Information base construction method, text information generation method, device, equipment and medium

By constructing an information database and storing the index relationship between keywords and text examples, the problem of poor generation performance of language processing models was solved, resulting in more accurate text generation and improved user satisfaction.

CN119202230BActive Publication Date: 2026-07-31CHINA UNITED NETWORK COMM GRP CO LTD +2
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA UNITED NETWORK COMM GRP CO LTD
Filing Date
2023-06-26
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

Existing language processing models cannot fully meet users' task requirements when generating text, resulting in poor generation results.

Method used

By building an information database, obtaining task requirements and text examples, determining keywords, generating and displaying original text information, responding to user feedback, storing keywords and text examples that meet similarity requirements, and establishing index relationships, the language processing model can quickly and accurately generate target text.

Benefits of technology

This improves the accuracy and user satisfaction of text generated by the language processing model, ensuring that the generated text better meets the task requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119202230B_ABST
    Figure CN119202230B_ABST
Patent Text Reader

Abstract

This application provides a method for constructing an information database, a method for generating text information, an apparatus, a device, and a medium. It includes: acquiring task requirement information to be constructed and text examples to be constructed; determining keywords in the task requirement information; generating and displaying original text information to the user based on the keywords and text examples; responding to user feedback on the original text information, determining target original text information and non-target original text information within the original text information; if the target original text information and non-target original text information meet a preset similarity requirement, storing the keywords and text examples to be constructed in the information database, and constructing an index relationship between the keywords and text examples to be constructed in the information database, so that the language processing model can use it when generating target text information after receiving task requirement information. The method of this application improves the effectiveness of language processing models in generating original text content.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of information database construction, and more particularly to an information database construction method, text information generation method, apparatus, device, and medium. Background Technology

[0002] Language processing models can perform various natural language processing tasks well, such as language translation, text summarization, and dialogue generation, but they still cannot fully meet all the requirements of user input.

[0003] The core idea behind existing language processing models for generating original text based on user-given task requirements is to first pre-train the model with a large amount of data and then fine-tune it for a specific task. This allows the model to generate original content based on user input prompts and the basic rules of natural language that have been learned.

[0004] However, due to the limitations of language processing models in understanding and processing natural language, existing methods suffer from poor performance when using language processing models for text generation. Summary of the Invention

[0005] This application provides a method for constructing an information database, a method for generating text information, an apparatus, a device, and a medium to address the problem that existing methods have poor performance when using language processing models for text generation.

[0006] Firstly, this application provides a method for constructing an information database, the method comprising:

[0007] Obtain the task requirements information and the text example to be built. The text example to be built is a text example corresponding to the task requirements information.

[0008] Determine the keywords required for the task to be built;

[0009] Based on keywords and text examples to be built, generate and display original text information to users;

[0010] In response to user feedback on original text information, target original text information and non-target original text information are determined. Target original text information is information selected by the user from the original text information that meets the task requirements, while non-target original text information is other original text information besides the target original text information.

[0011] If the target original text information and the non-target original text information meet the preset similarity requirements, the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database so that the language processing model can use it when generating target text information after receiving the task requirement information.

[0012] In this embodiment of the application, after determining the target original text information and non-target original text information in response to the user's feedback operation on the original text information, the method further includes:

[0013] If all the original text information is user-selected target original text information that meets the task requirements, then the keywords and text examples to be built are stored in the information database, and an index relationship between the keywords and text examples to be built is constructed in the information database.

[0014] In this embodiment of the application, if the target original text information and the non-target original text information meet a preset similarity requirement, the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database, including:

[0015] Identify the target text information segment in the non-target original text information. The target text information segment is the text information segment that meets the preset similarity requirement with the target original text information.

[0016] If the number of target text information segments and the total number of text information segments in non-target original text information meet the preset ratio threshold requirement, then the original text information is determined to be the standard original text information that meets the requirements of the task to be constructed.

[0017] Based on standard original text information, keywords and text examples to be built are stored in the information database, and an index relationship between keywords and text examples to be built is constructed in the information database.

[0018] In this embodiment of the application, if the target original text information and the non-target original text information meet a preset similarity requirement, then after storing the keywords and the text examples to be constructed in the information database, and constructing the index relationship between the keywords and the text examples to be constructed in the information database, the method further includes:

[0019] If the target original text information and the non-target original text information do not meet the similarity requirement, then the next text example is obtained. The next text example is a different example obtained again based on the task requirement information.

[0020] Using the next text example as a text example, the steps of generating original text information based on keywords and text examples are repeated until the target original text information and non-target original text information meet the similarity requirements. Then, the keywords and the next text example are stored in the information database, and an index relationship between keywords and the next text example is constructed in the information database.

[0021] Secondly, this application provides a method for generating text information, the method comprising:

[0022] Responding to the user's task input, obtain task requirement information;

[0023] Based on the task requirements information, target keyword information is determined. The target keyword information is the keyword that matches the task keywords in the information database. The information database is an information database constructed using the information database construction method.

[0024] Based on the task keywords, retrieve target text examples that have an index relationship with the task keywords from the information database;

[0025] Based on the target text example, generate target text information that meets the task requirements;

[0026] Display the target text information.

[0027] In this embodiment of the application, target text information that meets the task requirements is generated based on the target text example, including:

[0028] Based on the target text example and task requirement information, construct example samples, which include text key point examples, text example sentences examples, and task requirement information;

[0029] Input the example sample into the preset generation model to obtain the target text information that meets the task requirements.

[0030] In this embodiment of the application, an example sample is constructed based on the target text example and task requirement information. The example sample includes text key point examples, text example sentence examples, and task requirement information, including:

[0031] Based on the type of the target text, the target text examples are divided to obtain text key examples and text example sentences;

[0032] Based on the text key points examples and text example sentences, identify the conjunctions in the text key points examples and text example sentences.

[0033] Example samples are constructed based on the conjunctions in the text key points examples, the conjunctions in the text example sentences, and the task requirement information.

[0034] In this embodiment of the application, after displaying the target text information, the method further includes:

[0035] In response to the user's feedback action based on the target text information, the first user feedback information is obtained;

[0036] If the first user feedback information indicates that the target text information does not match the task requirement information, then obtain the target text example input by the user;

[0037] Based on the target text example input by the user, generate optimized text information that meets the task requirements;

[0038] Display optimized text information.

[0039] In this embodiment of the application, after displaying the optimized text information, the method further includes:

[0040] In response to the user's feedback action based on the optimized text information, a second user feedback message is obtained;

[0041] If the second user feedback information is information that represents optimized text information that matches the task requirements, then the target text example input by the user is stored in the preset information database, and an index relationship is established between the target text example and the target keyword information;

[0042] If the second user feedback information indicates that the optimized text information does not match the task requirement information, then other target text examples input by the user are retrieved again, and these other target text examples are used as target text examples. The step of generating optimized text information that meets the task requirement information based on the target text examples input by the user is then executed.

[0043] Thirdly, this application provides an information database construction apparatus, the apparatus comprising:

[0044] The information acquisition module is used to acquire the task requirements information to be built and the text example to be built. The text example to be built is a text example corresponding to the task requirements information to be built.

[0045] The keyword determination module is used to determine the keywords required for the task to be built;

[0046] The information generation module is used to generate and display original text information to users based on keywords and text examples to be built.

[0047] The information determination module, in response to the user's feedback operation on the original text information, determines the target original text information and non-target original text information in the original text information. The target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information besides the target original text information.

[0048] The storage and construction module is used to store keywords and text examples to be constructed in the information database if the target original text information and the non-target original text information meet the preset similarity requirements, and to construct the index relationship between keywords and text examples to be constructed in the information database.

[0049] Fourthly, this application provides a text information generation apparatus, the apparatus comprising:

[0050] The information acquisition module is used to acquire task requirement information in response to the user's task input operation;

[0051] The information determination module is used to determine target keyword information based on task requirement information. The target keyword information is the keyword that matches the task keywords in the information database. The information database is an information database constructed by the information database construction method.

[0052] The example retrieval module is used to retrieve target text examples that have an index relationship with the task keywords from the information database.

[0053] The information generation module is used to generate target text information that meets the task requirements based on the target text example.

[0054] The information display module is used to display target text information.

[0055] Fifthly, this application provides an apparatus, including: a processor, and a memory communicatively connected to the processor;

[0056] The memory stores the instructions that the computer executes;

[0057] The processor executes computer execution instructions stored in memory to implement the method of this application.

[0058] Sixthly, this application provides a computer-readable storage medium storing program code, which, when executed by a processor, is used to implement the method of this application.

[0059] The information database construction method, text information generation method, apparatus, device, and medium provided in this application acquire task requirement information to be constructed and text examples to be constructed, wherein the text examples to be constructed are text examples corresponding to the task requirement information to be constructed; determine the keywords of the task requirement information to be constructed; generate and display original text information to the user based on the keywords and the text examples to be constructed; in response to the user's feedback operation on the original text information, determine the target original text information and non-target original text information in the original text information, wherein the target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information besides the target original text information; if the target original text information and the non-target original text information meet the preset similarity requirements, then store the keywords and the text examples to be constructed in the information database, and construct an index relationship between the keywords and the text examples to be constructed in the information database.

[0060] In this way, original text information can be obtained by acquiring the task requirements and corresponding text examples. By judging whether the target original text information and non-target original text information meet a preset similarity requirement, it can be determined whether the original text information meets the task requirements. After determining that the original text information meets the task requirements, the extracted task-required keywords and given typical examples are stored in an information database, and an index relationship is established between the keywords and typical examples, thus constructing an information database for use by the language processing model. When using the language processing model to generate text information, keyword comparison can identify target keyword information and corresponding target text examples from the information database. Through these target text examples, the language processing model can quickly and accurately provide users with target text information that meets the task requirements. Therefore, even without providing numerous examples, the language processing model can accurately provide appropriate text information, improving its effectiveness. Attached Figure Description

[0061] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0062] Figure 1 This is a schematic diagram illustrating a scenario for a database construction method provided in an embodiment of this application.

[0063] Figure 2 This is a flowchart illustrating a method for constructing an information database, as provided in an embodiment of this application.

[0064] Figure 3This is a flowchart illustrating a text information generation method provided in an embodiment of this application.

[0065] Figure 4 This is a flowchart illustrating another method for constructing a database provided in an embodiment of this application.

[0066] Figure 5 This is a schematic diagram of the structure of an information database construction device provided in an embodiment of this application.

[0067] Figure 6 This is a schematic diagram of the structure of a text information generation device provided in an embodiment of this application.

[0068] Figure 7 This is a structural block diagram of an apparatus for performing a database construction method according to an embodiment of this application.

[0069] The accompanying drawings have illustrated specific embodiments of this application, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concept of this application to those skilled in the art by referring to specific embodiments. Detailed Implementation

[0070] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this application as detailed in the appended claims.

[0071] In existing technologies, language processing models learn the content—text components—of objects from training data using various machine learning methods, thereby generating entirely new and original text content. However, since the data used to train these models is always limited and cannot cover all user requirements, the quality of the text content generated by the language processing model will be significantly reduced when users input new task requirements that differ greatly from the training data, resulting in a substantial discrepancy with the user's task requirements.

[0072] To address the aforementioned issues, this application provides a method for constructing an information database. This method trains a language processing model using task requirements and given typical examples. When the original text generated by the language processing model based on these requirements and examples satisfies the task requirements, the extracted keywords and the given typical examples are stored in the information database. An index relationship is established between the keywords and typical examples, thereby constructing the information database. Furthermore, a text information generation method is proposed. When faced with task requirements, the language processing model can match the extracted keywords with the keyword database in the information database to obtain typical examples stored in the database that correspond to the task information, thereby generating original text that meets the task requirements. This improves the accuracy of the language processing model in generating original text that meets the user's task requirements and effectively enhances the effect of the language processing model in generating original text content.

[0073] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will be described below with reference to the accompanying drawings.

[0074] Figure 1 This diagram illustrates a practical application scenario of a database construction method provided in this application. Figure 1 As shown, the scene diagram may include an information acquisition unit 11, a text generation unit 12, and an information storage unit 13.

[0075] The information acquisition unit 11 can acquire the task requirements and given typical examples input by the user through the screen of the terminal device, or it can acquire them through other means. As long as it is an information acquisition unit used to acquire the task requirements and typical examples input by the user, this embodiment does not limit it.

[0076] The text generation unit 12 can be a language processing model, i.e. a deep learning model for natural language processing, which is trained to understand and generate natural language. It learns the content of objects—text components—from training data through various machine learning methods, and then generates new, completely original text. The language processing model can be a natural language processing (NLP) model, such as Chat GPT, or a recurrent neural network (RNN), such as seq2seq, or a language representation model such as Bidirectional Encoder Representation from Transformers (BERT).

[0077] The information storage unit 13 can be an information database with information storage function. It can be used to store keyword information required by the task and given typical examples, and to establish an index relationship between keywords and typical examples.

[0078] The signal interaction between the information acquisition unit 11, the text generation unit 12, and the information storage unit 13 can be achieved through wireless transmission.

[0079] In some implementations, the text generation unit 12 generates original text that better meets the task requirements based on the keyword information and matching typical examples in the information storage unit 13. The process of constructing the information storage unit 13 is as follows: the information acquisition unit 11 acquires the given task requirements and typical examples and sends them to the text generation unit 12. The text generation unit 12 generates original text information based on this. If the original text information meets the given task requirements, the extracted keyword information of the task requirements and the given typical examples are stored together in the information storage unit 13, and an index relationship is established between the keyword information and the typical examples. Thus, an information storage unit 13 is constructed that stores keyword information and typical examples with corresponding index relationships. This allows the subsequent text generation unit 12 to extract keyword information from the given task requirements and match the corresponding typical examples from the information storage unit 13 based on the keyword information. Therefore, based on the task requirements and the matched typical examples, original text information that meets the task requirements is generated, improving the accuracy of the generated original text information in meeting the task requirements and better meeting the user's needs.

[0080] The keyword information is the key information extracted from the task requirements that best reflects the user's needs, and is used to match the corresponding typical examples from the information storage unit 13. The method for extracting the keyword information can be template matching, full sentence search, deep neural network model, or other methods that can accurately find the task keywords in the text. This embodiment does not limit this method.

[0081] Figure 2 This is a flowchart illustrating a method for constructing an information database according to an embodiment of this application. The execution entity of this method can be an information database within a language processing model. Figure 2 As shown, the method for constructing this information repository may include the following steps:

[0082] S210. Obtain the task requirement information and the text example to be built. The text example to be built is a text example corresponding to the task requirement information.

[0083] The task requirement information to be built and the text example to be built represent the task requirement information and text example given to the language processing model during the construction of the information base. The text example to be built is a given text example whose content corresponds to the task requirement information to be built, so that the original text information generated by the language processing model based on the text example to be built can better meet the task requirement information to be built. It can be a text example entered by the user or an example obtained by crawling. The user selects the example that best corresponds to the task requirement information to be built as the text example to be built.

[0084] Based on this, the requirements of the task to be built and the text example to be built are obtained, so as to generate the corresponding original text information and build the information database in the future.

[0085] S220. Determine the keywords for the task requirements information to be built.

[0086] Among them, keywords are key information extracted from task requirements that best reflects user needs.

[0087] Based on this, keywords are extracted from the task requirements information to be built, so that original text information can be generated based on the keywords and the text examples to be built, and an index relationship between the keywords and the text examples to be built can be established.

[0088] S230: Based on keywords and text examples to be built, generate and display original text information to the user.

[0089] Based on this, the language processing model generates original text information and displays it to the user using keywords in the task requirements information and text examples to be constructed.

[0090] S240. In response to the user's feedback operation on the original text information, determine the target original text information and non-target original text information in the original text information, wherein the target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information in the original text information besides the target original text information.

[0091] The feedback operation is an operation that indicates whether the user determines whether the original text information meets the task requirements. It can be an operation in which the user selects a section or all of the original text information as the information that meets the task requirements, or it can be an operation in which the user determines that the generated original text information does not meet the task requirements.

[0092] Based on this, after displaying original text information to the user and receiving the user's feedback, the system responds to the user's feedback by identifying the text information that the user believes meets the task requirements from the original text information as the target original text information. The remaining text information that the user has not interacted with is the non-target original text information. There may also be text information that meets the task requirements among the non-target original text information, but the user has not been able to identify it due to the large amount of text information generated.

[0093] In some implementations, after determining the target original text information and non-target original text information in response to user feedback on the original text information, the method further includes:

[0094] If all the original text information is user-selected target original text information that meets the task requirements, then the keywords and text examples to be built are stored in the information database, and an index relationship between the keywords and text examples to be built is constructed in the information database.

[0095] Among them, the original text information is all user-selected target original text information that meets the task requirements. It can also be that the generated original text information is relatively small. Users can determine for themselves whether all the original text information meets the task requirements, that is, whether all the original text information is the target original text information.

[0096] Based on this, if the generated original text information is relatively small, the user can determine whether all of it meets the task requirements for the information to be constructed, i.e., whether all of it is the target original text information. After determining that all of the original text information is the target original text information, the keywords and text examples to be constructed are stored in the information database, and an index relationship between the keywords and text examples to be constructed is built in the information database, thereby realizing the construction of the information database. This allows the subsequent language processing model to generate original text information that meets the task requirements based on the keywords and text examples with index relationships built in the information database.

[0097] S250. If the target original text information and the non-target original text information meet the preset similarity requirements, then the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database so that the language processing model can use it when generating target text information after receiving the task requirement information.

[0098] The preset similarity requirement is a pre-set similarity requirement used to compare the similarity between target original text information and non-target original text information. If the target original text information and non-target original text information meet the preset similarity requirement, since the target original text information is determined by the user to meet the task requirements, the non-target original text information also meets the task requirements, that is, the original text information meets the task requirements. Thus, the original text information can be determined to meet the task requirements through the preset similarity requirement.

[0099] Similarity comparison can be performed by calculating the similarity between the target original text information and the non-target original text information through an algorithm, or by comparing the similarity through the angle between vectors, or by comparing sentence structure, word repetition rate, etc. This embodiment does not limit this.

[0100] In some implementations, if the target original text information and the non-target original text information meet a preset similarity requirement, then the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is built in the information database, including:

[0101] Identify the target text information segment in the non-target original text information. The target text information segment is the text information segment that meets the preset similarity requirement with the target original text information.

[0102] If the number of target text information segments and the total number of text information segments in non-target original text information meet the preset ratio threshold requirement, then the original text information is determined to be the standard original text information that meets the requirements of the task to be constructed.

[0103] Based on standard original text information, keywords and text examples to be built are stored in the information database, and an index relationship between keywords and text examples to be built is constructed in the information database.

[0104] The text information segment is a piece of information in the non-target original text information. It can be that the text in the original text information is divided into paragraphs, and one piece of text is determined as a text information segment. Alternatively, several pieces of text can be determined as a text information segment. This embodiment does not limit this.

[0105] The preset ratio threshold is a pre-set ratio threshold used to determine the proportion of the target text information segment in the non-target original text information. If the preset ratio threshold is met, that is, if the proportion of text information segments in the non-target original text information that meet the task requirements is relatively large, then the non-target original text information is determined to be text information that meets the task requirements, and thus the generated original text information is determined to be text information that meets the task requirements.

[0106] Based on this, after the user identifies the target original text information that meets the task requirements, each text segment of the non-target original text information is compared with the target original text information to obtain the target text information segments that meet the preset similarity requirements. If the ratio of the number of target text information segments to the number of non-target original text information segments meets the preset ratio threshold, then it is determined that the non-target original text information also meets the task requirements. Thus, the keywords and text examples to be constructed are stored in the information database and an index relationship is established to realize the construction of the information database.

[0107] In other embodiments, after storing the keywords and text examples to be constructed in an information database if the target original text information and the non-target original text information meet a preset similarity requirement, and after constructing an index relationship between the keywords and text examples to be constructed in the information database, the method further includes:

[0108] If the target original text information and the non-target original text information do not meet the similarity requirement, then the next text example is obtained. The next text example is a different example obtained again based on the task requirement information.

[0109] Using the next text example as a text example, the steps of generating original text information based on keywords and text examples are repeated until the target original text information and non-target original text information meet the similarity requirements. Then, the keywords and the next text example are stored in the information database, and an index relationship between keywords and the next text example is constructed in the information database.

[0110] Based on this, if the target original text information and the non-target original text information do not meet the similarity requirements, that is, the original text information does not meet the task requirements, then a new text example is determined so that the language processing model can generate new original text information based on the task requirements information to be constructed and the new text example. Then, it continues to execute the determination of the original text information that meets the task requirements based on the preset similarity requirements, and stores the keywords and the new text example in the information database, and builds the index relationship between the keywords and the new text example in the information database.

[0111] In this embodiment, original text information is generated by obtaining the task requirements information and text examples to be constructed. Users can determine whether the original text information meets the task requirements themselves; or they can determine a portion of the text information that meets the task requirements as the target original text information, and determine the text information segments that meet the task requirements in the non-target original text information as the target text information segments by using a preset similarity requirement. If the ratio of the number of target text information segments and non-target original text information meets a preset ratio threshold, it indicates that the original text information meets the task requirements. The keywords and the next text example are stored in the information database, and an index relationship between the keywords and the next text example is constructed in the information database.

[0112] In this way, by setting similarity requirements and a preset ratio threshold, the original text information is determined to meet the task requirements. Based on the keywords of the task requirement information to be constructed and the text examples to be constructed, the information database is constructed. This enables the subsequent language processing model to generate original text information by identifying text examples in the information database that match the task requirements, making the generated original text information more in line with the user's task requirements, thereby improving accuracy and user satisfaction.

[0113] Figure 3 This is a flowchart illustrating a text information generation method provided in an embodiment of this application. The execution entity of this method can be a language processing model. Figure 3 As shown, the text information generation method may include the following steps:

[0114] S310: Responding to the user's task input operation, obtain task requirement information.

[0115] Among them, the task input operation represents the user's need for the language processing model to generate original text information that meets the task requirements. This can be either manual input of the task requirements by the user or voice input.

[0116] Based on this, the language processing model responds to the user's task input and determines the task requirements information for generating original text information.

[0117] S320. Based on the task requirement information, determine the target keyword information. The target keyword information is the keyword that matches the task keyword in the information database. The information database is an information database constructed by the information database construction method.

[0118] Among them, the target keyword information is the key information required by the task, which is used to determine the corresponding text examples from the information database based on the index relationship, so that the language processing model can generate original text information.

[0119] S330. Based on the task keywords, retrieve target text examples from the information database that have an index relationship with the task keywords.

[0120] Based on this, an index relationship between keywords and corresponding text examples has been established during the construction of the information database. Thus, the target text examples stored in the information database are determined based on the task keywords and the index relationship.

[0121] S340. Based on the target text example, generate target text information that meets the task requirements.

[0122] Based on this, by using task keywords and target text examples in the information database, the language processing model generates target text information that meets the task requirements, thereby improving the accuracy of the text content.

[0123] In some implementations, target text information that meets the task requirements is generated based on the target text example, including:

[0124] Based on the target text example and task requirement information, construct example samples, which include text key point examples, text example sentences examples, and task requirement information;

[0125] Input the example sample into the preset generation model to obtain the target text information that meets the task requirements.

[0126] Among them, the text key point examples are examples that represent the key points of the target text example, such as "likes to use two words and reduplicated words to describe things" or "frequently uses phrases and short sentences to communicate". These examples that represent the characteristics of the text key points are text key point examples; the text example sentences are the original text sentences that correspond to the task requirements.

[0127] The preset generation model is a pre-defined text information generation model, which can be a language processing model.

[0128] Based on this, according to the different text types, the target text examples can be divided into two categories: text key point examples and text example sentence examples. The text key point examples, text example sentence examples, and task requirement information are used as example samples so that the generative model can generate original text information that meets the task requirements based on the example samples.

[0129] In this implementation, an example sample is constructed based on the target text example and task requirement information. The example sample includes text key point examples, text example sentences examples, and task requirement information, including:

[0130] Based on the type of the target text, the target text examples are divided to obtain text key examples and text example sentences;

[0131] Based on the text key points examples and text example sentences, identify the conjunctions in the text key points examples and text example sentences.

[0132] Example samples are constructed based on the conjunctions in the text key points examples, the conjunctions in the text example sentences, and the task requirement information.

[0133] Connectives are used to link target text examples of the same type so that the language processing model can better generate original text information based on the text examples; the connective for text point examples can be "its points are as follows", and the connective for text example sentences examples can be "the following are several example sentences".

[0134] Based on this, text key examples and text example sentences are connected into coherent text information using corresponding conjunctions. Example samples are then constructed based on text key examples with conjunctions, text example sentences with conjunctions, and task requirement information.

[0135] S350, Display target text information.

[0136] Based on this, the generated target text information can be displayed to the user in text form or in voice form; this embodiment does not limit this.

[0137] In some implementations, after displaying the target text information, the method further includes:

[0138] In response to the user's feedback action based on the target text information, the first user feedback information is obtained;

[0139] If the first user feedback information indicates that the target text information does not match the task requirement information, then obtain the target text example input by the user;

[0140] Based on the target text example input by the user, generate optimized text information that meets the task requirements;

[0141] Display optimized text information.

[0142] The first user feedback information is the feedback information obtained based on the user's feedback operation, indicating whether the target text information matches the task requirement information. For example, the language processing model can provide the user with the option to see whether the target text information matches the task requirement information. If the user selects the negative option, the obtained first user feedback information is the information that the user believes the target text information does not match the task requirement information.

[0143] Based on this, if the language processing model receives first user feedback indicating that the target text information does not match the task requirement information, the language processing model can prompt the user to input a new text example as the target text example, and generate optimized text information based on the target text example so that the optimized text information can meet the task requirements and fulfill the user's needs.

[0144] In this implementation, after displaying the optimized text information, the method further includes:

[0145] In response to the user's feedback action based on the optimized text information, a second user feedback message is obtained;

[0146] If the second user feedback information is information that represents optimized text information that matches the task requirements, then the target text example input by the user is stored in the preset information database, and an index relationship is established between the target text example and the target keyword information;

[0147] If the second user feedback information indicates that the optimized text information does not match the task requirement information, then other target text examples input by the user are retrieved again, and these other target text examples are used as target text examples. The step of generating optimized text information that meets the task requirement information based on the target text examples input by the user is then executed.

[0148] The second user feedback information is feedback information obtained based on user feedback operations, which determines whether the optimized text information matches the task requirements information, and is used to determine whether the optimized text information meets the task requirements.

[0149] Based on this, after displaying the optimized text information to the user, the system determines whether the optimized text information meets the task requirements based on the obtained second user feedback information. If it does, it indicates that the target text example input by the user is beneficial to the language processing model, and it is stored in the preset information base accordingly. An index relationship between the target text example and the target keyword information is established so that when the language processing model faces task requirements with the same keywords, it can generate text information that meets the task requirements based on the target text example. If it does not meet the requirements, it indicates that the target text example given by the user is not suitable for the language processing model. In this case, the user is prompted to continue inputting a new target text example until the language processing model generates text information that meets the task requirements.

[0150] In this embodiment, the language processing model obtains task requirement information, extracts keywords from it, and uses a pre-built information database to match target examples corresponding to the keywords based on index relationships. The model then categorizes the examples by type and determines the corresponding connecting words, thereby obtaining coherent target examples. This allows the language processing model to generate text information that meets the task requirements based on the task keywords and target examples. Furthermore, based on the obtained user feedback information, new target examples are determined to ensure that the final generated text information meets the task requirements. The information database is continuously improved based on the keywords and new target examples.

[0151] In this way, by using the target examples stored in the information base that correspond to the task requirements, the language processing model can improve the accuracy of the generated text information relative to the task requirements, thereby improving user satisfaction. If the user believes that the generated text information does not meet the task requirements, the model can obtain new target examples input by the user to ensure that original text information that meets the task requirements is generated and satisfies the user's needs. The target text examples input by the user are stored in the information base to continuously improve the information base.

[0152] Figure 4 This is a flowchart illustrating another method for constructing a database provided in an embodiment of this application. Figure 4 As shown, the method for constructing this information repository may include the following steps:

[0153] S410. For a certain task requirement, provide a corresponding typical example, which is then input into the generative artificial intelligence model as a whole to obtain the corresponding result.

[0154] Based on this, during the construction of the information database, task requirements and corresponding examples are provided to the artificial intelligence model so that the model can generate corresponding original text content.

[0155] S420. Determine whether the output meets the task requirements. If so, add the typical input example to the task example library and store the keywords of the input task text as the index of the example in the task example library.

[0156] Determining whether the output meets the task requirements can be done by the user confirming whether the output meets the requirements, by using an algorithm or the angle between vectors, or by calculating similarity.

[0157] Keywords in task text can be determined through template matching, whole-sentence search, deep neural network models, etc., which can accurately find task keywords in the text.

[0158] S430. If the output does not meet the task requirements, replace the typical example or add a typical example, and repeat the above steps until a suitable example is selected and added to the task example library.

[0159] The replacement of typical examples can be either user-inputted typical examples or obtained by crawling a large number of relevant examples, with the user selecting the typical example that best corresponds to the task requirements as the input model.

[0160] Based on this, once enough typical examples and keyword indexes for a sufficient number of new tasks are stored in the task example library, the construction of the task example library is complete.

[0161] S440. Ask the user if the output result solves the proposed task. If the user's feedback is that it is not solved, prompt the user to provide some task examples.

[0162] This could involve outputting voice or text prompts to the user to confirm whether the output meets the task requirements.

[0163] S450. Combine the task examples and task requirements provided by the user to obtain the corresponding output results. Determine whether the task requirements are met. If so, add the typical examples input by the user and the extracted keywords as indexes of the examples to the task example library.

[0164] Based on this, the model generates new text information according to the task examples obtained from user input. If the task requirements are met, the typical examples of user input and the keywords of the task requirements are stored in the task example library, and an index relationship is established between the keywords and examples in the task example library.

[0165] Furthermore, if the output does not meet the task requirements, the user is prompted to change or add a typical example, and the above steps are repeated until a suitable example is selected and added to the task example library.

[0166] In some implementations, after the user inputs the task requirements, a task keyword extraction model is invoked to determine whether the input matches an index in an existing task example library, i.e., whether the user's input contains keywords. If a matching task example is found, the corresponding example in the task example library is retrieved and merged with the user's original input. An updated prompt word is generated by adding example prompt words. This prompt word generator uses a manually designed prompt template approach, merging the example with the input using a fixed sentence structure. The updated prompt word is then input into the generative artificial intelligence model to obtain an optimized output result. This result is more in line with the user's requirements and of higher quality than the result obtained directly from the original input. On the other hand, if no matching task example is found in the input task, the original input is directly fed into the generative artificial intelligence model to obtain the result.

[0167] In this embodiment, the task example library is continuously improved during use so that the language processing model can better generate text information that meets the task requirements based on the task example library.

[0168] Figure 5 This is a schematic diagram of the structure of an information database construction device 500 provided in an embodiment of this application, as shown below. Figure 5 As shown, the apparatus 500 for constructing the information database includes: an information acquisition module 510, a keyword determination module 520, an information generation module 530, an information determination module 540, and a storage and construction module 550.

[0169] The information acquisition module 510 is used to acquire the task requirement information to be built and the text example to be built, wherein the text example to be built is a text example corresponding to the task requirement information to be built.

[0170] Keyword determination module 520 is used to determine the keywords required for the task to be constructed.

[0171] The information generation module 530 is used to generate and display original text information to users based on keywords and text examples to be constructed.

[0172] The information determination module 540, in response to the user's feedback operation on the original text information, determines the target original text information and non-target original text information in the original text information. The target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information in the original text information besides the target original text information.

[0173] The storage and construction module 550 is used to store keywords and text examples to be constructed in the information database if the target original text information and the non-target original text information meet the preset similarity requirements, and to construct the index relationship between keywords and text examples to be constructed in the information database so that the language processing model can use it when generating target text information after receiving task requirement information.

[0174] In this embodiment of the application, the apparatus 500 for constructing the information database can also be specifically used for:

[0175] If all the original text information is user-selected target original text information that meets the task requirements, then the keywords and text examples to be built are stored in the information database, and an index relationship between the keywords and text examples to be built is constructed in the information database.

[0176] In this embodiment of the application, the storage and construction module 550 can also be specifically used for:

[0177] Identify the target text information segment in the non-target original text information. The target text information segment is the text information segment that meets the preset similarity requirement with the target original text information.

[0178] If the number of target text information segments and the total number of text information segments in non-target original text information meet the preset ratio threshold requirement, then the original text information is determined to be the standard original text information that meets the requirements of the task to be constructed.

[0179] Based on standard original text information, keywords and text examples to be built are stored in the information database, and an index relationship between keywords and text examples to be built is constructed in the information database.

[0180] In this embodiment of the application, the apparatus 500 for constructing the information database can also be specifically used for:

[0181] If the target original text information and the non-target original text information do not meet the similarity requirement, then the next text example is obtained. The next text example is a different example obtained again based on the task requirement information.

[0182] Using the next text example as a text example, the steps of generating original text information based on keywords and text examples are repeated until the target original text information and non-target original text information meet the similarity requirements. Then, the keywords and the next text example are stored in the information database, and an index relationship between keywords and the next text example is constructed in the information database.

[0183] Figure 6 This is a schematic diagram of the structure of a text information generation device provided in an embodiment of this application, such as... Figure 6 As shown, the text information generation device 600 includes: an information acquisition module 610, an information determination module 620, an example acquisition module 630, an information generation module 640, and an information display module 650.

[0184] Information acquisition module 610 is used to acquire task requirement information in response to user task input operations;

[0185] The information determination module 620 is used to determine the target keyword information based on the task requirement information. The target keyword information is the keyword that matches the task keyword in the information database. The information database is an information database constructed by the information database construction method.

[0186] Example retrieval module 630 is used to retrieve target text examples that have an index relationship with the task keywords from the information database;

[0187] The information generation module 640 is used to generate target text information that meets the task requirements based on the target text example;

[0188] The information display module 650 is used to display target text information.

[0189] In this embodiment of the application, the information generation module 640 can also be specifically used for:

[0190] Based on the target text example and task requirement information, construct example samples, which include text key point examples, text example sentences examples, and task requirement information;

[0191] Input the example sample into the preset generation model to obtain the target text information that meets the task requirements.

[0192] In this embodiment of the application, the information generation module 640 can also be specifically used for:

[0193] Based on the type of the target text, the target text examples are divided to obtain text key examples and text example sentences;

[0194] Based on the text key points examples and text example sentences, identify the conjunctions in the text key points examples and text example sentences.

[0195] Example samples are constructed based on the conjunctions in the text key points examples, the conjunctions in the text example sentences, and the task requirement information.

[0196] In this embodiment of the application, the text information generation device 600 can also be specifically used for:

[0197] In response to the user's feedback action based on the target text information, the first user feedback information is obtained;

[0198] If the first user feedback information indicates that the target text information does not match the task requirement information, then obtain the target text example input by the user;

[0199] Based on the target text example input by the user, generate optimized text information that meets the task requirements;

[0200] Display optimized text information.

[0201] In this embodiment of the application, the text information generation device 600 can also be specifically used for:

[0202] In response to the user's feedback action based on the optimized text information, a second user feedback message is obtained;

[0203] If the second user feedback information is information that represents optimized text information that matches the task requirements, then the target text example input by the user is stored in the preset information database, and an index relationship is established between the target text example and the target keyword information;

[0204] If the second user feedback information indicates that the optimized text information does not match the task requirement information, then other target text examples input by the user are retrieved again, and these other target text examples are used as target text examples. The step of generating optimized text information that meets the task requirement information based on the target text examples input by the user is then executed.

[0205] Figure 7 This is a schematic diagram of the device provided in an embodiment of this application. Figure 7 As shown, the device 700 includes:

[0206] The device 700 may include a processor 701 with one or more processing cores, a memory 702 with one or more computer-readable storage media, a communication component 703, and other components. The processor 701, memory 702, and communication component 703 are connected via a bus 704.

[0207] In the specific implementation process, at least one processor 701 executes computer execution instructions stored in memory 702, causing at least one processor 701 to execute the message processing method described above.

[0208] The specific implementation process of processor 701 can be found in the above method embodiments, and its implementation principle and technical effect are similar. It will not be repeated here.

[0209] In the above Figure 7 In the illustrated embodiments, it should be understood that the processor can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. The general-purpose processor can be a microprocessor or any conventional processor. The steps of the methods disclosed in this application can be directly manifested as being executed by a hardware processor, or executed by a combination of hardware and software modules within the processor.

[0210] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage device.

[0211] The bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc. For ease of illustration, the buses shown in the accompanying drawings are not limited to a single bus or a single type of bus.

[0212] In some embodiments, a computer program product is also provided, including a computer program or instructions that, when executed by a processor, implement the steps in any of the above-described information database construction methods or text information generation methods.

[0213] For details on the implementation of each of the above operations, please refer to the previous examples, which will not be repeated here.

[0214] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be performed by instructions, or by instructions controlling related hardware. These instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0215] Therefore, embodiments of this application provide a computer-readable storage medium storing multiple lines of program code that can be loaded by a processor to execute steps in any of the information database construction methods or text information generation methods provided in embodiments of this application.

[0216] The storage medium may include: read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0217] According to one aspect of this application, a computer program product or computer program is provided, the computer program product or computer program including computer instructions stored in a computer-readable storage medium.

[0218] Since the instructions stored in the storage medium can execute the steps of any of the information database construction methods and text information generation methods provided in the embodiments of this application, the beneficial effects that any of the information database construction methods and text information generation methods provided in the embodiments of this application can achieve can be realized. For details, please refer to the previous embodiments, which will not be repeated here.

[0219] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the following claims.

[0220] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

Claims

1. An information base construction method characterized by comprising: An information base applied in a language processing model, the method comprising: Obtain the task requirements information and the text example to be built, wherein the text example to be built is a text example corresponding to the task requirements information; Determine the keywords for the task requirements information to be constructed; Based on the keywords and the text example to be constructed, generate and display original text information to the user; In response to the user's feedback operation on the original text information, target original text information and non-target original text information are determined in the original text information, wherein the target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information in the original text information besides the target original text information; If the target original text information and the non-target original text information meet the preset similarity requirements, then the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database so that the language processing model can use them when generating target text information after receiving task requirement information.

2. The method of claim 1, wherein, After determining the target original text information and non-target original text information within the original text information in response to the user's feedback operation on the original text information, the method further includes: If all the original text information is target original text information selected by the user that meets the task requirements, then the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database.

3. The method of claim 1, wherein, If the target original text information and the non-target original text information meet a preset similarity requirement, then the keywords and the text example to be constructed are stored in the information database, and an index relationship between the keywords and the text example to be constructed is constructed in the information database so that the language processing model can use it when generating target text information after receiving task requirement information, including: Identify the target text information segment in the non-target original text information, wherein the target text information segment is a text information segment that meets a preset similarity requirement with the target original text information; If the number of target text information segments and the total number of text information segments in the non-target original text information meet a preset ratio threshold requirement, then the original text information is determined to be standard original text information that meets the requirements of the task to be constructed. Based on the standard original text information, the keywords and the text examples to be constructed are stored in the information database, and an index relationship between the keywords and the text examples to be constructed is constructed in the information database.

4. The method of claim 1, wherein, After the method further includes storing the keywords and the text example to be constructed in the information database if the target original text information and the non-target original text information meet a preset similarity requirement, and constructing an index relationship between the keywords and the text example to be constructed in the information database so that the language processing model can use them when generating target text information after receiving task requirement information, the method further includes: If the target original text information and the non-target original text information do not meet the similarity requirement, then the next text example is obtained. The next text example is an example that is re-obtained according to the task requirement information and is different from the text example. Using the next text example as the text example, the step of generating original text information based on the keywords and the text example is repeated until the target original text information and the non-target original text information in the original text information meet the similarity requirement. Then, the keywords and the next text example are stored in the information database, and an index relationship between the keywords and the next text example is constructed in the information database.

5. A method of generating text information, characterized by, Applied to a language processing model, the method includes: Responding to the user's task input, obtain task requirement information; Based on the task requirement information, target keyword information is determined, wherein the target keyword information is a keyword that matches the task keywords in the information database, and the information database is the information database of any one of claims 1 to 4; Based on the task keywords, retrieve target text examples that have an index relationship with the task keywords from the information database; Based on the target text example, generate target text information that meets the task requirements. Display the target text information.

6. The method of claim 5, wherein, The step of generating target text information that meets the task requirements based on the target text example includes: Based on the target text example and the task requirement information, an example sample is constructed, which includes text key point examples, text example sentences examples, and task requirement information; The example sample is input into a preset generation model to obtain target text information that meets the task requirements.

7. The method of claim 6, wherein, Based on the target text example and the task requirement information, an example sample is constructed. The example sample includes text key point examples, text example sentences, and task requirement information, including: Based on the type of the target text, the target text examples are divided to obtain text key examples and text example sentences examples; Based on the text key point examples and the text example sentences, determine the conjunctions in the text key point examples and the text example sentences. The example sample is constructed based on the conjunctions in the text key point example, the conjunctions in the text example sentence example, and the task requirement information.

8. The method of claim 5, wherein, After displaying the target text information, the method further includes: In response to the user's feedback operation based on the target text information, first user feedback information is obtained; If the first user feedback information indicates that the target text information does not match the task requirement information, then obtain an example of the target text input by the user; Based on the target text example input by the user, generate optimized text information that meets the task requirements. Display the optimized text information.

9. The method of claim 8, wherein, After displaying the optimized text information, the method further includes: In response to the user's feedback operation based on the optimized text information, a second user feedback information is obtained; If the second user feedback information is information indicating that the optimized text information matches the task requirement information, then the target text example input by the user is stored in a preset information database, and an index relationship is established between the target text example and the target keyword information; If the second user feedback information indicates that the optimized text information does not match the task requirement information, then other target text examples input by the user are obtained again, and the other target text examples are used as the target text examples. The step of generating optimized text information that meets the task requirement information based on the target text examples input by the user is then executed.

10. An information base construction apparatus characterized by comprising: The apparatus includes an information base used in a language processing model. The information acquisition module is used to acquire the task requirement information to be built and the text example to be built, wherein the text example to be built is a text example corresponding to the task requirement information to be built. The keyword determination module is used to determine the keywords required for the task to be constructed; The information generation module is used to generate and display original text information to the user based on the keywords and the text example to be constructed; The information determination module, in response to the user's feedback operation on the original text information, determines the target original text information and non-target original text information in the original text information, wherein the target original text information is the information selected by the user from the original text information that meets the task requirements, and the non-target original text information is other original text information in the original text information besides the target original text information; The storage and construction module is used to store the keywords and the text examples to be constructed in the information database if the target original text information and the non-target original text information meet the preset similarity requirements, and to construct the index relationship between the keywords and the text examples to be constructed in the information database so that the language processing model can use them when generating target text information after receiving task requirement information.

11. A text information generating apparatus characterized by comprising: The apparatus, applied to a language processing model, includes: The information acquisition module is used to acquire task requirement information in response to the user's task input operation; An information determination module is used to determine target keyword information based on the task requirement information, wherein the target keyword information is a keyword that matches the task keywords in an information database, and the information database is the information database according to any one of claims 1 to 4; The example acquisition module is used to acquire target text examples that have an index relationship with the task keywords from the information database based on the task keywords; The information generation module is used to generate target text information that meets the task requirements based on the target text example. The information display module is used to display the target text information.

12. An apparatus, comprising: include: One or more processors; Memory; One or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs being configured to perform the method as described in any one of claims 1 to 9.

13. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores program code that can be invoked by a processor to execute the method as described in any one of claims 1 to 9.