Professional field database retrieval method based on large language model knowledge enhancement, electronic equipment and medium

By processing database keywords and descriptions using a large language model, generating features, and performing similarity matching, the problems of professional dependence and keyword limitation in large-scale database retrieval are solved, and efficient and stable retrieval results are achieved.

CN119226500BActive Publication Date: 2026-06-05ZHEJIANG LAB

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG LAB
Filing Date
2024-09-06
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing technologies suffer from problems such as being time-consuming and labor-intensive in large-scale comprehensive database retrieval, the quality of retrieval results depending on professional skills, keyword limitations, the influence of query language, and insufficient universality due to the imperfection of external knowledge bases.

Method used

By acquiring keywords and descriptions of different types of data from the database, a large language model is used to generate data and query suggestion text. Natural language processing features are extracted and weighted fusion is performed, and similarity matching is calculated to derive search results.

Benefits of technology

It improves retrieval performance, overcomes the limitations of database-defined keywords and data descriptions, enhances retrieval efficiency and stability, and has a wider range of application scenarios and greater versatility.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119226500B_ABST
    Figure CN119226500B_ABST
Patent Text Reader

Abstract

The application discloses a professional field database retrieval method based on large language model knowledge enhancement, an electronic device and a medium, and comprises the following steps: acquiring keywords and descriptions corresponding to each type of data in a target field database, and linking and matching the data contents to obtain an SQL table; defining a first corpus template to concatenate the keywords and the descriptions to obtain data prompt text; defining a second corpus template to concatenate query text to obtain query prompt text; inputting the data prompt text and the query prompt text into a large language model respectively to generate response and retrieval texts; inputting the query text, the retrieval text and the response text into a natural language processing model respectively to generate query text features, retrieval text features and response text features; performing weighted fusion on the query text features and the retrieval text features to obtain fused text features; calculating the similarity between the fused text features and the response text features, and exporting data corresponding to the K response text features with the highest similarity from the SQL table as a retrieval result.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of data retrieval, and particularly relates to a professional domain database retrieval method, electronic device, and medium based on knowledge enhancement of a large language model. Background Technology

[0002] With the development of intelligent technologies in the science and technology field, an increasing number of publicly available large-scale comprehensive databases have emerged, such as the UK Biobank (UKB) in the life sciences field, the China Kadoorie Biobank (CKB) in the chronic disease prospective study cohort study field, and the WorldClim high spatial resolution global weather and climate database in the meteorological sciences field. These comprehensive databases contain massive amounts of data with diverse data types, but the databases themselves only pre-set search codes (such as keywords) and standard search fields (such as data descriptions) for each data type. Therefore, effective data retrieval methods are crucial for fully and rationally utilizing these specialized, large-scale comprehensive databases.

[0003] Currently, data retrieval methods for large-scale domain-specific comprehensive databases have the following problems:

[0004] 1. Traditional manual retrieval methods are mainly carried out by researchers or practitioners in the field, who use their own domain knowledge and professional experience to search domain databases. This is time-consuming and labor-intensive when dealing with large-scale comprehensive databases, and the quality of the retrieval results is easily affected by the professional ability of the retrieval personnel.

[0005] 2. While keyword semantic similarity-based retrieval can quickly process large-scale comprehensive databases, its performance is easily limited by the database's built-in keywords and data descriptions. If there are few keywords or the descriptions are too brief, the algorithm's retrieval performance will be significantly affected. Furthermore, this method is also susceptible to the user's query language; if the query language is too simple or ambiguous, it can lead to problems such as mismatches and omissions.

[0006] 3. Methods that use large models to construct high-dimensional feature vectors for semantic similarity matching are also susceptible to limitations imposed by database-defined keywords and data descriptions. While injecting external knowledge can compensate for these limitations, incomplete or inadequate knowledge bases can reduce the reliability of search results. Furthermore, different external knowledge bases need to be set up independently for different databases for model fine-tuning and training, resulting in insufficient versatility. Summary of the Invention

[0007] To address the shortcomings of existing technologies, this invention provides a professional domain database retrieval method, electronic device, and medium based on knowledge enhancement using a large language model.

[0008] In a first aspect, embodiments of the present invention provide a professional domain database retrieval method based on knowledge enhancement using a large language model, the method comprising:

[0009] Obtain the keywords and descriptions corresponding to each type of data in the target domain database, and match the keywords and descriptions corresponding to each type of data with data links and content to obtain the SQL table of the target domain; define the first corpus template, and concatenate the keywords and descriptions based on the first corpus template to obtain the data prompt text;

[0010] Define a second corpus template, and concatenate the user-input query text based on the second corpus template to obtain the query prompt text;

[0011] Input the data prompt text and query prompt text into the large language model, and generate response text and search text respectively;

[0012] Input the query text, retrieval text, and response text into the natural language processing model to generate query text features, retrieval text features, and response text features;

[0013] The query text features and the retrieval text features are weighted and fused to obtain the fused text features;

[0014] Calculate the similarity between the fused text features and the response text features, and export the data corresponding to the top K response text features with the highest similarity from the SQL table as the retrieval results.

[0015] Secondly, embodiments of the present invention provide an electronic device, including a memory and a processor, characterized in that the memory is coupled to the processor; wherein the memory is used to store program data, and the processor is used to execute the program data to implement the above-described method for retrieving professional domain databases based on knowledge enhancement of large language models.

[0016] Thirdly, embodiments of the present invention provide a computer-readable storage medium having a computer program stored thereon, characterized in that the program, when executed by a processor, implements the above-described method for retrieving professional domain databases based on knowledge enhancement of a large language model.

[0017] Fourthly, embodiments of the present invention provide a computer program product, including a computer program / instruction, characterized in that, when the computer program / instruction is executed by a processor, it implements the above-described method for retrieving a professional domain database based on knowledge enhancement of a large language model.

[0018] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0019] (1) This invention obtains keywords and descriptions of different types of data in the database, inputs the query text, retrieval text and response text into the natural language processing model respectively, generates query text features, retrieval text features and response text features, performs knowledge reasoning through the large language model, and utilizes the knowledge base and context understanding capabilities of the large language model to obtain more relevant background information and details, better understand the user's query intent, and overcome the limitations of self-defined keywords and data descriptions in professional domain databases, effectively improving retrieval performance.

[0020] (2) Weighted fusion of query text features and retrieval text features is performed to obtain fused text features; the fused text features are then matched with the response text features for similarity, which can quickly process large-scale comprehensive databases and effectively improve the efficiency of data utilization.

[0021] (3) This invention improves database retrieval performance based on domain knowledge of a large language model. It does not require setting up external knowledge bases for different professional domain databases, nor does it require training or fine-tuning of the large language model. It has stronger versatility and a wider range of application scenarios. At the same time, this invention makes full use of the domain knowledge of the large language model for retrieval. It uses the domain knowledge of the model to improve the semantic matching performance between the query statement and the retrieval content. It is not easily affected by the lack of experience of the retrieval personnel or the imperfection of the external knowledge base. The retrieval performance is more stable and reliable. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0023] Figure 1 This is a first schematic diagram of a professional domain database retrieval method based on large model knowledge enhancement provided in the embodiment;

[0024] Figure 2 This is a second schematic diagram of a professional domain database retrieval method based on large model knowledge enhancement provided in the embodiment;

[0025] Figure 3 This is a schematic diagram illustrating the process of generating data prompt text and response text provided in the embodiment;

[0026] Figure 4 This is a schematic diagram illustrating the process of generating query prompt text and search text provided in the embodiment;

[0027] Figure 5 This is a schematic diagram of an electronic device provided in an embodiment. Detailed Implementation

[0028] 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 embodiments of the present invention, and not all embodiments. 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.

[0029] It should be noted that, unless otherwise specified, the features in the following embodiments and implementation methods can be combined with each other.

[0030] like Figure 1 and Figure 2 As shown, this embodiment of the invention provides a professional domain database retrieval method based on knowledge enhancement using a large language model. The method includes:

[0031] Step S1: Obtain the keywords and descriptions corresponding to each type of data in the target domain database, and match the keywords and descriptions corresponding to each type of data with data links and content to obtain the SQL table of the target domain; define the first corpus template, and concatenate the keywords and descriptions based on the first corpus template to obtain the data prompt text.

[0032] Furthermore, the target domain databases include: the UK Biobank (UKB) in the life sciences field, the China Kadoorie Biobank (CKB) in the chronic disease prospective study cohort database, and the WorldClim high spatial resolution global weather and climate database in the meteorological sciences field, etc.

[0033] Furthermore, the template for the first corpus is a command sentence or an interrogative sentence.

[0034] Step S2: Define a second corpus template, and concatenate the query text based on the second corpus template to obtain the query prompt text.

[0035] Further, step S2 includes:

[0036] Based on the size and scope of the target domain database, set the parameter N for the number of retrieval texts to be generated;

[0037] Define a second corpus template, which is a command sentence or an interrogative sentence. Combine the query text with the quantity parameter N to obtain the query prompt text.

[0038] Step S3: Input the data prompt text and query prompt text into the large language model respectively to generate response text and search text respectively.

[0039] Specifically, the data prompt text is input into the large language model to generate knowledge-enhanced response text;

[0040] Input the query suggestion text into the large language model, and obtain N knowledge-enhanced search texts based on the quantity parameter N.

[0041] Step S4: Input the query text, retrieval text, and response text into the natural language processing model to generate query text features, retrieval text features, and response text features.

[0042] Further, step S4 includes:

[0043] Input the query text and the retrieved text into the natural language processing model to obtain the feature vector of each text unit in the query text and the retrieved text.

[0044] Input the response text into the natural language processing model to obtain the feature vector of each text unit in the response text;

[0045] For natural language processing models that include special units [CLS], the feature vectors corresponding to the text units [CLS] are used as the high-dimensional feature vectors of the text.

[0046] For natural language processing models that do not contain special units [CLS], the average value of the feature vectors corresponding to all text units is used as the high-dimensional feature vector of the text.

[0047] Step S5: Perform weighted fusion of query text features and retrieval text features to obtain fused text features.

[0048] Furthermore, the query text features and retrieval text features are weighted and fused, as shown in the following expression:

[0049]

[0050] In the formula, M is the fused text feature vector, N is the number of generated retrieval texts, λ is the query text weight, and d k f(.) is the k-th search text generated by the large language model, f(.) is the vectorization operation, and q is the query text.

[0051] Step S6: Calculate the similarity between the fused text features and the response text features, and export the data corresponding to the top K response text features with the highest similarity from the SQL table as the retrieval results.

[0052] Furthermore, in this example, Euclidean distance or cosine distance is used to calculate the similarity between the fused text features and the response text features.

[0053] The expression for calculating Euclidean distance is as follows:

[0054]

[0055] The expression for calculating the cosine distance is as follows:

[0056]

[0057] In the formula, r i In response to the i-th dimension feature of text feature R, m i Let P be the i-th dimension of the fused text feature M, where P is the dimension of the high-dimensional feature vector.

[0058] Based on the similarity calculation results, the data corresponding to the K most similar response texts are used as the user's query results. The corresponding data content is exported from an SQL table and returned to the user. Preferably, K can be adjusted by the user according to their needs, and the value of K is greater than 0 and less than or equal to the number of data types in the database.

[0059] Example 1

[0060] The following examples further illustrate the professional domain database retrieval method and system based on large model knowledge enhancement proposed in this invention.

[0061] In this embodiment of the invention, a computing server is provided for data storage, computation, and the implementation of retrieval methods. This server is equipped with one Intel Xeon Silver 4214 GPU, two Nvidia V100 GPUs, 256GB DDR4-2666MHz memory, a Crucial 4TB SSD, and a Lenovo T24A-10 LCD monitor.

[0062] In this embodiment of the invention, the UK Biobank database is used as an example of a specialized domain database to demonstrate the effectiveness of the invention. The UK Biobank database is a large-scale life science database containing biomedical data samples from approximately 500,000 participants aged 45 to 69, specifically including data types such as population data, genetic data, human imaging data, and cognitive and psychological data, totaling 15,205 sample fields. The specific steps of the specialized domain database retrieval method based on large-model knowledge enhancement for the UK Biobank database are as follows:

[0063] Step S1: Obtain the keywords and descriptions corresponding to each type of data in the target domain database, and match the keywords and descriptions corresponding to each type of data with data links and content to obtain the SQL table of the target domain; define the first corpus template, and concatenate the keywords and descriptions based on the first corpus template to obtain the data prompt text.

[0064] The keywords and description fields of 15,205 data samples in the database are extracted. This embodiment takes the keywords and descriptions of the "demographic characteristics" sample data as an example; for example, such as Figure 3 As shown, the template for the first corpus is defined as follows:

[0065] "As an experienced healthcare professional, biologist, medical expert, and sociology researcher, your task is to transform the following items from the UK Biobank database into content-rich summaries. Then, analyze the significance of this content in the context of precision medicine and personal health management:"

[0066] [Keywords] refer to a type of data in the UK Biobank database. [Description].

[0067] Keywords: demographic characteristics;

[0068] The description is as follows: This category contains characteristic data of the participants. It includes two subcategories: (1) baseline characteristics and (2) persistent characteristics.

[0069] Based on the first corpus template, keywords and their descriptions are concatenated to obtain the following data prompt text:

[0070] "As a research team comprised of experienced healthcare professionals, biologists, medical experts, and sociological researchers, your task is to translate the following items from the UK Biobank database into highly readable summaries. Subsequently, analyze the significance of this content in the context of precision medicine and personal health management:"

[0071] Demographic characteristics are a category of data in the UK Biobank database. This category contains characteristic data of participants. It includes two subcategories: (1) baseline characteristics and (2) ongoing characteristics.

[0072] Step S2: Define a second corpus template, and concatenate the query text based on the second corpus template to obtain the query prompt text.

[0073] The system receives query text input by the user. This embodiment uses "blood-related data" as an example. For instance,... Figure 4 As shown, the template for the second corpus is:

[0074] "As an experienced healthcare professional, biologist, medical expert, and sociology researcher, your task is to transform the following query into [N] rich, concise summaries from the UK Biobank database to better retrieve relevant queries from the UK Biobank:"

[0075] [User query text].

[0076] Query text: Blood-related data;

[0077] The number of retrieved texts generated, N, is set to 10.

[0078] Based on the second corpus template, the query text is concatenated to obtain the following query suggestion text:

[0079] "As an experienced healthcare professional, biologist, medical expert, and sociology researcher, your task is to transform the following query into 10 well-structured and concise summaries from the UK Biobank database to better retrieve relevant information from the UK Biobank:"

[0080] Blood-related data.

[0081] Step S3: Input the data prompt text and query prompt text into the large language model respectively to generate response text and search text respectively.

[0082] Furthermore, in this example, the "Tongyi 1000 Questions 7B Model" is selected as the large language model for knowledge enhancement.

[0083] Specifically, the data prompt text is input into the large language model to generate knowledge-enhanced response text;

[0084] For example, the generated knowledge-enhanced response text is:

[0085] “The ‘demographic profile’ in UK biobanks contains important information about participants, which helps to provide a comprehensive understanding of their basic profile, such as age, gender, education level, occupation, health status (such as smoking or pre-existing conditions) and family medical history.”

[0086] This information is divided into two subcategories:

[0087] 1. Baseline characteristics: These are the initial attributes collected at the start of the study, reflecting background information about the participants. Examples include age, gender, education level, occupation, and health status. Understanding these factors helps researchers establish a basis for assessing individual health risks.

[0088] 2. Continuous Features: This subclass contains data that changes over time and is crucial for time-series precision medicine. It can track lifestyle changes, medical events, or other factors that may affect health. Monitoring these continuous features enables more personalized interventions and targeted treatments based on real-time information.

[0089] Impact on precision medicine and health management:

[0090] 1. Genetic diversity: Baseline characteristics provide insights into the genetic composition of a population, helping to discover associations between diseases and genetic factors and to develop customized genetic tests.

[0091] 2. Risk stratification: By analyzing this data, healthcare professionals can identify high-risk individuals with specific conditions, enabling early intervention and personalized preventative measures.

[0092] 3. Lifestyle tracking: Continuous characteristics allow researchers to assess lifestyle habits that may affect health, such as dietary or exercise habits. This provides a basis for personalized recommendations to improve overall health and reduce disease risk.

[0093] 4. Dynamic Health Management: Precision medicine often involves adjustments based on changes in circumstances. Data from the UK Biobank allows for continuous monitoring of participants' characteristics, enabling adjustments to treatment plans as needed.

[0094] 5. Public Health Policy: Understanding demographic characteristics can guide the development of public health policies and allocate resources to specific groups with higher needs.

[0095] In summary, the demographic characteristics of UK biobanks provide a rich source of data for precision medicine and health management, helping researchers identify risk factors, track changes, and develop personalized strategies for individuals.

[0096] Furthermore, the query prompt text is input into the large language model, and N knowledge-enhanced retrieval texts are obtained based on the quantity parameter N.

[0097] For example, the generated knowledge-enhanced retrieval text is:

[0098] To help you retrieve blood data more effectively from the UK Biobank database, here are 10 comprehensive and concise summaries, each focusing on a different aspect of blood data to guide your precise queries:

[0099] 1. Complete blood count: Retrieves red blood cell count, hemoglobin, hematocrit, mean corpuscular volume, white blood cell count and differential, platelet count, and assesses anemia, infection, or blood disorders.

[0100] 2. Biochemical indicators: Check liver enzyme activity, kidney function, blood glucose, blood lipids, and inflammatory markers for chronic disease risk assessment.

[0101] 3. Genetic associations: Analyzing the relationship between genetic variations and blood parameters, including genotypic and phenotypic associations with hereditary blood disorders.

[0102] 4. Metabolomics: Studying metabolites in blood samples, such as amino acids, fatty acids, and glucose derivatives, to identify biomarkers associated with metabolic syndrome, cardiovascular disease, and diabetes.

[0103] 5. Drug responsiveness: Assess pharmacokinetic and pharmacodynamic parameters, and monitor the effects of drugs on blood parameters, including drug concentration and drug-induced hematological changes.

[0104] 6. Immune cell analysis: Examine white blood cell subsets, including T cells, B cells, natural killer cells, and monocytes, to assess the status of the immune system and immune-related diseases.

[0105] 7. Cardiovascular disease biomarkers: Identify blood biomarkers associated with cardiovascular disease, such as myocardial injury markers, heart failure markers, and atherosclerosis markers.

[0106] 8. Genetic Risk Score: Calculates the contribution of genetic factors to abnormal blood parameters and predicts the risk of cardiovascular disease, diabetes, and certain cancers.

[0107] 9. Environmental Exposure and Blood Parameters: Analyze the impact of environmental factors, such as air pollution and heavy metal exposure, on blood parameters and assess environmental health risks.

[0108] 10. Lifestyle factors: Assess the impact of diet, exercise, smoking, and alcohol consumption habits on blood parameters such as blood pressure, blood sugar, and lipid levels to promote recommendations for a healthy lifestyle.

[0109] Step S4: Input the query text, retrieval text, and response text into the natural language processing model to generate query text features, retrieval text features, and response text features.

[0110] Further, step S4 includes:

[0111] The query text and the retrieved text are input into the natural language processing model to obtain the feature vector of each text unit in the query text and the retrieved text. In this example, the "Sentence-BERT-base model" is selected as the natural language processing model, which can convert text sentences into 768-dimensional feature vectors.

[0112] Input the response text into the natural language processing model to obtain the feature vector of each text unit in the response text;

[0113] Since the Sentence-BERT-base model contains special units [CLS], the feature vectors corresponding to the special units [CLS] can be used as high-dimensional feature vectors of the input text.

[0114] Step S5: Perform weighted fusion of query text features and retrieval text features to obtain fused text features.

[0115] Furthermore, the query text features and retrieval text features are weighted and fused, as shown in the following expression:

[0116]

[0117] In the formula, M is the fused text feature vector, N is the number of generated retrieval texts (N = 10 in this example), λ is the query text weight (λ = 5 in this example), and d k f(.) is the k-th search text generated by the large language model, f(.) is the vectorization operation, and q is the query text.

[0118] Step S6: Calculate the similarity between the fused text features and the response text features, and export the data corresponding to the top K response text features with the highest similarity from the SQL table as the retrieval results.

[0119] Furthermore, in this example, Euclidean distance or cosine distance is used to calculate the similarity between the fused text features and the response text features.

[0120] Based on the similarity calculation results, the data corresponding to the K most similar response texts are used as the user's query results. The corresponding data content is exported from the SQL table and returned to the user. Preferably, K can be adjusted by the user according to their needs. The value of K is greater than 0 and less than or equal to the number of data types in the database. In this example, K is an integer greater than 0 and less than or equal to 15205.

[0121] In this embodiment, the K value is set to 3, and the search results for "blood-related data" are shown in Table 1 below.

[0122] Table 1: Query Results Table

[0123]

[0124]

[0125] As shown in Table 1, when a user enters "blood-related data" to query the UK Biobank database, three blood-related items are returned: "blood-immunodeficiency report", "blood sample collection report", and "blood-anemia report". This demonstrates the effectiveness of the professional domain database retrieval method based on large model knowledge enhancement proposed in this invention.

[0126] Accordingly, this application also provides an electronic device, comprising: one or more processors; a memory for storing one or more programs; and, when the one or more programs are executed by the one or more processors, causing the one or more processors to implement the aforementioned domain-specific database retrieval method based on large model knowledge enhancement. Figure 5 The diagram shown illustrates a hardware structure of any device with data processing capabilities for the professional domain database retrieval method based on large model knowledge enhancement provided in this embodiment of the invention. (Except for...) Figure 5 In addition to the processor, memory device, input device, and network interface shown, any data processing device in the embodiment may also include other hardware depending on the actual function of the data processing device, which will not be described in detail here.

[0127] Accordingly, this application also provides a computer-readable storage medium storing computer instructions, which, when executed by a processor, implement the aforementioned domain-specific database retrieval method based on large model knowledge enhancement. The computer-readable storage medium can be an internal storage unit of any data-processing device as described in this embodiment, such as a hard disk or memory. The computer-readable storage medium can also be an external storage device, such as a plug-in hard disk, smart media card (SMC), SD card, flash card, etc., equipped on the device. Further, the computer-readable storage medium can also simultaneously include both internal storage units and external storage devices of any data-processing device. The computer-readable storage medium is used to store the computer program, as well as other programs and data required by the data-processing device, and can also be used to temporarily store data that has been output or will be output.

[0128] The above embodiments are only used to illustrate the design concept and features of the present invention, and their purpose is to enable those skilled in the art to understand the content of the present invention and implement it accordingly. The protection scope of the present invention is not limited to the above embodiments. Therefore, all equivalent changes or modifications made based on the principles and design ideas disclosed in the present invention are within the protection scope of the present invention.

Claims

1. A professional domain database retrieval method based on knowledge enhancement using a large language model, characterized in that, The method includes: Obtain the keywords and descriptions corresponding to each type of data in the target domain database, and match the keywords and descriptions corresponding to each type of data with data links and content to obtain the SQL table of the target domain database; define the first corpus template, and concatenate the keywords and descriptions based on the first corpus template to obtain the data prompt text; Define a second corpus template, and concatenate the user-input query text based on the second corpus template to obtain the query prompt text; Input the data prompt text and query prompt text into the large language model, and generate response text and search text respectively; Input the query text, retrieval text, and response text into the natural language processing model to generate query text features, retrieval text features, and response text features; The query text features and the retrieval text features are weighted and fused to obtain the fused text features; Calculate the similarity between the fused text features and the response text features, and export the data corresponding to the top K response text features with the highest similarity from the SQL table as the retrieval results.

2. The method for retrieving a professional domain database based on knowledge enhancement using a large language model as described in claim 1, characterized in that, The target domain databases include: the UK Biobank, the China Chronic Disease Prospective Study Cohort Database, or a high spatial resolution global weather and climate database in the field of meteorology.

3. The method for retrieving a professional domain database based on knowledge enhancement using a large language model according to claim 1, characterized in that, The first corpus template is a command sentence or an interrogative sentence.

4. The method for retrieving a professional domain database based on knowledge enhancement using a large language model according to claim 1, characterized in that, The process of obtaining query suggestion text includes: Based on the size and scope of the target domain database, set the parameter N for the number of retrieval texts to be generated; Define a second corpus template, which is a command sentence or an interrogative sentence. Combine the query text with the quantity parameter N to obtain the query prompt text.

5. A professional domain database retrieval method based on large language model knowledge enhancement according to claim 1, characterized in that, The process of inputting query text, retrieval text, and response text into a natural language processing model to generate query text features, retrieval text features, and response text features includes: Input the query text and the retrieved text into the natural language processing model to obtain the feature vector of each text unit in the query text and the retrieved text. Input the response text into the natural language processing model to obtain the feature vector of each text unit in the response text; For natural language processing models that include special units [CLS], the feature vectors corresponding to the text units [CLS] are used as the high-dimensional feature vectors of the text. For natural language processing models that do not contain special units [CLS], the average value of the feature vectors corresponding to all text units is used as the high-dimensional feature vector of the text.

6. The method for retrieving a professional domain database based on knowledge enhancement using a large language model according to claim 1, characterized in that, The process of weightedly fusing query text features and retrieval text features to obtain fused text features includes: In the formula, M is the fused text feature vector, N is the number of generated retrieval texts, λ is the query text weight, and d k f(.) is the k-th search text generated by the large language model, f(.) is the vectorization operation, and q is the query text.

7. A professional domain database retrieval method based on large language model knowledge enhancement according to claim 1, characterized in that, Calculating the similarity between fused text features and response text features includes: The similarity between the fused text features and the response text features is calculated using Euclidean distance or cosine distance.

8. An electronic device comprising a memory and a processor, characterized in that, The memory is coupled to the processor; wherein the memory is used to store program data, and the processor is used to execute the program data to implement the professional domain database retrieval method based on large language model knowledge enhancement as described in any one of claims 1-7.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the domain database retrieval method based on large language model knowledge enhancement as described in any one of claims 1-7.

10. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instruction is executed by the processor, it implements the domain-specific database retrieval method based on large language model knowledge enhancement as described in any one of claims 1-7.