Information generation method and device and computer readable storage medium

By using historical Q&A information and current question text to generate answer text in multiple rounds of conversations, the feature vectors of question and answer text are directly processed, which solves the problem of stressful processing in multiple rounds of conversations, and achieves more efficient and accurate information generation.

CN120197698APending Publication Date: 2025-06-24SHENZHEN WORKEC TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510272787.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-10
Publication Date
2025-06-24

AI Technical Summary

Technical Problem

During multiple rounds of conversations, the large language model needs to process multiple question-and-answer texts, resulting in greater processing pressure.

Method used

By obtaining the task identification of the dialogue task between the target large language model and the user and the target information of the current question text, the current answer text is generated based on the historical question and answer information and the current question text, and the feature vector of the question and answer text is directly processed.

Benefits of technology

Reduces the processing pressure of large language models in multiple rounds of conversations, and improves efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120197698A_ABST
    Figure CN120197698A_ABST
Patent Text Reader

Abstract

The invention provides an information generation method and device and a computer readable storage medium, relates to the technical field of large language models, and can reduce the processing pressure of the large language model in a multi-round dialogue process. The method is applied to an information generation device, a target large language model is deployed in the information generation device, the target large language model is used for generating an answer text based on a question text, and the method comprises the steps of obtaining target information; the target information comprises a target task identifier of a target dialogue task between the target large language model and the target user and a current question text input by the target user; determining historical question and answer information of the target dialogue task according to the target task identifier; the historical question and answer information comprises a feature vector of a historical question text and a feature vector of a historical answer text corresponding to the historical question text; and generating a current answer text of the current question text according to the historical question and answer information and the current question text.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of large language models, and particularly to an information generation method, apparatus, and computer-readable storage medium. Background Art

[0002] A large language model is a deep learning model capable of processing and generating natural language text. After a user inputs a question text, the large language model can generate an answer text based on the question text.

[0003] A user can have multiple rounds of conversations with the large language model. That is, the user inputs the first question text, the large language model can generate the first answer text, the user then inputs the second question text, and the large language model generates the second answer text based on the first question text, the first answer text, and the second question text, and so on.

[0004] During the process of multiple rounds of conversations, every time the user inputs a question text, the previous question text and the previous answer text in the current conversation task need to be used as the input of the large language model. The large language model processes multiple texts to generate an answer text, and the processing pressure on the large language model is relatively high. Summary of the Invention

[0005] This application provides an information generation method, apparatus, and computer-readable storage medium, which can reduce the processing pressure on the large language model during the process of multiple rounds of conversations.

[0006] To achieve the above objective, this application adopts the following technical solutions:

[0007] In a first aspect, an information generation method is provided. The method is applied to an information generation apparatus deployed with a target large language model for generating an answer text based on a question text. The method includes: obtaining target information; the target information includes a target task identifier of a target conversation task between the target large language model and a target user and the current question text input by the target user; determining historical question-and-answer information of the target conversation task according to the target task identifier; the historical question-and-answer information includes a feature vector of a historical question text and a feature vector of a historical answer text corresponding to the historical question text; and generating a current answer text for the current question text according to the historical question-and-answer information and the current question text.

[0008] In combination with the first aspect, in some embodiments of the first aspect, generating a current answer text for the current question text according to the historical question-and-answer information and the current question text includes: processing the current question text to obtain a feature vector of the current question text; and generating the current answer text according to the historical question-and-answer information and the feature vector of the current question text.

[0009] In combination with the first aspect, in some embodiments of the first aspect, the method further includes: processing the current answer text to obtain a feature vector of the current answer text; storing the feature vector of the current question text and the feature vector of the current answer text in a target storage area, where the target storage area is used to store historical question-and-answer information corresponding to the target dialogue task.

[0010] In combination with the first aspect, in some embodiments of the first aspect, processing the current question text / current answer text to obtain a feature vector of the current question text / current answer text includes: performing text compression and / or text enhancement processing on the current question text / current answer text to obtain a target current question text / target current answer text; performing vectorization processing on the target current question text / target current answer text to obtain a feature vector of the current question text / current answer text.

[0011] In combination with the first aspect, in some embodiments of the first aspect, the target storage area is further used to store historical question-and-answer information corresponding to the same type of dialogue task, and the task type of the same type of dialogue task is the same as the task type of the target dialogue task.

[0012] In combination with the first aspect, in some embodiments of the first aspect, the historical question-and-answer information further includes the serial number of the historical question text.

[0013] In a second aspect, an information generation device is provided for implementing the information generation method of the first aspect above. The information generation device is deployed with a target large language model, and the target large language model is used to generate an answer text based on the question text. The information generation device includes corresponding modules, units, or means for implementing the above method, and the modules, units, or means can be implemented by hardware, software, or by hardware executing corresponding software. The hardware or software includes one or more modules or units corresponding to the above functions.

[0014] In combination with the second aspect, in some embodiments of the second aspect, the device includes: an acquisition module and a processing module; the acquisition module is used to acquire target information; the target information includes the target task identifier of the target dialogue task between the target large language model and the target user and the current question text input by the target user; the processing module is used to determine the historical question-and-answer information of the target dialogue task according to the target task identifier; the historical question-and-answer information includes the feature vector of the historical question text and the feature vector of the historical answer text corresponding to the historical question text; the processing module is further used to generate the current answer text of the current question text according to the historical question-and-answer information and the current question text.

[0015] In combination with the second aspect, in certain embodiments of the second aspect, the processing module is further configured to generate a current answer text for the current question text based on historical Q&A information and the current question text, including: processing the current question text to obtain a feature vector of the current question text; and generating the current answer text based on the historical Q&A information and the feature vector of the current question text.

[0016] In combination with the second aspect, in certain embodiments of the second aspect, the processing module is further configured to: process the current answer text to obtain a feature vector of the current answer text; and store the feature vector of the current question text and the feature vector of the current answer text in a target storage area, where the target storage area is used to store historical Q&A information corresponding to a target dialogue task.

[0017] In combination with the second aspect, in certain embodiments of the second aspect, the processing module is further configured to process the current question text / current answer text to obtain a feature vector of the current question text / current answer text, including: performing text compression and / or text enhancement processing on the current question text / current answer text to obtain a target current question text / target current answer text; and performing vectorization processing on the target current question text / target current answer text to obtain a feature vector of the current question text / current answer text.

[0018] In combination with the second aspect, in certain embodiments of the second aspect, the target storage area is further configured to store historical Q&A information corresponding to a same-type dialogue task, and the task type of the same-type dialogue task is the same as the task type of the target dialogue task.

[0019] In combination with the second aspect, in certain embodiments of the second aspect, the historical Q&A information further includes the serial number of the historical question text.

[0020] In a third aspect, there is provided an information generation device, including: at least one processor and a memory for storing instructions executable by the processor; wherein, the processor is configured to execute the instructions to implement the method provided in the first aspect and any possible implementation manner thereof.

[0021] In a fourth aspect, there is provided a computer-readable storage medium, when the instructions in the computer-readable storage medium are executed by the processor of the information generation device, enabling the information generation device to execute the method provided in the first aspect and any possible implementation manner thereof.

[0022] In a fifth aspect, there is provided a computer program product containing instructions, when it runs on a computer, enabling the computer to execute the method provided in the above-mentioned first aspect and any possible implementation manner thereof.

[0023] Among them, for the technical effects brought by any one of the second to fifth aspects, reference can be made to the technical effects brought by different embodiments of the first aspect above, which will not be elaborated here.

[0024] Based on the solution of the present application, compared with the existing solution that takes the previous question text and the previous answer text in the dialogue task as inputs and processes multiple Q&A texts, the solution of the present application obtains the target task identifier of the target dialogue task between the target large language model and the target user and the target information of the current question text input by the target user. Then, according to the target task identifier, the historical Q&A information including the feature vector of the historical question text and the feature vector of the historical answer text of the target dialogue task is determined. Then, according to the historical Q&A information and the current question text, the current answer text of the current question text is generated. Since the historical Q&A information includes the feature vector of the historical question text and the feature vector of the historical answer text, the target large language model can directly use the feature vectors of the Q&A texts and combine them with the current question text to generate the current Q&A text, without first converting the Q&A texts into feature vectors and then combining them with the current question text to generate the current Q&A text, thus reducing the processing pressure on the large language model. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 It is a schematic structural diagram of an information generation system provided by the present application;

[0026] Figure 2 It is a schematic flowchart of an information generation method provided by the present application;

[0027] Figure 3 It is a schematic flowchart of another information generation method provided by the present application;

[0028] Figure 4 It is a schematic structural diagram of an information generation device provided by the present application;

[0029] Figure 5 It is a schematic structural diagram of another information generation device provided by the present application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0030] In the description of the present application, unless otherwise specified, "a plurality" means two or more than two. "At least one (piece)" or its similar expression refers to any combination of these items, including any combination of single item (piece) or plural items (pieces). For example, at least one (piece) of a, b, or c can represent: a, b, c, a - b, a - c, b - c, or a - b - c, where a, b, c can be single or multiple.

[0031] Meanwhile, in the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a concrete manner for ease of understanding.

[0032] It is understood that the "embodiment" mentioned throughout the specification means that the specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, the various embodiments in the entire specification do not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It is understood that in various embodiments of the present application, the size of the sequence number of each process does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.

[0033] It can be understood that in the present application, "when", "if" and "if" all mean that corresponding processing will be carried out under certain objective circumstances, but do not limit the time, nor do they require judgment actions when implementing them, nor do they mean the existence of other limitations.

[0034] It can be understood that some optional features in the embodiments of the present application may be implemented independently in certain scenarios without relying on other features, such as the solution on which they are currently based, to solve corresponding technical problems and achieve corresponding effects, or may be combined with other features according to needs in certain scenarios. Accordingly, the devices provided in the embodiments of the present application may also realize these features or functions accordingly, which will not be elaborated here.

[0035] In this application, unless otherwise specified, the same or similar parts between the various embodiments can refer to each other. In the various embodiments in this application, and the various implementation methods in each embodiment, if there is no special description and logical conflict, the terms and / or descriptions between different embodiments and the various implementation methods in each embodiment are consistent and can be referenced to each other. The technical features in different embodiments and the various implementation methods in each embodiment can be combined to form new embodiments, implementation methods, implementation methods, or implementation methods according to their inherent logical relationships. The following implementation methods of this application do not constitute a limitation on the scope of protection of this application.

[0036] The Big Language Model is a deep learning model that can process and generate natural language text. After the user enters the question text, the Big Language Model can generate the answer text based on the question text.

[0037] Users can have multiple rounds of conversations with the large language model. That is, the user inputs the first question text, and the large language model can output the first answer text. Then the user inputs the second question text, and the large language model, based on the first question text, the first answer text, and the second question text, inputs the second answer text, and so on.

[0038] During the process of multiple rounds of conversations, every time the user inputs a question text, the previous question text and the previous answer text in the current conversation task need to be used as the input for the large language model. The large language model processes multiple texts to generate the answer text, which results in a relatively large processing pressure on the large language model.

[0039] For example, after the user inputs the first question text, the first question text will be used as the input and input into the large language model. The large language model analyzes and processes the first question text to obtain the first answer text. Subsequently, if the user inputs the second question text, the first question text, the first answer text, and the second question text will be used as the input and input into the large language model. The large language model analyzes and processes the first question text, the first answer text, and the second question text to obtain the second answer text. Subsequently, if the user inputs the third question text, the first question text, the first answer text, the second question text, the second answer text, and the third question text will be used as the input and input into the large language model. The large language model analyzes and processes the first question text, the first answer text, the second question text, the second answer text, and the third question text to obtain the third answer text. Thus, the number of texts that the large language model needs to process is increasing, resulting in a relatively large processing pressure on the large language model.

[0040] To solve the above problems, this application provides an information generation method, which includes: obtaining target information; the target information includes the target task identifier of the target conversation task between the target large language model and the target user and the current question text input by the target user; determining the historical Q&A information of the target conversation task according to the target task identifier; the historical Q&A information includes the feature vectors of the historical question text and the feature vectors of the historical answer text; generating the current answer text of the current question text according to the historical Q&A information and the current question text.

[0041] Based on this solution, compared with the existing solution that processes multiple question-and-answer texts by using the previous question text and the previous answer text in the conversation task as inputs, the solution of this application obtains the target task identifier of the target conversation task between the target large language model and the target user and the target information of the current question text input by the target user. Subsequently, according to the target task identifier, the historical question-and-answer information including the feature vector of the historical question text and the feature vector of the historical answer text of the target conversation task is determined. Subsequently, according to the historical question-and-answer information and the current question text, the current answer text of the current question text is generated. Since the historical question-and-answer information includes the feature vector of the historical question text and the feature vector of the historical answer text, the target large language model can directly use the feature vector of the question-and-answer text and combine it with the current question text to generate the current question-and-answer text, without first converting the question-and-answer text into a feature vector and then combining it with the current question text to generate the current question-and-answer text, thereby reducing the processing pressure on the large language model.

[0042] Figure 1 It is a schematic diagram of the architecture of an information generation system provided by this application. The technical solution of the embodiments of this application can be applied to Figure 1 the information generation system shown in Figure 1 As shown in

[0043] Among them, the information generation device 11 is directly or indirectly connected to the electronic device 12. In this connection relationship, a wired connection or a wireless connection can be adopted, and this application embodiment does not make any limitation on this.

[0044] Data interaction can be carried out between the information generation device 11 and the electronic device 12.

[0045] The information generation device 11 is deployed with a target large language model, and the target large language model is used to generate an answer text based on the question text.

[0046] The target large language model can be a large language model based on Transformer. The target large language model can be ChatGPT, Wenxin Yiyan, etc. This application does not make specific limitations on this.

[0047] It should be noted that the information generation device 11 and the electronic device 12 can be independent devices or integrated into the same device, and this application does not make specific limitations on this.

[0048] When the information generation device 11 and the electronic device 12 are integrated into the same device, the communication method between the information generation device 11 and the electronic device 12 is the communication between internal modules of the device. In this case, the communication process between the two is the same as the "communication process between the information generation device 11 and the electronic device 12 when they are independent of each other".

[0049] In the following embodiments provided by the present application, the present application takes the information generation device 11 and the electronic device 12 being independently arranged as an example for illustration.

[0050] In practical applications, the information generation method provided by the embodiments of the present application can be applied to the information generation device 11 or to the devices included in the information generation device 11.

[0051] Next, in combination with the accompanying drawings, taking the information generation method being applied to the information generation device 11 as an example, the information generation method provided by the embodiments of the present application will be described.

[0052] Figure 2 is a schematic flowchart of an information generation method provided by the present application, as Figure 2 shown, the method includes the following steps:

[0053] S201. The information generation device acquires target information.

[0054] Among them, the target information includes the target task identifier of the target dialogue task between the target large language model and the target user and the current question text input by the target user.

[0055] It should be noted that the target task identifier can be sessionId, and the target task identifier can be determined based on information such as the user identifier of the target user and the triggering moment of the target dialogue task. The present application does not make specific limitations on the form and specific determination method of the target task identifier.

[0056] Exemplarily, the current question text can be "What's the weather like today", "How strong is the wind tomorrow", and the present application does not make specific limitations on this.

[0057] As a possible implementation manner, in combination with Figure 1 , the information generation device receives a message from the electronic device, the message includes the target information, and the information generation device acquires the target information from the message.

[0058] S202. The information generation device determines the historical Q&A information of the target dialogue task according to the target task identifier.

[0059] Among them, the historical Q&A information includes the feature vector of the historical question text and the feature vector of the historical answer text corresponding to the historical question text.

[0060] It should be noted that the historical Q&A information also includes the serial number of the historical question text.

[0061] The serial number can be RequestId.

[0062] For example, if the serial number of a historical question text is 1, it means that this historical question text is the first question text input by the user; if the serial number of a historical question text is 2, it means that this historical question text is the second question text input by the user.

[0063] It can be understood that since there is a corresponding relationship between the question text and the answer text, after determining the serial number of a certain question text, the answer text corresponding to this question text can also be determined.

[0064] Based on this solution, when the historical Q&A information also includes the serial number of the historical question text, the current answer text of the current question text can be generated based on the order of historical Q&A, further improving the accuracy of the current answer text.

[0065] The historical Q&A information can also include information such as the status flag bit of the dialogue task, the timeout duration, the maximum number of sessions, etc., and this application does not make specific restrictions on this.

[0066] It should be noted that when the current question text is not the first question text input by the user, since the user has input question texts before, therefore, there is historical Q&A information for this dialogue task. Through this step, the historical Q&A information of the target dialogue task can be determined, and subsequently, the current answer text of the current question text can be generated based on the historical Q&A information and the current question text.

[0067] When the current question text is the first question text input by the user, since the user has not input question texts before, therefore, there is no historical Q&A information for this dialogue task. Through this step, it is determined that the historical Q&A information of the target dialogue task is a null value, and subsequently, the current answer text of the current question text can be directly generated based on the current question text.

[0068] As a possible implementation, the information generation device searches for the historical Q&A information of the target task identifier in the target storage area.

[0069] It should be noted that the target storage area can store the target task identifier and the historical Q&A information corresponding to the target task identifier.

[0070] The target storage area can be a storage area inside the information generation device, or the target storage area can also be a storage area outside the information generation device. For example, the target storage area can be a storage area in an electronic device, and this application does not make specific restrictions on this.

[0071] In some embodiments, the target storage area is further used to store historical Q&A information corresponding to the same type of dialogue tasks, and the task type of the same type of dialogue tasks is the same as that of the target dialogue task.

[0072] The inside of the target storage device can be divided into multiple sub-storage areas, and one sub-storage area is used to store a dialogue task and the historical Q&A information of the dialogue task.

[0073] The task type can include creative type, summary type, etc., and the present application does not make specific limitations on this.

[0074] Based on this solution, since the target storage area is further used to store historical Q&A information corresponding to the same type of dialogue tasks, and the task type of the same type of dialogue tasks is the same as that of the target dialogue task, the historical Q&A information of dialogue tasks with the same task type can be stored together, which can improve the efficiency of data management for the historical Q&A information of dialogue tasks with the same task type.

[0075] For example, when it is necessary to delete the relevant data of a dialogue task with a creative task type, the storage area storing the data of the dialogue task with a creative task type can be found, and then the data in this storage area can be directly deleted, without searching for the data of each dialogue task with a creative task type in the entire storage space for deletion, thereby improving the efficiency of data management.

[0076] S203. The information generation device generates the current answer text of the current question text according to the historical Q&A information and the current question text.

[0077] As a possible implementation manner, the information generation device processes the current question text to obtain the feature vector of the current question text, and then, according to the historical Q&A information and the feature vector of the current question text, generates the current answer text.

[0078] As an example, the information generation device performs text compression and / or text enhancement processing on the current question text to obtain the target current question text, and then, performs vectorization processing on the target current question text to obtain the feature vector of the current question text, and then, combines a large language model to generate the current answer text according to the feature vector of the current question text and the historical question information.

[0079] Text compression means that the content of the current question text is too long, and by removing the redundant content in the current question text, the current question text is refined. In this way, by performing text compression processing on the current question text, the refinement degree of the feature vector of the current question text can be improved subsequently, the data size of the feature vector can be reduced, and the storage space can be saved.

[0080] Text enhancement refers to the situation where there are problems in the current problem text, such as typos, data errors, data missing, etc. By means of error correction, complementation, etc., the problems in the current problem text are reduced. In this way, by performing text enhancement processing on the current problem text, the data quality of the feature vector of the current problem text can be improved subsequently.

[0081] It should be noted that in this example, for the specific description of vectorizing the target current answer text and generating the current answer text based on the feature vector of the current problem text and historical problem information, reference can be made to existing solutions, which will not be elaborated in this application.

[0082] Based on this solution, compared with the existing solution that takes the previous question text and the previous answer text in the dialogue task as inputs and processes multiple Q&A texts, the solution of this application obtains the target task identifier of the target dialogue task between the target large language model and the target user and the target information of the current problem text input by the target user. Then, according to the target task identifier, the historical Q&A information including the feature vector of the historical question text and the feature vector of the historical answer text of the target dialogue task is determined. Then, according to the historical Q&A information and the current problem text, the current answer text of the current problem text is generated. Since the historical Q&A information includes the feature vector of the historical question text and the feature vector of the historical answer text, the target large language model can directly use the feature vector of the Q&A text and combine it with the current problem text to generate the current Q&A text, without first converting the Q&A text into a feature vector and then combining it with the current problem text to generate the current Q&A text, thereby reducing the processing pressure on the large language model.

[0083] The above is a general description of the information generation method provided by this application. Next, the information generation method provided by this application will be further described with reference to the accompanying drawings.

[0084] In one design, Figure 3 is a schematic flowchart of another information generation method provided by this application. As Figure 3 shown, after S203, the information generation method provided by this application may further include the following multiple steps:

[0085] S301: The information generation device processes the current answer text to obtain the feature vector of the current answer text.

[0086] As a possible implementation, the information generation device performs text compression and / or text enhancement processing on the current answer text to obtain the target current answer text, and then performs vectorization processing on the target current answer text to obtain the feature vector of the current answer text.

[0087] For the specific description of text compression and text enhancement, reference can be made to the relevant description in S203 above, which will not be elaborated in this application.

[0088] It should be noted that the specific description of the vectorization process of the target current answer text in this example can refer to existing solutions, which will not be elaborated in this application.

[0089] S302. The information generation device stores the feature vector of the current question text and the feature vector of the current answer text in the target storage area.

[0090] Among them, the target storage area is used to store the historical Q&A information corresponding to the target dialogue task.

[0091] As a possible implementation, after the information generation device performs Q&A binding on the feature vector of the current question text and the feature vector of the current answer text, it stores them in the target storage area.

[0092] It should be noted that performing Q&A binding on the feature vector of the current question text and the feature vector of the current answer text can establish a corresponding relationship between the feature vector of the current question text and the feature vector of the current answer text. After the feature vector of the question text is determined subsequently, the corresponding feature vector of the answer text can also be determined, or after the feature vector of the answer text is determined subsequently, the corresponding feature vector of the question text can also be determined.

[0093] Based on this solution, by processing the current answer text, the feature vector of the current answer text is obtained. Subsequently, the feature vector of the current question text and the feature vector of the current answer text are stored in the target storage area, and the target storage area is used to store the historical Q&A information corresponding to the target dialogue task. After the target user inputs the question text again, the feature vector of the question text and the feature vector of the answer text input by the target user historically can be obtained.

[0094] The above mainly introduces the solution provided by the embodiments of the present application from the perspective of the information generation device executing the information generation method. To implement the above functions, the information generation device includes the corresponding hardware structure and / or software module for executing each function. Those skilled in the art should easily realize that, combined with the units and algorithm steps of each example described in the embodiments disclosed in this article, the embodiments of the present application can be implemented in the form of hardware or a combination of hardware and computer software. Whether a certain function is executed in the way of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional technicians can use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the present application.

[0095] Embodiments of the present application can divide the information generation device into functional modules according to the above method examples. For example, each functional module can be divided corresponding to each function, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware or in the form of a software functional module. Optionally, the division of modules in the embodiments of the present application is illustrative, only a logical function division, and there may be other division methods in actual implementation. In addition, the "module" here can refer to a specific application-specific integrated circuit (ASIC), a circuit, a processor and a memory that execute one or more software or firmware programs, an integrated logic circuit, and / or other devices that can provide the above functions.

[0096] In the case of functional module division, Figure 4 A schematic structural diagram of an information generation device is shown. As Figure 4 shown, the information generation device 40 includes an acquisition module 401 and a processing module 402.

[0097] In some embodiments, the information generation device 40 may further include a storage module ( Figure 4 not shown in the figure) for storing program instructions and data.

[0098] Among them, the acquisition module 401 is used to acquire target information; the target information includes the target task identifier of the target dialogue task between the target large language model and the target user and the current question text input by the target user; the processing module 402 is used to determine the historical Q&A information of the target dialogue task according to the target task identifier; the historical Q&A information includes the feature vector of the historical question text and the feature vector of the historical answer text corresponding to the historical question text; the processing module 402 is further used to generate the current answer text of the current question text according to the historical Q&A information and the current question text.

[0099] Optionally, the processing module 402 is further used to generate the current answer text of the current question text according to the historical Q&A information and the current question text, including: processing the current question text to obtain the feature vector of the current question text; generating the current answer text according to the historical Q&A information and the feature vector of the current question text.

[0100] Optionally, the processing module 402 is further used to: process the current answer text to obtain the feature vector of the current answer text; store the feature vector of the current question text and the feature vector of the current answer text in the target storage area, and the target storage area is used to store the historical Q&A information corresponding to the target dialogue task.

[0101] Optionally, the processing module 402 is further configured to process the current question text / current answer text to obtain the feature vector of the current question text / current answer text, including: performing text compression and / or text enhancement processing on the current question text / current answer text to obtain the target current question text / target current answer text; performing vectorization processing on the target current question text / target current answer text to obtain the feature vector of the current question text / current answer text.

[0102] Optionally, the target storage area is further configured to store the historical question-and-answer information corresponding to the same type of dialogue task, and the task type of the same type of dialogue task is the same as that of the target dialogue task.

[0103] Optionally, the historical question-and-answer information further includes the serial number of the historical question text.

[0104] All relevant contents of each step involved in the above method embodiments can be cited in the function description of the corresponding functional module, and will not be elaborated here.

[0105] In the case of implementing the functions of the above functional modules in the form of hardware Figure 5 shows a schematic structural diagram of another information generation device. As Figure 5 shown, the information generation device 50 includes a processor 501, a memory 502, and a bus 503. The processor 501 and the memory 502 can be connected through the bus 503.

[0106] The processor 501 is the control center of the information generation device 50, and can be a single processor or a collective term for multiple processing elements. For example, the processor 501 can be a general-purpose central processing unit (CPU), or other general-purpose processors. Among them, the general-purpose processor can be a microprocessor or any conventional processor, etc.

[0107] As an embodiment, the processor 501 may include one or more CPUs, such as Figure 5 the CPU0 and CPU1 shown in

[0108] The memory 502 can be a read-only memory (ROM) or other types of static storage devices that can store static information and instructions, a random access memory (RAM) or other types of dynamic storage devices that can store information and instructions, or it can also be an electrically erasable programmable read-only memory (EEPROM), a magnetic disk storage medium or other magnetic storage devices, or any other medium that can be used to carry or store the desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto.

[0109] As a possible implementation, the memory 502 can exist independently of the processor 501. The memory 502 can be connected to the processor 501 through the bus 503 for storing instructions or program code. When the processor 501 calls and executes the instructions or program code stored in the memory 502, the information generation method provided by the embodiments of the present application can be implemented.

[0110] In another possible implementation, the memory 502 can also be integrated with the processor 501.

[0111] The bus 503 can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, etc. This bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, Figure 5 only a thick line is shown here, but it does not mean that there is only one bus or one type of bus.

[0112] It should be noted that Figure 5 the structure shown does not constitute a limitation on the information generation device 50. Except Figure 5 for the components shown, the information generation device 50 can include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0113] As an example, in combination with Figure 4 , the functions implemented by the acquisition module 401 and the processing module 402 in the information generation device 40 are the same as Figure 5 the functions of the processor 501 in

[0114] Optionally, asFigure 5 As shown in Figure 5 , the information generation device 50 provided in the embodiment of the present application may further include a communication interface 504.

[0115] The communication interface 504 is used to connect to other devices through a communication network. The communication network may be an Ethernet, a radio access network, a wireless local area network (WLAN), etc. The communication interface 504 may include a receiving unit for receiving data and a sending unit for sending data.

[0116] In a possible implementation manner, in the information generation device 50 provided in the embodiment of the present application, the communication interface 504 may also be integrated in the processor 501. The embodiment of the present application does not make specific limitations on this.

[0117] As a possible product form, the information generation device in the embodiment of the present application may also be implemented by using the following: one or more field programmable gate arrays (FPGAs), programmable logic devices (PLDs), controllers, state machines, gate logics, discrete hardware components, any other suitable circuits, or any combination of circuits capable of performing various functions described throughout the present application.

[0118] Through the description of the above embodiments, those skilled in the art can clearly understand that, for the convenience and simplicity of description, only the above division of each functional unit is used as an example for illustration. In actual applications, the above functions may be allocated to different functional units according to needs, that is, the internal structure of the device is divided into different functional units to complete all or part of the functions described above. The specific working processes of the systems, devices, and units described above may refer to the corresponding processes in the foregoing method embodiments and will not be elaborated herein.

[0119] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program or instruction is stored. When the computer program or instruction is executed, the computer executes each step in the method flow shown in the foregoing method embodiment.

[0120] The embodiment of the present application provides a computer program product containing instructions. When the instructions run on a computer, the computer executes each step in the method flow shown in the foregoing method embodiment.

[0121] An embodiment of the present application provides a chip system, including: a processor and an interface circuit; the interface circuit is configured to receive a computer program or instruction and transmit it to the processor; the processor is configured to execute the computer program or instruction so that the chip system executes each step in the method flow shown in the above method embodiment.

[0122] Among them, a computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples (non-exhaustive list) of computer-readable storage media include: an electrical connection having one or more wires, a portable computer disk, a hard disk. Random Access Memory (RAM), Read-Only Memory (ROM), Erasable Programmable Read Only Memory (EPROM), registers, hard disks, optical fibers, portable compact disc read-only memory (Compact Disc Read-Only Memory, CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the above, or any other form of computer-readable storage medium known in the art. An exemplary storage medium is coupled to the processor so that the processor can read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in a specific-purpose ASIC. In the embodiments of the present application, a computer-readable storage medium can be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.

[0123] Since the information generation device, computer-readable storage medium, and computer program product provided in this embodiment can be applied to the information generation method provided in the above, the technical effects that can be obtained can also refer to the above method embodiment, and the embodiments of the present application will not be elaborated herein.

[0124] Although the present application has been described in conjunction with various embodiments herein, however, in the process of implementing the claimed present application, those skilled in the art can understand and implement other variations of the disclosed embodiments by viewing the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other components or steps, and "a" or "one" does not exclude a plurality. A single processor or other unit can implement several functions recited in the claims. Certain measures are recited in mutually different dependent claims, but this does not mean that these measures cannot be combined to produce good results.

[0125] Although the present application has been described in connection with specific features and their embodiments, it will be apparent that various modifications and combinations can be made thereto without departing from the spirit and scope of the present application. Accordingly, the present specification and the drawings are merely exemplary illustrations of the present application as defined by the appended claims, and are considered to have covered any and all modifications, variations, combinations or equivalents within the scope of the present application. Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalent technologies, the present application is also intended to include these changes and modifications.

Claims

1. A method for generating information, characterized in that: The method is applied to an information generating device, wherein the information generating device is equipped with a target large language model, wherein the target large language model is used to generate an answer text based on a question text, and the method comprises: Acquire target information; the target information includes a target task identifier of a target dialogue task between the target large language model and a target user and a current question text input by the target user; Determine the historical question and answer information of the target dialogue task according to the target task identifier; the historical question and answer information includes a feature vector of a historical question text and a feature vector of a historical answer text corresponding to the historical question text; A current answer text of the current question text is generated according to the historical question and answer information and the current question text.

2. The method according to claim 1, characterized in that The step of generating a current answer text of the current question text according to the historical question and answer information and the current question text comprises: Processing the current question text to obtain a feature vector of the current question text; The current answer text is generated according to the historical question and answer information and the feature vector of the current question text.

3. The method according to claim 2, characterized in that The method further comprises: Processing the current answer text to obtain a feature vector of the current answer text; The feature vector of the current question text and the feature vector of the current answer text are stored in a target storage area, where the target storage area is used to store historical question and answer information corresponding to the target dialogue task.

4. The method according to claim 3, characterized in that: Processing the current question text / the current answer text to obtain a feature vector of the current question text / the current answer text includes: Performing text compression and / or text enhancement processing on the current question text / the current answer text to obtain a target current question text / target current answer text; The target current question text / the target current answer text is vectorized to obtain a feature vector of the current question text / the current answer text.

5. The method according to claim 3, characterized in that: The target storage area is also used to store historical question and answer information corresponding to the same type of dialogue tasks, and the task type of the same type of dialogue tasks is the same as the task type of the target dialogue task.

6. The method according to any one of claims 1 to 5, characterized in that: The historical question and answer information also includes the serial number of the historical question text.

7. An information generating device, characterized in that: The information generating device is deployed with a target large language model, and the target large language model is used to generate an answer text based on a question text. The device includes: an acquisition module and a processing module; The acquisition module is used to acquire target information; the target information includes a target task identifier of a target dialogue task between the target large language model and a target user and a current question text input by the target user; The processing module is used to determine the historical question and answer information of the target dialogue task according to the target task identifier; the historical question and answer information includes a feature vector of a historical question text and a feature vector of a historical answer text corresponding to the historical question text; The processing module is also used to generate a current answer text for the current question text based on the historical question and answer information and the current question text.

8. The device according to claim 7, characterized in that The processing module is further used to generate a current answer text of the current question text according to the historical question and answer information and the current question text, including: Processing the current question text to obtain a feature vector of the current question text; The current answer text is generated according to the historical question and answer information and the feature vector of the current question text.

9. An information generating device, characterized in that: The information generating device comprises: a processor, the processor is coupled to a memory, the memory is used to store programs or instructions, when the program or instructions are executed by the processor, the device executes the method according to any one of claims 1 to 6.

10. A computer-readable storage medium having a computer program or instruction stored thereon, characterized in that: When the computer program or instructions are executed, the computer is caused to perform the method according to any one of claims 1 to 6.