Interactive content storage calling method and device for cue word engineering

By building a memory database and retrieving relevant interactive memory information, the problem that big models are difficult to understand user intentions is solved, and more accurate and useful feedback results are achieved.

CN119396883APending Publication Date: 2025-02-07LONGTEL INC
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411517617.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-29
Publication Date
2025-02-07

AI Technical Summary

Technical Problem

The existing prompt word project is difficult to help the big model fully understand the user's intentions, resulting in the feedback results obtained by the user being unsatisfactory.

Method used

By recalling relevant memory information when the user interacts with the big model, a memory database is built to store and call historical interaction data, helping the big model better understand user intentions.

Benefits of technology

The big model is implemented to better understand user intentions, thereby providing more accurate and useful feedback results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119396883A_ABST
    Figure CN119396883A_ABST
Patent Text Reader

Abstract

The invention provides an interactive content storage and calling method and device for cue word engineering, belongs to the technical field of cue word engineering, and is used for solving the problem that intelligent cue word engineering is difficult to fully understand user intentions in related technologies. And a related typical historical interaction process is called when the user interacts with the large model, so that a historical data reference is provided for the large model to understand the intention of the user, and the large model can understand the intention of the user more sufficiently.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of prompt word engineering, and in particular to a method and device for storing and calling interactive content for prompt word engineering. Background Art

[0002] With the development and widespread application of big model technology, how to better achieve interaction with big models has become an important research topic in the field of big models, and prompt word engineering has emerged. The general purpose of prompt word engineering is to analyze the text or context information input by the user, predict and provide the most likely subsequent words or phrases to help users quickly complete input or generate high-quality text content. Of course, helping users quickly complete input and generate high-quality text content can make the text sent by users to big models higher in quality, but it is of limited help to the big model in fully understanding the user's intentions. Summary of the invention

[0003] The present application provides an interactive content storage and calling method and device for prompt word engineering, which is conducive to the large model to fully understand the user's intention, thereby facilitating the user to obtain more needed feedback results from the large model.

[0004] In a first aspect, the present application provides a method for storing and calling interactive content for a prompt word project. The method comprises: when a user sends interactive instruction information to a large model, calling up memory information related to the interactive instruction information; The memory information related to the interaction instruction information is retrieved including: Based on the interaction instruction information, relevant memory information is retrieved from a pre-built memory database, wherein the memory database includes interaction memory examples, and the interaction memory examples include historical interaction instructions, historical structured instructions, historical large model feedback, and historical user feedback. The relevant memory information is interaction memory examples in which the similarity between the historical interaction instructions and the interaction instruction information is higher than a similarity threshold.

[0005] By adopting the above technical solution, it is possible to achieve selective memory of the interaction process between the user and the large model and to retrieve relevant memory information when new interaction instructions arrive, so that the large model can use the relevant memory information to more fully understand the user's intentions, thereby facilitating the user to obtain more needed feedback results from the large model.

[0006] Furthermore, the method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data according to the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

[0007] Further, determining typical historical data based on the tendency data and a preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of the preset tendency range is less than a preset distance as typical historical data.

[0008] Further, for each user identifier, determining that the typical historical data is a long-term memory example in the long-term memory database or a short-term memory example in the short-term memory database includes: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

[0009] Further, the determining of the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback includes: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

[0010] In a second aspect, the present application provides an interactive content storage and calling device for the intelligent prompt word function. The device includes a state recognition module and a memory calling module; The state recognition module is used to recognize the state of the user sending interaction instruction information to the large model; The memory retrieval module is used to retrieve the memory information related to the interactive instruction information; The memory retrieval module is further configured to: based on the interaction instruction information, retrieve relevant memory information in a pre-built memory database, the memory database including interaction memory examples, the interaction memory examples including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the relevant memory information is an interaction memory example in which the similarity between the historical interaction instructions and the interaction instruction information is higher than a similarity threshold.

[0011] Furthermore, the memory retrieval module is further configured as follows: the method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data according to the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

[0012] Furthermore, the memory retrieval module is further configured such that determining typical historical data based on the tendency data and a preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of a preset tendency range is less than a preset distance as typical historical data.

[0013] Furthermore, the memory retrieval module is further configured to: for each user identifier, determining that the typical historical data is a long-term memory example in the long-term memory database or a short-term memory example in the short-term memory database includes: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

[0014] Furthermore, the memory retrieval module is further configured to determine the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback, including: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

[0015] In summary, this application at least has the following beneficial effects: A method and device for storing and calling interactive content for a prompt word project is provided, which helps the big model to more fully understand the user's intention by storing the memory of the typical interaction process between the user and the big model and calling the relevant memory when a new interaction instruction arrives.

[0016] It should be understood that the contents described in the Summary of the Invention are not intended to limit the key or important features of the embodiments of the present application, nor are they intended to limit the scope of the present application. Other features of the present application will become easily understood through the following description. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The above and other features, advantages and aspects of the embodiments of the present application will become more apparent with reference to the following detailed description in conjunction with the accompanying drawings. In the accompanying drawings, the same or similar reference numerals represent the same or similar elements, wherein: Figure 1 A flowchart of a method for storing and calling interactive content for a prompt word project in an embodiment of the present application is shown; Figure 2 A flow chart of a method for intelligently generating prompt words in an embodiment of the present application is shown; Figure 3 A block diagram of an interactive content storage and calling device for an intelligent prompt word function in an embodiment of the present application is shown. DETAILED DESCRIPTION

[0018] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0019] In addition, the term "and / or" in this article is only a description of the association relationship between the associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.

[0020] The present application provides a method and device for storing and calling interactive content for prompt word engineering, which helps the big model to more fully understand the user's intention by storing the memory of the typical interaction process between the user and the big model and calling the relevant memory when new interaction instructions arrive.

[0021] In a first aspect, the present application provides an interactive content storage and calling method for a prompt word project. The method can be executed by a server.

[0022] Figure 1 A flow chart of a method for storing and calling interactive content for a prompt word project in an embodiment of the present application is shown.

[0023] Reference Figure 1 , the method specifically comprises the following steps: S110: Identify the state in which the user sends interactive instruction information to the large model; S120: Retrieve the memory information related to the interaction instruction information.

[0024] Specifically, the method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data according to the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

[0025] In one example, determining typical historical data based on the tendency data and a preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of the preset tendency range is less than a preset distance as typical historical data.

[0026] In one example, for each user identifier, determining that the typical historical data is a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database includes: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

[0027] In one example, determining the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback includes: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

[0028] Furthermore, in order to more conveniently introduce how interactive content storage calls can assist the large model to more fully understand user intentions, the embodiment of the present application introduces the overall method of intelligently generating prompt words. The interactive content storage call method used for prompt word engineering in this application is a key step in the method.

[0029] Figure 2 A flow chart of a method for intelligently generating prompt words in an embodiment of the present application is shown; Reference Figure 2 , the method specifically comprises the following steps: S210: Acquire interaction instruction information sent by the user.

[0030] The interactive instruction information sent by the user refers to the instruction information input by the user and desired to be sent to the big model to interact with the big model. The interactive instruction information is required to be converted into natural language text for subsequent use. Of course, the instructions initially sent by the user may be in various forms such as audio, pictures, and files. The instructions initially sent by the user can be converted into natural language text using technologies such as audio to text, picture to text, or picture interpretation and understanding, and file content extraction.

[0031] The user's interactive command information also needs to be pre-processed, and the preset emotional rules are used to filter the interactive command information for intent, personality abstraction, ethical review, simulation exclusion, etc., to ensure that the interactive command information is an instruction that can be received and answered by the big model. Of course, pre-processing also includes operations such as information trajectory, information analysis, role understanding, and goal understanding of the interactive command information to ensure that the interactive command information is clarified, that is, the interactive command information used later contains clear and complete meanings.

[0032] S220: Retrieve the memory information related to the interaction instruction information.

[0033] The method of this step can refer to the detailed introduction of the interactive content storage and calling method for the prompt word project in the above-mentioned embodiment of the present application, and will not be repeated here.

[0034] S230: Generate a planning conversion plan according to the interactive instruction information and related memory information.

[0035] The method of this step specifically includes: substituting the interactive instruction information into a pre-constructed graphical thinking chain model to obtain multiple intention interpretation paths, and determining multi-dimensional scoring standard data for each intention interpretation path; determining the fit data of each intention interpretation path and related memory information; determining the evaluation value data of each intention interpretation path based on the scoring standard data and the fit data; determining the intention interpretation path with the highest evaluation value data as the optimal interpretation path, and determining the planning conversion plan based on the optimal interpretation path.

[0036] The scoring standard data includes efficiency data, cost data and risk data.

[0037] In the method of this step, determining the evaluation value data of each intention interpretation path according to the scoring standard data and the fitting degree data includes: for each intention interpretation path, Determine a path scoring base value according to the scoring standard data; Determining a memory influence coefficient according to the relevant memory information; Determine the evaluation value data according to the path scoring base value and the memory influence coefficient; Determining the memory influence coefficient according to the relevant memory information includes: If the distance between the tendency data of the relevant memory information and the negative limit of the preset tendency range is less than the preset distance, the tendency coefficient of the relevant memory information is -1; if the distance between the tendency data of the relevant memory information and the positive limit of the preset tendency range is less than the preset distance, the tendency coefficient of the relevant memory information is 1; Assume that there are m pieces of relevant memory information with a tendency coefficient of 1, and the fitting data of the i-th piece and the intention interpretation path is , there are n pieces of relevant memory information with a tendency coefficient of -1, and the fitting data of the jth piece and the intention interpretation path is , the memory influence coefficient of the intention interpretation path is p, then , where is the preset fit; Determining the evaluation value data according to the path scoring base value and the memory influence coefficient includes: Assume that the path score base value is , the evaluation value data is z, then .

[0038] Determining the planning conversion scheme according to the optimal interpretation path includes: Analyze the optimal interpretation path to obtain multiple key intent elements; Based on a pre-constructed element framework table, a formatting framework is obtained according to the key intention elements, wherein the element framework table includes a correspondence relationship between the key intention elements and the formatting framework; The planning conversion scheme includes the optimal interpretation path and the formatting framework.

[0039] S240: Generate structured instruction information according to the planned conversion scheme and the interactive instruction information.

[0040] The structured instruction information is used to be sent to the large model, and can also be provided to the user for confirmation and then sent to the large model.

[0041] The method of this step includes: using the planning conversion scheme to convert the interactive instruction information into formatted text information; Based on the pre-built structured conversion rules, the instruction structured scheme information is generated according to the formatted text information; Input the instruction structured scheme into the large model to obtain the structural input feedback of the large model; Directly input the interactive instruction information into the large model to obtain direct quasi-input feedback from the large model; Comparing the similarity between the structured quasi-input feedback and the direct quasi-input feedback, determining the instruction structuring scheme with a similarity higher than the quasi-input similarity threshold as an alternative conversion scheme; Determine the preference data of the alternative conversion schemes based on the relevant memory information; The candidate conversion scheme with the highest priority data is determined as the preferred conversion scheme, and the instruction structured scheme information of the preferred conversion scheme is the structured instruction information.

[0042] In summary, the method for intelligently generating prompt words can fully understand and verify the intention behind the interactive instruction information sent by the user, and then send the structured instruction information that clearly and completely expresses the user's intention to the large model. The large model is more likely to understand the structured instruction information, and is more likely to return the feedback results required by the user. The interactive content storage and calling method used for the prompt word project is conducive to storing and retrieving historical interactive content that is more valuable and more helpful for understanding the intention of the interactive instruction information, which is conducive to supporting the good implementation of the method for intelligently generating prompt words, and is also conducive to making it easier for the large model to understand the structured instruction information.

[0043] It should be noted that, for the aforementioned method embodiments, for the sake of simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that the present application is not limited by the described order of actions, because according to the embodiments of the present application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily required by the present application.

[0044] In a second aspect, the present application provides an interactive content storage and calling device for an intelligent prompt word function. The device may be included in a server.

[0045] Figure 3 A block diagram of an interactive content storage and calling device for an intelligent prompt word function in an embodiment of the present application is shown.

[0046] Reference Figure 3 , the device specifically includes a state recognition module and a memory retrieval module; The state recognition module is used to recognize the state of the user sending interaction instruction information to the large model; The memory retrieval module is used to retrieve the memory information related to the interactive instruction information; The memory retrieval module is further configured to: based on the interaction instruction information, retrieve relevant memory information in a pre-built memory database, the memory database including interaction memory examples, the interaction memory examples including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the relevant memory information is an interaction memory example in which the similarity between the historical interaction instructions and the interaction instruction information is higher than a similarity threshold.

[0047] Furthermore, the memory retrieval module is further configured as follows: the method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data according to the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

[0048] Furthermore, the memory retrieval module is further configured such that determining typical historical data based on the tendency data and a preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of a preset tendency range is less than a preset distance as typical historical data.

[0049] Furthermore, the memory retrieval module is further configured to: for each user identifier, determining that the typical historical data is a long-term memory example in the long-term memory database or a short-term memory example in the short-term memory database includes: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

[0050] Furthermore, the memory retrieval module is further configured to determine the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback, including: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

[0051] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the described device can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.

[0052] In summary, this application at least has the following beneficial effects: A method and device for storing and calling interactive content for a prompt word project is provided, which helps the big model to more fully understand the user's intention by storing the memory of the typical interaction process between the user and the big model and calling the relevant memory when a new interaction instruction arrives.

[0053] The above description is only a preferred embodiment of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of disclosure involved in the present application is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the aforementioned disclosed concept. For example, the above features are replaced with the technical features with similar functions disclosed in this application (but not limited to) by each other to form a technical solution.

Claims

1. A method for storing and calling interactive content for a prompt word project, characterized in that: include: When the user sends interaction instruction information to the large model, the memory information related to the interaction instruction information is retrieved; The memory information related to the interaction instruction information is retrieved including: Based on the interaction instruction information, relevant memory information is retrieved from a pre-built memory database, wherein the memory database includes interaction memory examples, and the interaction memory examples include historical interaction instructions, historical structured instructions, historical large model feedback, and historical user feedback. The relevant memory information is interaction memory examples in which the similarity between the historical interaction instructions and the interaction instruction information is higher than a similarity threshold.

2. The interactive content storage and calling method for prompt word engineering according to claim 1, characterized in that: The method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data based on the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

3. The interactive content storage and calling method for prompt word engineering according to claim 2, characterized in that: Determining typical historical data according to the tendency data and the preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of the preset tendency range is less than a preset distance as typical historical data.

4. The interactive content storage and calling method for prompt word engineering according to claim 2, characterized in that: The step of determining, for each user identifier, that the typical historical data is a long-term memory example in the long-term memory database or a short-term memory example in the short-term memory database comprises: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

5. The interactive content storage and calling method for prompt word engineering according to claim 2, characterized in that: The determining of the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback includes: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

6. An interactive content storage and calling device for intelligent prompt word function, characterized in that: It includes a state recognition module and a memory retrieval module; The state recognition module is used to recognize the state of the user sending interaction instruction information to the large model; The memory retrieval module is used to retrieve the memory information related to the interactive instruction information; The memory retrieval module is further configured to: based on the interaction instruction information, retrieve relevant memory information in a pre-built memory database, the memory database including interaction memory examples, the interaction memory examples including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the relevant memory information is an interaction memory example in which the similarity between the historical interaction instructions and the interaction instruction information is higher than a similarity threshold.

7. The interactive content storage and calling device for intelligent prompt word function according to claim 6, characterized in that: The memory retrieval module is further configured as follows: the method for constructing the memory database includes: Acquire historical interaction data, the historical interaction data including historical interaction instructions, historical structured instructions, historical large model feedback and historical user feedback, the historical interaction data carrying a timestamp and a user identifier; Determine the tendency data of each historical interaction data according to the historical big model feedback and the historical user feedback, wherein the tendency data represents the degree of understanding of the big model to the user intention corresponding to the historical interaction instruction; Determining typical historical data based on the tendency data and a preset tendency range; For each user identifier, typical historical data is determined as a long-term memory example in a long-term memory database or a short-term memory example in a short-term memory database; the short-term memory database and the long-term memory database constitute the memory database, and the long-term memory examples and the short-term memory examples constitute the interactive memory examples as a whole.

8. The interactive content storage and calling device for intelligent prompt word function according to claim 6, characterized in that: The memory retrieval module is further configured such that determining typical historical data based on the tendency data and a preset tendency range includes: determining historical interaction data whose distance between the tendency data and a negative limit or a positive limit of the preset tendency range is less than a preset distance as typical historical data.

9. The interactive content storage and calling device for intelligent prompt word function according to claim 6, characterized in that: The memory retrieval module is further configured to: for each user identifier, determining that the typical historical data is a long-term memory example in the long-term memory database or a short-term memory example in the short-term memory database includes: For each user identifier, the typical historical data and the corresponding tendency data are substituted into a pre-constructed short-term forgetting curve model to determine the memory state data of each typical historical data, wherein the short-term forgetting curve model includes a memory state base value and a forgetting ratio curve, and the memory state base value of the historical interaction data is positively correlated to the absolute value of the difference between the corresponding tendency data and the median of the tendency range; storing the historical interaction data whose memory state data is higher than a preset memory ratio threshold as a short-term memory example in a short-term memory database, and updating the memory state data of the short-term memory example in real time; Historical interaction data in which the user identifier and historical structured instructions are identical and the similarity between the historical large model feedback and the historical user feedback is higher than a preset similarity is judged to be the same historical interaction data; if the proportion of time in which the historical interaction data exists in the short-term memory database within a preset time length is higher than a preset time proportion threshold, the historical interaction data is stored in the long-term memory database as a long-term memory example, and the long-term forgetting curve model is memorized to update the memory state data of the long-term memory example.

10. The interactive content storage and calling device for intelligent prompt word function according to claim 7, characterized in that: The memory retrieval module is further configured to determine the tendency data of each historical interaction data according to the historical large model feedback and the historical user feedback, including: Analyze historical user feedback to determine whether the historical user feedback contains subsequent interaction instructions within a preset interaction interval; If not, determining the propensity data to be a preset propensity value; If so, the feedback consistency information, feedback tendency information and feedback emotion information of the first subsequent interaction instruction within the preset interaction interval are analyzed. The feedback consistency information reflects whether the historical user feedback is consistent with the historical large model feedback. The feedback tendency information reflects whether the historical user feedback is positive feedback or negative feedback to the historical large model feedback. The feedback emotion information reflects the emotional color carried by the historical user feedback. The tendency data is determined based on the feedback consistency information, feedback tendency information and feedback emotion information.

Citation Information

Cited By

  • Cue word generation method and system based on user habits and documents

    CN121478946A