Multi-round dialogue processing method based on RAG technology dynamic cue word retrieval

By adopting a dynamic prompt word search method based on RAG technology in multiple rounds of dialogue processing, the shortcomings of traditional models in the history of fusion of RAG technology and tracking dialogue are solved, and more accurate and useful answers and more efficient computing resource utilization are achieved.

CN119538918AInactive Publication Date: 2025-02-28林志成 +1
View PDF 0 Cites 6 Cited by

Patent Information

Application Number
CN202411594717.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-10
Publication Date
2025-02-28
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Traditional large language models are difficult to effectively integrate RAG technology in multiple rounds of dialogue processing, resulting in limited knowledge, high computing resources consumption, and as dialogue rounds increase, the model may forget the dialogue content, and the generated answers are inconsistent with the dialogue history.

Method used

Using a dynamic prompt word search method based on RAG technology, the pre-trained Faiss vector search model searches related documents from the knowledge base, dynamically generates prompt words, combines large language models to generate more accurate answers, and retains dialogue historical context information through the pre-trained Transformer encoder.

Benefits of technology

Improves the accuracy and usefulness of the answers, enhances the model's ability to track conversation history and context, reduces computational costs, improves processing efficiency, and optimizes model performance through online learning and feedback.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119538918A_ABST
    Figure CN119538918A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of multi-round dialogue processing, in particular to a multi-round dialogue processing method based on RAG technology dynamic cue word retrieval. Comprising the following steps of question input by a user, initial retrieval and cue word generation, question splicing and answer generation, historical dialogue management and context coding, multi-round question analysis and retrieval enhancement, complex question decomposition and parallel retrieval, multi-source information fusion and generation model optimization, iterative feedback and model tuning, and exception handling and fault-tolerant mechanism. According to the method, related information is retrieved from an external knowledge base, the model can utilize wider and more specific knowledge to generate answers and better track dialogue history and context, so that answers consistent and coherent with the dialogue history are generated, the model can generate answers on a short input sequence by retrieving and splicing related cue words, and meanwhile, the model can be used for analyzing the dialogue history. Cue words are dynamically generated according to user input and retrieval results, so that the model can better adapt to different dialogue scenes and user requirements.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of multi-round dialogue processing, and in particular to a multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval. Background Art

[0002] RAG (Retrieval-Augmented Generation) is a technology that combines information retrieval and text generation. In natural language processing tasks, especially dialogue systems, RAG technology enhances the output of the generative model by retrieving relevant information from external knowledge bases. This method enables the generative model to utilize broader and more specific knowledge, thereby generating more accurate and useful answers.

[0003] Generally, traditional large language models (such as the GPT series) cannot integrate RAG technology well in multi-round dialogue processing, but rely on model internal parameters and memory to track dialogue history and context, resulting in knowledge limitations in the method of learning how to generate coherent and relevant answers based on previous dialogue content through training. The model's knowledge mainly comes from training data. For information or knowledge that has not appeared in the training data, the model may not be able to accurately answer. As the number of dialogue rounds increases, the model may gradually forget the previous dialogue content, resulting in inconsistent answers with the dialogue history. In order to maintain the dialogue history and context, the model needs to consume a lot of computing resources.

[0004] In summary, it is necessary to propose a multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval to solve the above problems. Summary of the invention

[0005] The purpose of the present invention is to provide a multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval to solve the problems raised in the above background technology.

[0006] To achieve the above object, the present invention provides the following technical solutions:

[0007] A multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval includes the following steps:

[0008] S1. The user enters the first question and starts the conversation process;

[0009] S2. Use the pre-trained Faiss vector retrieval model to retrieve relevant document fragments from the knowledge base according to the user's question, dynamically generate one or more prompt words based on the retrieved document content, and use the prompt words to guide the subsequent generation model to understand the question context more accurately;

[0010] S3. concatenate the user question with the dynamically generated prompt words and input them into the large language model to generate the first round of answers;

[0011] S4. Save the user questions and generated answers to the historical dialogue set, and use the pre-trained Transformer encoder to encode the entire dialogue history to preserve contextual information;

[0012] S5. Use the question conversion model to analyze whether the newly input question has a matching relationship with the historical dialogue set, including the relevance of the question subject and the answer content. If there is a match, generate an enhanced search query based on the historical dialogue to improve the search accuracy;

[0013] S6. For complex questions, use the question decomposition algorithm to decompose them into multiple sub-questions, and retrieve relevant documents for each sub-question in parallel;

[0014] S7. Integrate the information from direct retrieval, historical dialogue, and question decomposition retrieval as the input of the generative model, and use the attention mechanism to optimize the generative model so that the model can more reasonably use multi-source information to generate coherent and informative answers;

[0015] S8. Collect user feedback through online learning or simulated dialogue environment, and iteratively optimize the retrieval model and generation model;

[0016] S9. During the conversation, if there is a retrieval failure or abnormal output of the generated model, the preset fault-tolerant mechanism will be activated, and the backup retrieval model, generated model or preset general answer will be used to ensure the continuity of the conversation process.

[0017] As a preferred technical solution of the present invention, the implementation process of step S1 is:

[0018] S1.1. User input capture: Receive text questions input by users and pre-process the input, including removing irrelevant characters and word segmentation;

[0019] S1.2. Preliminary semantic analysis: Use the pre-trained BERT model to semantically encode the input question and identify the main intent and keywords of the question;

[0020] S1.3. Dialogue initialization: Create a new dialogue session, assign a unique session ID, and initialize the dialogue state, including user input and system response.

[0021] As a preferred technical solution of the present invention, the implementation process of step S2 is:

[0022] S2.1. Vector representation generation: Use the Faiss library to convert user questions and document snippets in the knowledge base into vector representations

[0023] S2.2. Preliminary retrieval: Calculate the similarity between the user question vector and the knowledge base document vector, and retrieve the top N document fragments with the highest similarity;

[0024] S2.3. Dynamic prompt word generation: Based on the retrieved document content, template matching and generative models (including GPT) are used to generate prompt words;

[0025] S2.4. Prompt word screening: The optimal prompt word is screened based on preset evaluation criteria including relevance and diversity.

[0026] As a preferred technical solution of the present invention, the implementation process of step S3 is:

[0027] S3.1 Question concatenation: concatenate the user question with the dynamically generated prompt words to form a new input sequence;

[0028] S3.2. Large language model response generation: Input the concatenated input sequence into the pre-trained GPT-3 large language model;

[0029] S3.3. Post-response processing: Verify the generated response to ensure grammatical correctness and semantic coherence.

[0030] As a preferred technical solution of the present invention, the implementation process of step S4 is:

[0031] S4.1. Conversation preservation: save user questions and generated answers to historical conversation sets;

[0032] S4.2. Context encoding: Encode the entire conversation history using a pre-trained Transformer encoder;

[0033] S4.3. Context update: Update the encoded context information to the dialogue state.

[0034] As a preferred technical solution of the present invention, the implementation process of step S5 is:

[0035] S5.1. New question analysis: Use a large language model to analyze whether the newly input question matches the historical conversation;

[0036] S5.2. Search query enhancement: if there is a match, generate an enhanced search query based on the historical conversation;

[0037] S5.3. Re-search: Use the enhanced query to conduct a new round of search to improve the search accuracy.

[0038] As a preferred technical solution of the present invention, the implementation process of step S6 is:

[0039] S6.1. Problem decomposition: Use problem decomposition algorithms to decompose complex problems into multiple sub-problems;

[0040] S6.2. Parallel retrieval: Perform retrieval operations on each sub-question in parallel to obtain relevant documents;

[0041] S6.3. Result summary: Summarize and integrate the search results of each sub-question.

[0042] As a preferred technical solution of the present invention, the implementation process of step S7 is:

[0043] S7.1. Information fusion: Fusion of direct search results, historical dialogues, and question decomposition search results;

[0044] S7.2.Generative model optimization: Use the attention mechanism to optimize the generative model so that it can make more reasonable use of multi-source information;

[0045] S7.3. Response generation: Generate the final response based on the optimized generation model.

[0046] As a preferred technical solution of the present invention, the implementation process of step S8 is:

[0047] S8.1. User feedback collection: Collect explicit or implicit feedback from users on system responses online;

[0048] S8.2. Model evaluation: Use feedback data to evaluate the retrieval model and the generation model.

[0049] S8.3. Model tuning: Based on the evaluation results, use the reinforcement learning algorithm to iteratively optimize the model parameters.

[0050] As a preferred technical solution of the present invention, the implementation process of step S9 is:

[0051] S9.1. Anomaly detection: Real-time monitoring of abnormal situations in the conversation process, including retrieval failures and abnormal output of the generated model;

[0052] S9.2. Fault-tolerance mechanism activation: If an anomaly is detected, the preset fault-tolerance mechanism is activated, including the use of a backup model or a general answer;

[0053] S9.3. Dialogue process recovery: Execute recovery measures to ensure the continuity of the dialogue process.

[0054] Compared with the prior art, the beneficial effects of the present invention are as follows: by retrieving relevant information from an external knowledge base, the model can generate answers using broader and more specific knowledge, thereby improving the accuracy and usefulness of the answers; by explicitly retrieving and splicing relevant information in historical conversations, the model can better track the conversation history and context, thereby generating answers that are consistent and coherent with the conversation history; by retrieving and splicing relevant prompt words, the model can generate answers on a shorter input sequence, reducing the computational cost; at the same time, mechanisms such as parallel retrieval and result aggregation further improve the processing efficiency; prompt words are dynamically generated according to user input and retrieval results, so that the model can better adapt to different conversation scenarios and user needs; by collecting user feedback online and iteratively optimizing model parameters using a reinforcement learning algorithm, the model can continuously learn and improve, thereby improving performance and user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] Figure 1 This is a flow chart of the multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval of the present invention. DETAILED DESCRIPTION

[0056] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0057] See also Figure 1 The present invention provides a technical solution: a multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval, comprising the following steps:

[0058] S1. User input problem

[0059] S1.1. User input capture: Receive text questions input by users and pre-process the input, including removing irrelevant characters and word segmentation;

[0060] S1.2. Preliminary semantic analysis: Use the pre-trained BERT model to semantically encode the input question and identify the main intent and keywords of the question;

[0061] S1.3. Dialogue initialization: Create a new dialogue session, assign a unique session ID, and initialize the dialogue state, including user input and system response;

[0062] S2. Initial search and prompt word generation

[0063] S2.1. Vector representation generation: Use the Faiss library to convert user questions and document snippets in the knowledge base into vector representations;

[0064] q = FaissEncoder (user question), di = FaissEncoder (document i)

[0065] S2.2. Preliminary retrieval: Calculate the similarity between the user question vector and the knowledge base document vector;

[0066] sim(q,di)=cos(q,di)

[0067] Retrieve the top N document fragments with the highest similarity;

[0068] S2.3. Dynamic prompt word generation: Based on the retrieved document content, template matching and generative models (including GPT) are used to generate prompt words;

[0069] Prompt word = GeneratePrompt (search results)

[0070] S2.4. Prompt word screening: Screen the optimal prompt words according to the preset evaluation criteria including relevance and diversity;

[0071] S3. Question concatenation and answer generation

[0072] S3.1. Question concatenation: concatenate the user question with the dynamically generated prompt words to form a new input sequence;

[0073] Input sequence = user question ⊕ prompt word

[0074] S3.2. Large language model response generation: Input the concatenated input sequence into the pre-trained GPT-3 large language model (including GPT-3);

[0075] response = GPT-3(input sequence)

[0076] S3.3. Response post-processing: Verify the generated response to ensure grammatical correctness and semantic coherence;

[0077] S4. Historical dialogue management and context encoding

[0078] S4.1. Conversation preservation: save user questions and generated answers to historical conversation sets;

[0079] Historical dialogue set ← (user questions, responses)

[0080] S4.2. Context encoding: Encode the entire conversation history using a pre-trained Transformer encoder;

[0081] h = TransformerEncoder (historical dialogue set)

[0082] S4.3.Context update: Update the encoded context information to the dialogue state;

[0083] S5. Multi-round question analysis and retrieval enhancement

[0084] S5.1. New question analysis: Use a large language model to analyze whether the newly input question matches the historical conversation;

[0085] Matching relationship = AnalyzeMatching (new question, historical dialogue set)

[0086] S5.2. Search query enhancement: if there is a match, generate an enhanced search query based on the historical conversation;

[0087] Enhance Query = EnhanceQuery (new question, matching historical conversation)

[0088] S5.3. Re-search: Use the enhanced query to conduct a new round of search to improve the search accuracy;

[0089] S6. Complex question decomposition and parallel retrieval

[0090] S6.1. Problem decomposition: Use problem decomposition algorithms to decompose complex problems into multiple sub-problems;

[0091] (Sub-problem 1, Sub-problem 2, ..., Sub-problem n) = Decompose Question (complex question)

[0092] S6.2. Parallel retrieval: Perform retrieval operations on each sub-question in parallel to obtain relevant documents;

[0093] (result 1, result 2, ..., result n) = ParallelRetrieve ((subproblem 1, subproblem 2, ..., subproblem n))

[0094] S6.3.Results summary: summarize and integrate the search results of each sub-question;

[0095] S7. Multi-source information fusion and generation model optimization

[0096] S7.1. Information fusion: Fusion of direct search results, historical dialogues, and question decomposition search results;

[0097] Fuse Information = FuseInformation (direct search results, historical dialogue, question decomposition search results)

[0098] S7.2.Generative model optimization: Use the attention mechanism to optimize the generative model so that it can make more reasonable use of multi-source information;

[0099] Optimize response = AttentionGPT (fusion information, h)

[0100] S7.3. Response generation: Generate the final response according to the optimized generation model;

[0101] S8. Iterative feedback and model tuning

[0102] S8.1. User feedback collection: Collect explicit or implicit feedback from users on system responses online;

[0103] Feedback = CollectFeedback (user behavior)

[0104] S8.2. Model evaluation: Use feedback data to evaluate the retrieval model and the generation model.

[0105] Evaluation result = EvaluateModel(feedback)

[0106] S8.3. Model tuning: Based on the evaluation results, use the reinforcement learning algorithm to iteratively optimize the model parameters;

[0107]

[0108] In the formula, θ new is the updated model parameter, θ old is the model parameter before update (i.e. the current model parameter), α is the learning rate, which is a hyperparameter used to control the step size of parameter update. is the gradient of the reward function Reward(θ) with respect to the model parameters θ. This gradient indicates how to change θ to increase the reward.

[0109] S9. Exception handling and fault tolerance mechanism

[0110] S9.1. Anomaly detection: Real-time monitoring of abnormal situations in the conversation process, including retrieval failures and abnormal output of the generated model;

[0111] Anomaly = DetectAnomaly(system output)

[0112] S9.2. Fault-tolerance mechanism activation: If an anomaly is detected, the preset fault-tolerance mechanism is activated, including the use of a backup model or a general answer;

[0113] Recovery measure = ActivateFallback (Exception type)

[0114] S9.3. Dialogue process recovery: Execute recovery measures to ensure the continuity of the dialogue process.

[0115] Example

[0116] In practical applications, the multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval has the following process:

[0117] The user enters the first question through the chat window on the e-commerce platform, such as:

[0118] “I want to buy a cost-effective laptop”

[0119] Use the pre-trained BERT model to semantically encode the input question and identify the main intent:

[0120] “Buy a laptop”;

[0121] The keywords are:

[0122] “Great value for money”

[0123] Create a new conversation session and initialize the conversation state, including user input, response, etc.

[0124] Use the Faiss library to convert user questions and document fragments in the knowledge base (such as product descriptions, user reviews, etc.) into vector representations, calculate the similarity between the user question vector and the knowledge base document vector, and retrieve the top N document fragments with the highest similarity. These fragments may contain information about the cost-effectiveness, configuration, price, etc. of laptops. Based on the retrieved document content, use template matching combined with a generative model (such as GPT) to generate prompt words, such as:

[0125] “Have you considered laptops from brand XX? They are known for their great value for money.”

[0126] Filter out the best prompt words according to the preset evaluation criteria;

[0127] The user question is then concatenated with the dynamically generated prompt words to form a new input sequence, which is then fed into a pre-trained large language model (such as GPT-3) to generate a response:

[0128] “Have you considered laptops from brand XX? They are known for their high cost-performance ratio and have configurations that meet your needs.”

[0129] Verify the generated response to ensure grammatical correctness and semantic coherence;

[0130] Save user questions and generated answers to the historical dialogue set, and use the pre-trained Transformer encoder to encode the entire dialogue history so that context information can be used in subsequent dialogues and the encoded context information can be updated to the dialogue state;

[0131] The user continued to ask:

[0132] “Are there any special offers for this computer?”

[0133] Analyze the matching relationship between new questions and historical conversations, identify that the user is interested in the promotion of XX brand laptops, and generate enhanced search queries based on historical conversations, such as:

[0134] "XX brand laptop computer special offer"

[0135] Use the enhanced query to conduct a new round of searches to improve search accuracy;

[0136] If a user asks a complex question such as:

[0137] “I want to find a laptop that is suitable for both programming and gaming, and the price should not exceed 8,000 yuan”;

[0138] Break the problem down into multiple sub-problems, such as:

[0139] “A laptop suitable for programming”;

[0140] "A good laptop for gaming";

[0141] "Laptops priced no more than 8,000 yuan";

[0142] Perform search operations on each sub-question in parallel, obtain relevant documents, summarize and integrate the search results of each sub-question, and generate a comprehensive answer;

[0143] The direct search results, historical dialogues, and question decomposition search results are integrated to obtain more comprehensive information. The attention mechanism is used to optimize the generation model so that it can make more reasonable use of multi-source information and generate more accurate answers.

[0144] Collect explicit or implicit feedback from users on responses online, such as whether the user is satisfied, whether to continue asking questions, etc. Use feedback data to evaluate the retrieval model and generation model to understand the performance of the model and the direction of improvement. Based on the evaluation results, use reinforcement learning algorithms to iteratively optimize the model parameters to improve the model performance and user experience.

[0145] Real-time monitoring of abnormal situations during the conversation process, such as retrieval failure, abnormal model output, etc. If an abnormality is detected, the preset fault-tolerant mechanism is activated, such as using a backup model or a universal answer to respond, and executing recovery measures to ensure that the conversation process continues without affecting the user experience.

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

Claims

1. A multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval, characterized in that: The following steps are involved: S1. The user enters the first question and starts the conversation process; S2. Use the pre-trained Faiss vector retrieval model to retrieve relevant document fragments from the knowledge base according to the user's question, dynamically generate one or more prompt words based on the retrieved document content, and use the prompt words to guide the subsequent generation model to understand the question context more accurately; S3. concatenate the user question with the dynamically generated prompt words and input them into the large language model to generate the first round of answers; S4. Save the user questions and generated answers to the historical dialogue set, and use the pre-trained Transformer encoder to encode the entire dialogue history to preserve contextual information; S5. Use the question conversion model to analyze whether the newly input question has a matching relationship with the historical dialogue set, including the relevance of the question subject and the answer content. If there is a match, generate an enhanced search query based on the historical dialogue to improve the search accuracy; S6. For complex questions, use the question decomposition algorithm to decompose them into multiple sub-questions, and retrieve relevant documents for each sub-question in parallel; S7. Integrate the information from direct retrieval, historical dialogue, and question decomposition retrieval as the input of the generative model, and use the attention mechanism to optimize the generative model so that the model can more reasonably use multi-source information to generate coherent and informative answers; S8. Collect user feedback through online learning or simulated dialogue environment, and iteratively optimize the retrieval model and generation model; S9. During the conversation, if there is a retrieval failure or abnormal output of the generated model, the preset fault-tolerant mechanism will be activated, and the backup retrieval model, generated model or preset general answer will be used to ensure the continuity of the conversation process.

2. According to claim 1, a multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval is characterized in that: The implementation process of step S1 is as follows: S1.

1. User input capture: Receive text questions input by users and pre-process the input, including removing irrelevant characters and word segmentation; S1.

2. Preliminary semantic analysis: Use the pre-trained BERT model to semantically encode the input question and identify the main intent and keywords of the question; S1.

3. Dialogue initialization: Create a new dialogue session, assign a unique session ID, and initialize the dialogue state, including user input and system response.

3. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 2 is characterized in that: The implementation process of step S2 is as follows: S2.

1. Vector representation generation: Use the Faiss library to convert user questions and document snippets in the knowledge base into vector representations S2.

2. Preliminary retrieval: Calculate the similarity between the user question vector and the knowledge base document vector, and retrieve the top N document fragments with the highest similarity; S2.

3. Dynamic prompt word generation: Based on the retrieved document content, template matching and generative models (including GPT) are used to generate prompt words; S2.

4. Prompt word screening: The optimal prompt word is screened based on preset evaluation criteria including relevance and diversity.

4. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 3 is characterized in that: The implementation process of step S3 is as follows: S3.1 Question concatenation: concatenate the user question with the dynamically generated prompt words to form a new input sequence; S3.

2. Large language model response generation: Input the concatenated input sequence into the pre-trained GPT-3 large language model; S3.

3. Post-response processing: Verify the generated response to ensure grammatical correctness and semantic coherence.

5. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 4 is characterized in that: The implementation process of step S4 is as follows: S4.

1. Conversation preservation: save user questions and generated answers to historical conversation sets; S4.

2. Context encoding: Encode the entire conversation history using a pre-trained Transformer encoder; S4.

3. Context update: Update the encoded context information to the dialogue state.

6. A multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 5, characterized in that: The implementation process of step S5 is as follows: S5.

1. New question analysis: Use a large language model to analyze whether the newly input question matches the historical conversation; S5.

2. Search query enhancement: if there is a match, generate an enhanced search query based on the historical conversation; S5.

3. Re-search: Use the enhanced query to conduct a new round of search to improve the search accuracy.

7. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 6 is characterized in that: The implementation process of step S6 is as follows: S6.

1. Problem decomposition: Use problem decomposition algorithms to decompose complex problems into multiple sub-problems; S6.

2. Parallel retrieval: Perform retrieval operations on each sub-question in parallel to obtain relevant documents; S6.

3. Result summary: Summarize and integrate the search results of each sub-question.

8. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 7 is characterized in that: The implementation process of step S7 is as follows: S7.

1. Information fusion: Fusion of direct search results, historical dialogues, and question decomposition search results; S7.2.Generative model optimization: Use the attention mechanism to optimize the generative model so that it can make more reasonable use of multi-source information; S7.

3. Response generation: Generate the final response based on the optimized generation model.

9. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 8 is characterized in that: The implementation process of step S8 is as follows: S8.

1. User feedback collection: Collect explicit or implicit feedback from users on system responses online; S8.

2. Model evaluation: Use feedback data to evaluate the retrieval model and the generation model. S8.

3. Model tuning: Based on the evaluation results, use the reinforcement learning algorithm to iteratively optimize the model parameters.

10. The multi-round dialogue processing method based on RAG technology dynamic prompt word retrieval according to claim 9 is characterized in that: The implementation process of step S9 is as follows: S9.

1. Anomaly detection: Real-time monitoring of abnormal situations during the conversation, including retrieval failures and abnormal output of the generated model; S9.

2. Fault-tolerance mechanism activation: If an anomaly is detected, the preset fault-tolerance mechanism is activated, including the use of a backup model or a general answer; S9.

3. Dialogue process recovery: Execute recovery measures to ensure the continuity of the dialogue process.

Citation Information

Cited By

  • Cue word layered optimization method for complex problem decomposition

    CN120234399A

  • Insurance clause knowledge base self-maintenance method, system and equipment based on large model

    CN120975207A

  • Retrieval enhancement method and system for multi-round dialogue type questions and answers and application

    CN121029952A

  • A retrieval enhancement method, system and application for multi-turn conversational question answering

    CN121029952B

  • Dynamic interactive document generation method and device based on generative AI, computer equipment and computer readable storage medium

    CN121072503A