Retrieval enhancement generation method and device for domain questions and answers, equipment and medium

By training the base language model for problem understanding and generation, and automatically generating pseudo-label data and performing quality verification, the reliance on expensive manually labeled data in domain adaptation is resolved, and efficient and accurate domain question answering model construction is achieved.

CN121543725APending Publication Date: 2026-02-17深圳市和讯华谷信息技术有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511720619.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-21
Publication Date
2026-02-17

AI Technical Summary

Technical Problem

Existing domain-adaptive methods rely on costly manually labeled data and lack the ability to address the challenges of accuracy and reliability of generated content in the absence of labeled data.

Method used

By training the base language model to understand and generate questions, the preprocessing model automatically generates pseudo-label data pairs containing questions, context, and answers. High-quality pseudo-label data pairs are then selected through a rigorous quality verification mechanism for fine-tuning and optimization training.

Benefits of technology

It significantly reduces reliance on expensive manually labeled data, improves the efficiency and economy of the domain adaptation process, ensures the accuracy and reliability of generated data, and enhances the precision and reliability of domain expert models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121543725A_ABST
    Figure CN121543725A_ABST
Patent Text Reader

Abstract

The invention discloses a domain question and answer-oriented retrieval enhancement generation method and device, equipment and a medium. The method comprises the following steps: performing dual ability training of question understanding and question generation on a base language model to obtain a preprocessing model; processing unlabeled corpora in a specific field by using the preprocessing model, and automatically generating a pseudo-label data pair; performing quality verification and filtering on the generated pseudo label data through a self-error correction mechanism based on reverse retrieval, and screening out high-quality data; and optimizing the base model by using the high-quality data to obtain a domain expert model. According to the method, through automatic generation and strict quality control, the dependence on manual annotation data is remarkably reduced, the unannotated field data is efficiently utilized, and the accuracy and reliability of the model in professional field questions and answers are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to a method, apparatus, device, and medium for enhancing retrieval and generating domain-specific question answering. Background Technology

[0002] Large-scale language models have demonstrated outstanding performance in general natural language processing tasks, particularly in open-domain question answering. These models, pre-trained on massive amounts of internet text, have acquired powerful language understanding and generation capabilities. However, when these general-purpose models are directly applied to highly specialized fields such as medicine, finance, and law, their performance often declines significantly. This is mainly because the general training corpora lack in-depth coverage of domain-specific terminology, knowledge systems, and expression habits, making it difficult for the models to accurately understand and respond to specialized questions.

[0003] To overcome this limitation, domain adaptation techniques have become a key research direction. Existing mainstream methods typically rely on large amounts of high-quality, expert-annotated domain-specific data for supervised fine-tuning of general models. While effective, this approach suffers from bottlenecks: the production of domain-annotated data is extremely costly and time-consuming, requiring deep involvement from scarce domain experts, which severely restricts the rapid deployment and large-scale application of models across numerous vertical domains. Furthermore, although some studies have attempted to incorporate external knowledge using retrieval-enhanced generation techniques, ensuring the accuracy and reliability of model-generated content remains a significant challenge in the absence of labeled data.

[0004] Therefore, there is an urgent need in this field for a new method that can effectively reduce reliance on manually labeled data and make full use of a large number of readily available unlabeled documents in the domain to automatically and efficiently build high-quality domain question answering models. Summary of the Invention

[0005] The technical problem to be solved by this invention is to reduce the dependence on a large amount of expensive manually labeled data in the process of domain adaptation.

[0006] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is: a retrieval enhancement generation method for domain-oriented question answering, comprising the following steps: S1. Train the base language model to improve its problem understanding and problem generation capabilities, so as to obtain a preprocessing model with bidirectional understanding and generation capabilities. S2. Obtain unlabeled corpus in a specific domain, process the unlabeled corpus using the preprocessing model, and automatically generate pseudo-label data pairs containing questions, context, and answers; S3. The pseudo-label data pairs are filtered through a preset quality verification mechanism to select high-quality pseudo-label data pairs. S4. Using the selected high-quality pseudo-label data pairs, fine-tune and optimize the base language model to obtain a domain expert model adapted to the specific domain.

[0007] Furthermore, in step S2, the step of acquiring unlabeled corpus in a specific domain and processing the unlabeled corpus using the preprocessing model to automatically generate pseudo-label data pairs containing questions, context, and answers specifically includes: S21. Select the target context from the unlabeled corpus of the specific domain; S22. Using the preprocessing model, extract at least one candidate answer from the target context; S23. For each candidate answer, the preprocessing model is used to generate a corresponding candidate question based on the target context and the candidate answer; S24. Combine the candidate question, the target context, and the candidate answer to form a candidate pseudo-label data pair.

[0008] Furthermore, in step S3, filtering the pseudo-label data pairs through a preset quality verification mechanism to select high-quality pseudo-label data pairs specifically includes: S31. Isolate the candidate problem from the candidate pseudo-label data pairs; S32. Using the isolated candidate questions as query conditions, perform semantic retrieval in the database consisting of all contexts that constitute the unlabeled corpus to obtain a list of retrieval results sorted by relevance to the candidate questions; S33. Compare the search result list with the source context information in the candidate pseudo-label data pairs, and make a quality decision based on the preset decision rules. S34. Based on the results of the quality decision, the candidate pseudo-label data pairs that failed the decision are filtered out to obtain high-quality pseudo-label data.

[0009] Furthermore, in step S33, comparing the search result list with the source context information in the candidate pseudo-label data pairs and making a quality decision based on preset decision rules specifically includes: S331. Determine whether the context corresponding to the first-ranked search result in the search result list is the same as the target context in the candidate pseudo-label data pair. S332. Determine whether the first relevance score between the first-ranked search result and the candidate question is significantly higher than the second relevance score between the second-ranked search result and the candidate question; S333. If the judgment conditions of steps S331 and S332 are met simultaneously, then the candidate pseudo-label data pair is determined to be a high-quality pseudo-label data pair.

[0010] Furthermore, in step S332, determining whether the first relevance score of the top-ranked search result to the candidate question is significantly higher than the second relevance score of the second-ranked search result to the candidate question specifically includes: Determine whether the first relevance score between the top-ranked search result and the candidate question is higher than the second relevance score between the second-ranked search result and the candidate question by a preset threshold percentage.

[0011] Furthermore, step S4 also includes: mixing the selected high-quality pseudo-label data with the original labeled training data to form an enhanced training set, and using the enhanced training set to fine-tune and optimize the base language model.

[0012] Furthermore, in step S1, training the base language model's problem understanding ability specifically includes: The base language model is trained using a dataset containing questions, context, and answers, enabling it to generate the correct answer based on the input question and context.

[0013] The present invention also provides a retrieval enhancement generation device for domain-oriented question answering, comprising: The basic training module is used to train the base language model to understand and generate questions, so as to obtain a preprocessed model with bidirectional understanding and generation capabilities. The pseudo-data generation module is used to acquire unlabeled corpus in a specific domain, process the unlabeled corpus using the preprocessing model, and automatically generate pseudo-label data pairs containing questions, context, and answers. The quality filtering module is used to filter the pseudo-label data pairs through a preset quality verification mechanism to select high-quality pseudo-label data pairs. The model optimization module is used to fine-tune and optimize the base language model using the selected high-quality pseudo-label data pairs to obtain a domain expert model adapted to the specific domain.

[0014] The present invention also provides a computer device, the computer device including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the domain-oriented question answering retrieval enhancement generation method as described above.

[0015] The present invention also provides a storage medium storing a computer program, which, when executed by a processor, can implement the domain-oriented question-answering retrieval enhancement generation method described above.

[0016] The beneficial effects of this invention are as follows: By first training the base model bidirectionally for problem understanding and generation to construct a preprocessing model, and then using the preprocessing model to automatically generate pseudo-label data pairs from unlabeled domain corpora, a rigorous quality verification mechanism is introduced for screening. Finally, the base model is optimized using high-quality data, forming a self-driven closed-loop technical solution. This solution significantly reduces the reliance on expensive manually labeled data, efficiently transforms massive amounts of unlabeled domain literature into reliable training resources, and ensures the accuracy of the generated data through a quality control mechanism. This fundamentally improves the efficiency and economy of the domain adaptation process, and guarantees the accuracy and reliability of the resulting domain expert model in professional question-answering tasks. Attached Figure Description

[0017] The specific structure of the present invention will now be described in detail with reference to the accompanying drawings.

[0018] Figure 1 This is a flowchart of the domain-oriented question answering retrieval enhancement generation method according to an embodiment of the present invention; Figure 2 This is a flowchart illustrating the pseudo-data generation process according to an embodiment of the present invention. Figure 3 This is a flowchart of the pseudo-data filtering process according to an embodiment of the present invention; Figure 4 This is a flowchart illustrating the pseudo-data quality adjudication process according to an embodiment of the present invention. Figure 5 This is a block diagram of a domain-oriented question-answering retrieval enhancement generation device according to an embodiment of the present invention; Figure 6 This is a schematic block diagram of a computer device according to an embodiment of the present invention. Detailed Implementation

[0019] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0020] It should be understood that, when used in this specification and the appended claims, the terms "comprising" and "including" indicate the presence of the described features, integrals, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or collections thereof.

[0021] It should also be understood that the terminology used in this specification is for the purpose of describing particular embodiments only and is not intended to limit the invention. As used in this specification and the appended claims, the singular forms “a,” “an,” and “the” are intended to include the plural forms unless the context clearly indicates otherwise.

[0022] It should also be further understood that the term "and / or" as used in this specification and the appended claims refers to any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.

[0023] like Figure 1 As shown, an embodiment of the present invention is: a retrieval enhancement generation method for domain-oriented question answering, including steps S1-S4, as detailed below: S1. Train the base language model to improve its problem understanding and problem generation capabilities, so as to obtain a preprocessing model with bidirectional understanding and generation capabilities.

[0024] In one specific embodiment, step S1, training the base language model's problem understanding ability, specifically includes: The base language model is trained using a dataset containing questions, context, and answers, enabling it to generate the correct answer based on the input question and context.

[0025] In this embodiment, dual-capability training is the foundation of the entire method, shaping a general base model into a preprocessing model capable of simultaneously understanding and generating questions. The model is trained using a question-and-answer dataset from the financial domain. During the question understanding training phase, data preparation involves collecting a dataset containing financial regulatory questions, relevant regulatory context, and standard answers. The preprocessing phase cleans the data to ensure a precise correspondence between questions and regulatory provisions. During training, each question and its corresponding regulatory context are input into the base language model, whose task is to generate accurate answers. By calculating the loss between the base language model's output and the standard answer, and adjusting the base language model's parameters using backpropagation, the base language model gradually learns to extract key information from complex financial texts and provide compliant answers. Simultaneously, question generation training is performed. For example, given a context describing the disclosure deadlines for listed companies' annual reports, and the key answer "within four months," the model is trained to generate a precise question, such as "How long after the end of the fiscal year should a listed company disclose its annual report?" Through this joint training in the financial field, the model not only gained a deep understanding of the question-and-answer logic of financial regulation, but also learned how to extract and construct questions from the original text of regulations. This enabled it to acquire bidirectional understanding and generation capabilities in the financial field, laying a solid foundation for automatically generating high-quality pseudo-labeled data pairs from massive amounts of unlabeled financial documents.

[0026] S2. Obtain unlabeled corpus in a specific domain, process the unlabeled corpus using the preprocessing model, and automatically generate pseudo-label data pairs containing questions, context, and answers.

[0027] like Figure 2 As shown, in a specific embodiment, step S2 specifically includes steps S21-S24, as follows: S21. Select the target context from the unlabeled corpus of the specific domain.

[0028] S22. Using the preprocessing model, extract at least one candidate answer from the target context.

[0029] S23. For each candidate answer, the preprocessing model is used to generate a corresponding candidate question based on the target context and the candidate answer.

[0030] S24. Combine the candidate question, the target context, and the candidate answer to form a candidate pseudo-label data pair.

[0031] In this embodiment, to illustrate the automatic generation process of step S2 more specifically, we take a financial compliance review scenario as an example. The system automatically downloads an original regulatory document titled "Measures for the Administration of Information Disclosure by Listed Companies" and segments it into independent text paragraphs with unique numbers. For example, when the system processes the paragraph with Chunk-ID: 1138, its original text reads: "Annual reports should be prepared and disclosed within four months from the end of each fiscal year, and interim reports should be prepared and disclosed within two months from the end of the first half of each fiscal year." First, the system calls a preprocessing model to identify and extract the most specific and crucial factual information from this paragraph as candidate answers. For example, it may output two candidate answers: "within four months from the end of each fiscal year" and "within two months from the end of the first half of each fiscal year." Next, for the first candidate answer, the system calls the preprocessing model again, combining it with the original text to generate a natural language question that precisely matches it. For example, the candidate question might be: "When should a listed company disclose its annual report?" Finally, the system automatically combines this question, the original context Chunk-ID: 1138, and the candidate answers to form a structured candidate pseudo-label data pair. This process can efficiently extract structured knowledge pairs from dry original texts, laying a data foundation for subsequent training.

[0032] S3. The pseudo-label data pairs are filtered through a preset quality verification mechanism to select high-quality pseudo-label data pairs.

[0033] like Figure 3 As shown, in a specific embodiment, step S3 specifically includes steps S31-S34, as follows: S31. Isolate the candidate problem from the candidate pseudo-label data pairs.

[0034] S32. Using the isolated candidate questions as query conditions, perform semantic retrieval in the database consisting of all contexts that constitute the unlabeled corpus to obtain a list of search results sorted by relevance to the candidate questions.

[0035] S33. Compare the search result list with the source context information in the candidate pseudo-label data pairs, and make a quality decision based on the preset decision rules.

[0036] In one specific embodiment, step S33 specifically includes steps S331-S333, as follows: S331. Determine whether the context corresponding to the first-ranked search result in the search result list is the same as the target context in the candidate pseudo-label data pair.

[0037] S332. Determine whether the first relevance score between the first ranked search result and the candidate question is significantly higher than the second relevance score between the second ranked search result and the candidate question.

[0038] like Figure 4 As shown, in a specific embodiment, step S332 specifically includes: determining whether the first relevance score of the first-ranked search result to the candidate question is higher than the second relevance score of the second-ranked search result to the candidate question by a preset threshold percentage.

[0039] S333. If the judgment conditions of steps S331 and S332 are met simultaneously, then the candidate pseudo-label data pair is determined to be a high-quality pseudo-label data pair.

[0040] S34. Based on the results of the quality decision, the candidate pseudo-label data pairs that failed the decision are filtered out to obtain high-quality pseudo-label data.

[0041] In this embodiment, taking the candidate knowledge pairs generated in the aforementioned financial scenario as an example, the self-correction mechanism based on reverse retrieval is explained in detail. First, the question—namely, when should a listed company disclose its annual report—is isolated from the candidate knowledge pairs, and its corresponding answer and source context are hidden to ensure fairness through blind verification. Next, this question is used as a query condition, and a full-database semantic search is performed on all text paragraphs in the entire regulatory database. Assume that in the search engine's results list sorted by relevance, the top-ranked result is the original paragraph Chunk-ID: 1138 used to generate the question, and its relevance score to the question is 0.95, significantly higher than the second-ranked result's score of 0.60, for example, if the score difference reaches a preset threshold percentage. Then, the system judges according to two preset adjudication rules: Rule 1, source consistency verification passes because the ID of the top-ranked result is completely consistent with the original ID of the candidate knowledge pair; Rule 2, confidence and discrimination verification also passes because the score of the first-ranked result is significantly higher than the second-ranked result. Therefore, the system determines that this candidate knowledge pair is high-quality data and retains it. Conversely, if the top-ranked result returned by the retrieval is not the original paragraph, or if the scores of the first and second-ranked results are very close and ambiguous, the candidate knowledge pair will be judged as low-quality and immediately deleted by the system. This self-correcting mechanism can automatically check and eliminate low-quality or ambiguous data, ensuring that the data ultimately used for training has high accuracy and unique relevance.

[0042] S4. Using the selected high-quality pseudo-label data pairs, fine-tune and optimize the base language model to obtain a domain expert model adapted to the specific domain.

[0043] In one specific embodiment, step S4 further includes: mixing the selected high-quality pseudo-label data with the original labeled training data to form an enhanced training set, and using the enhanced training set to fine-tune and optimize the base language model.

[0044] In this embodiment, after a long period of operation following the aforementioned quality filtering process, tens of thousands of high-quality knowledge pairs, certified by a self-correcting mechanism, can be accumulated. These high-quality knowledge pairs constitute excellent teaching materials for domain adaptation of the base model. Using these knowledge pairs, a general AI model can be fine-tuned. Ultimately, an optimized expert model that internalizes a massive amount of financial compliance knowledge can be obtained. Based on the above complete process, only periodic updates of the original data and periodic automated fine-tuning are required. The entire process can complete the update of the model knowledge base with almost no human intervention, enabling the expert model to continuously master the latest domain knowledge and significantly reducing the overall cost and threshold of domain adaptation.

[0045] like Figure 5 As shown, this embodiment of the invention also provides a retrieval enhancement generation device for domain-oriented question answering, comprising: The basic training module 10 is used to train the base language model to understand and generate questions, so as to obtain a preprocessed model with bidirectional understanding and generation capabilities.

[0046] The pseudo-data generation module 20 is used to acquire unlabeled corpus in a specific domain, process the unlabeled corpus using the preprocessing model, and automatically generate pseudo-label data pairs containing questions, context, and answers.

[0047] The quality filtering module 30 is used to filter the pseudo-label data pairs through a preset quality verification mechanism to select high-quality pseudo-label data pairs.

[0048] The model optimization module 40 is used to fine-tune and optimize the base language model using the selected high-quality pseudo-label data pairs to obtain a domain expert model adapted to the specific domain.

[0049] The pseudo-data generation module 20 is specifically used for: Select the target context from the unlabeled corpus of the specific domain; Using the preprocessing model, at least one candidate answer is extracted from the target context; For each candidate answer, the preprocessing model is used to generate a corresponding candidate question based on the target context and the candidate answer; The candidate question, the target context, and the candidate answer are combined to form a candidate pseudo-label data pair.

[0050] The quality filtration module 30 specifically includes: A candidate question filtering unit is used to isolate the candidate questions from the candidate pseudo-label data pairs; The semantic retrieval unit is used to perform semantic retrieval in a database consisting of all contexts that constitute the unlabeled corpus, using the isolated candidate questions as query conditions, and to obtain a list of retrieval results sorted by relevance to the candidate questions. The quality adjudication unit is used to compare the list of search results with the source context information in the candidate pseudo-label data pairs, and to make a quality adjudication based on preset adjudication rules. The data filtering unit is used to filter out the candidate pseudo-label data pairs that fail to pass the quality decision based on the result of the quality decision, so as to obtain high-quality pseudo-label data.

[0051] The quality adjudication unit is specifically used for: Determine whether the context corresponding to the first-ranked search result in the search result list is the same as the target context in the candidate pseudo-label data pair; Determine whether the first relevance score between the top-ranked search result and the candidate question is significantly higher than the second relevance score between the second-ranked search result and the candidate question; If the search result and the target context are the same and the first relevance score is significantly higher than the second relevance score, then the candidate pseudo-label data pair is determined to be a high-quality pseudo-label data pair.

[0052] In one specific embodiment, determining whether the first relevance score of the top-ranked search result to the candidate question is significantly higher than the second relevance score of the second-ranked search result to the candidate question specifically includes: Determine whether the first relevance score between the top-ranked search result and the candidate question is higher than the second relevance score between the second-ranked search result and the candidate question by a preset threshold percentage.

[0053] The model optimization module 40 is also used to: mix the selected high-quality pseudo-label data with the original labeled training data to form an enhanced training set, and use the enhanced training set to fine-tune and optimize the base language model.

[0054] In one specific embodiment, the training of the base language model's problem understanding ability in the basic training module 10 specifically includes: The base language model is trained using a dataset containing questions, context, and answers, enabling it to generate the correct answer based on the input question and context.

[0055] It should be noted that those skilled in the art can clearly understand that the specific implementation process of the above-mentioned domain-oriented question answering retrieval enhancement generation device and each unit can be referred to the corresponding description in the foregoing method embodiments. For the sake of convenience and brevity, it will not be repeated here.

[0056] The aforementioned domain-oriented question-answering retrieval enhancement generation device can be implemented as a computer program, which can, for example... Figure 6 It runs on the computer device shown.

[0057] Please see Figure 6 , Figure 6 This is a schematic block diagram of a computer device provided in an embodiment of this application. The computer device 500 can be a terminal or a server. The terminal can be an electronic device with communication functions, such as a smartphone, tablet, laptop, desktop computer, personal digital assistant, or wearable device. The server can be a standalone server or a server cluster composed of multiple servers.

[0058] See Figure 6 The computer device 500 includes a processor 502, a memory, and a network interface 505 connected via a system bus 501. The memory may include a non-volatile storage medium 503 and internal memory 504.

[0059] The non-volatile storage medium 503 may store an operating system 5031 and a computer program 5032. The computer program 5032 includes program instructions that, when executed, cause the processor 502 to perform a domain-oriented question-answering retrieval enhancement generation method.

[0060] The processor 502 provides computing and control capabilities to support the operation of the entire computer device 500.

[0061] The internal memory 504 provides an environment for the execution of the computer program 5032 in the non-volatile storage medium 503. When the computer program 5032 is executed by the processor 502, the processor 502 can execute a domain-oriented question-answering retrieval enhancement generation method.

[0062] This network interface 505 is used for network communication with other devices. Those skilled in the art will understand that... Figure 6 The structure shown is merely a block diagram of a portion of the structure related to the present application and does not constitute a limitation on the computer device 500 to which the present application is applied. The specific computer device 500 may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0063] The processor 502 is used to run a computer program 5032 stored in the memory to implement the domain-oriented question-answering retrieval enhancement generation method as described above.

[0064] It should be understood that in the embodiments of this application, the processor 502 may be a central processing unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.

[0065] It will be understood by those skilled in the art that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program includes program instructions and can be stored in a storage medium, which is a computer-readable storage medium. The program instructions are executed by at least one processor in the computer system to implement the process steps of the embodiments of the above methods.

[0066] Therefore, the present invention also provides a storage medium. This storage medium can be a computer-readable storage medium. The storage medium stores a computer program, wherein the computer program includes program instructions. When executed by a processor, the program instructions cause the processor to perform the domain-oriented question-answering retrieval enhancement generation method as described above.

[0067] The storage medium can be any computer-readable storage medium capable of storing program code, such as a USB flash drive, portable hard drive, read-only memory (ROM), magnetic disk, or optical disk.

[0068] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.

[0069] In the several embodiments provided by this invention, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For example, the division of each unit is merely a logical functional division, and there may be other division methods in actual implementation. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed.

[0070] The steps in the method of this invention can be adjusted, merged, or reduced in order according to actual needs. The units in the device of this invention can be merged, divided, or reduced according to actual needs. Furthermore, the functional units in the various embodiments of this invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0071] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, a terminal, or a network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.

[0072] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and these modifications or substitutions should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.

Claims

1. A retrieval enhancement generation method for domain-oriented question answering, characterized in that, The method comprises the following steps: S1, performing question understanding ability training and question generation ability training on a base language model to obtain a preprocessing model with bidirectional understanding and generation capabilities; S2, obtaining unlabeled corpus of a specific field, processing the unlabeled corpus by using the preprocessing model, and automatically generating pseudo-label data pairs containing questions, contexts and answers; S3, filtering the pseudo-label data pairs by using a preset quality verification mechanism, and screening high-quality pseudo-label data pairs; S4, fine-tuning and optimizing the base language model by using the screened high-quality pseudo-label data pairs to obtain a domain expert model adapted to the specific field.

2. The domain question answering retrieval augmentation generation method of claim 1, wherein, In step S2, the unlabeled corpus of the specific field is obtained, and the unlabeled corpus is processed by using the preprocessing model to automatically generate pseudo-label data pairs containing questions, contexts and answers. Specifically, the step S2 comprises the following steps: S21, selecting a target context from the unlabeled corpus of the specific field; S22, extracting at least one candidate answer from the target context by using the preprocessing model; S23, for each candidate answer, generating a corresponding candidate question based on the target context and the candidate answer by using the preprocessing model; S24, automatically combining the candidate question, the target context and the candidate answer to form a candidate pseudo-label data pair.

3. The domain question answering retrieval augmentation generation method of claim 2, wherein, In step S3, the pseudo-label data pairs are filtered by using a preset quality verification mechanism, and high-quality pseudo-label data pairs are screened. Specifically, the step S3 comprises the following steps: S31, isolating the candidate question from the candidate pseudo-label data pair; S32, taking the isolated candidate question as a query condition to perform semantic retrieval in a database composed of all contexts constituting the unlabeled corpus, to obtain a retrieval result list sorted according to the relevance to the candidate question; S33, comparing the retrieval result list with the source context information in the candidate pseudo-label data pair, and performing quality judgment according to a preset judgment rule; S34, based on the result of the quality judgment, filtering out the candidate pseudo-label data pair that fails to pass the judgment to obtain high-quality pseudo-label data.

4. The domain question answering retrieval augmentation generation method of claim 3, wherein, In step S33, the retrieval result list is compared with the source context information in the candidate pseudo-label data pair, and quality judgment is performed according to a preset judgment rule. Specifically, the step S33 comprises the following steps: S331, judging whether the context corresponding to the first-ranked retrieval result in the retrieval result list is the same context as the target context in the candidate pseudo-label data pair; S332, judging whether the first relevance score of the first-ranked retrieval result and the candidate question is significantly higher than the second relevance score of the second-ranked retrieval result and the candidate question; S333, if the judgment conditions of steps S331 and S332 are both met, the candidate pseudo-label data pair is determined to be a high-quality pseudo-label data pair.

5. The domain question answering retrieval augmentation generation method of claim 4, wherein, In step S332, it is judged whether the first relevance score of the first ranked search result and the candidate question is significantly higher than the second relevance score of the second ranked search result and the candidate question, specifically including: It is judged whether the first relevance score of the first ranked search result and the candidate question is higher than the second relevance score of the second ranked search result and the candidate question by a preset threshold percentage.

6. The domain question answering retrieval augmentation generation method of claim 1, wherein, In step S4, further comprising: mixing the screened high-quality pseudo-label data and the original labeled training data to form an enhanced training set, and using the enhanced training set to fine-tune and optimize the training of the base language model.

7. The domain question answering retrieval augmentation generation method of claim 1, wherein, In step S1, the question understanding ability training of the base language model specifically includes: Using a data set containing questions, contexts and answers to train the base language model so that it can generate correct answers according to input questions and contexts.

8. A domain question answering search enhancement generation apparatus characterized by comprising: It includes: A basic training module for training the base language model for question understanding ability and question generation ability to obtain a pre-processing model with bidirectional understanding and generation ability; A pseudo-data generation module for obtaining unlabeled corpus of a specific field, processing the unlabeled corpus using the pre-processing model, and automatically generating pseudo-label data pairs containing questions, contexts and answers; A quality filtering module for filtering the pseudo-label data pairs through a preset quality verification mechanism, and screening high-quality pseudo-label data pairs; A model optimization module for fine-tuning and optimizing the base language model using the screened high-quality pseudo-label data pairs to obtain a domain expert model adapted to the specific field.

9. A computer device, comprising: The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the retrieval enhancement generation method for field-oriented question answering according to any one of claims 1-7 when executing the computer program.

10. A storage medium, characterized by The storage medium stores a computer program, and the computer program can implement the retrieval enhancement generation method for field-oriented question answering according to any one of claims 1-7 when executed by the processor.