CN117290492A - Knowledge base question-answering method and device, electronic equipment and storage medium - Google Patents

Knowledge base question-answering method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN117290492A
CN117290492A CN202311587827.2A CN202311587827A CN117290492A CN 117290492 A CN117290492 A CN 117290492A CN 202311587827 A CN202311587827 A CN 202311587827A CN 117290492 A CN117290492 A CN 117290492A
Authority
CN
China
Prior art keywords
question
query
similar
knowledge base
questions
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202311587827.2A
Other languages
Chinese (zh)
Inventor
张俊峰
张炜
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Lingzhi Digital Technology Co ltd
Original Assignee
Shenzhen Lingzhi Digital Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Lingzhi Digital Technology Co ltd filed Critical Shenzhen Lingzhi Digital Technology Co ltd
Priority to CN202311587827.2A priority Critical patent/CN117290492A/en
Publication of CN117290492A publication Critical patent/CN117290492A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/332Query formulation
    • G06F16/3329Natural language query formulation or dialogue systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/3331Query processing
    • G06F16/334Query execution
    • G06F16/3344Query execution using natural language analysis
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/33Querying
    • G06F16/338Presentation of query results
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/34Browsing; Visualisation therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing
    • G06F40/216Parsing using statistical methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Computational Linguistics (AREA)
  • Artificial Intelligence (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Mathematical Physics (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • General Health & Medical Sciences (AREA)
  • Human Computer Interaction (AREA)
  • Probability & Statistics with Applications (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application is applicable to the technical field of artificial intelligence, and provides a knowledge base question-answering method, a knowledge base question-answering device, electronic equipment and a storage medium, wherein the knowledge base question-answering method comprises the following steps: acquiring a query question, and retrieving a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base by using a pre-trained vector coding model; and the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode, constructs query prompt words according to the query questions, the similar questions and answers of the similar questions, and generates query answers of the query prompt words by utilizing a pre-trained large language model. The method and the device can accurately generate the query answer based on the query question.

Description

Knowledge base question-answering method and device, electronic equipment and storage medium
Technical Field
The application belongs to the technical field of artificial intelligence, and particularly relates to a knowledge base question-answering method, a knowledge base question-answering device, electronic equipment and a computer readable storage medium.
Background
In the field of question and answer at present, such as an intelligent customer service question and answer system of a supermarket, for a question input by a user, matching a local question and answer library and feeding back answers of the most similar questions to the user; or directly generating answers to the questions through the language model and feeding back the answers to the questions to the user. However, because the number of question-answer data in the question-answer library may be insufficient, the language model may deviate from the questions of the user, and the like, the questions of the user may not be accurately answered, and the user experience is affected.
Disclosure of Invention
The embodiment of the application provides a knowledge base question-answering method, a knowledge base question-answering device, electronic equipment and a computer readable storage medium, which can accurately generate query answers based on query questions.
In a first aspect, an embodiment of the present application provides a knowledge base question-answering method, including:
acquiring a query question, and retrieving a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base by using a pre-trained vector coding model; the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode;
constructing a query prompt word according to the query question, the similar question and the answer of the similar question;
and generating query answers of the query prompt words by utilizing a pre-trained large language model.
Optionally, before retrieving the multiple similar questions of the query question and the answers corresponding to the similar questions from the question-answer knowledge base by using the pre-trained vector coding model, the method further includes:
acquiring a history dialogue set and a preset text vectorization model;
constructing a similar problem set based on the historical dialogue set and the question-answering knowledge base;
And fine tuning the text vectorization model by using the historical dialogue set, the question-answering knowledge base and the similar problem set to obtain the pre-trained vector coding model.
Optionally, the constructing a similar problem set based on the historical dialogue set and the question-answer knowledge base includes:
acquiring an open source problem pair set, and constructing a training prompt word based on problem pairs in the open source problem pair set and problems in the question-answering knowledge base;
determining a first similar problem according to the training prompt word;
recall a second similar problem from the historical dialog collection; the second similar question is a question similar to a question in the question-and-answer knowledge base in the historical dialog set;
and marking the first similar problem and the second similar problem, and obtaining the similar problem set based on the marked first similar problem and second similar problem.
Optionally, the fine tuning the text vectorization model by using the historical dialogue set, the question-answer knowledge base and the similar problem set to obtain the pre-trained vector coding model includes:
taking the similar problem set as a supervised training data set, and taking the historical dialogue set and the question-answering knowledge base as an unsupervised training data set;
Calculating a first loss using the supervised training data set and the text vectorization model;
calculating a second loss using the unsupervised training data set and the text vectorization model;
and fine tuning the text vectorization model based on the first loss and the second loss to obtain the vector coding model.
Optionally, before the generating the query answer of the query prompt word by using the pre-trained large language model, the method further includes:
utilizing a preset fine tuning instruction template to adjust the format of the question-answer data in the question-answer knowledge base to obtain a fine tuning data set; the fine tuning instruction template is a standard format template for adjusting the question-answer data format;
and performing fine tuning on a preset language model based on the fine tuning data set to obtain the pre-trained large language model.
Optionally, the fine tuning the preset language model based on the fine tuning data set includes:
freezing a portion of the parameters in the language model;
calculating a third loss using the frozen language model and the fine tuning data set;
and adjusting unfrozen parameters in the language model based on the third loss.
Optionally, the retrieving, by using the pre-trained vector coding model, a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base includes:
carrying out vectorization processing on the query problem by using the vector coding model to obtain a query vector;
and obtaining a plurality of similar questions of the query questions and answers corresponding to the similar questions from the question-answering knowledge base according to the matched vector data by utilizing the vector data in the query vector matching vector database, wherein the vector data in the vector database is obtained by carrying out vectorization processing on the questions in the question-answering knowledge base through the vector coding model.
Optionally, the constructing a query term according to the query question, the similar question, and the answer of the similar question includes:
filtering abnormal problems in the similar problems according to the query problems to obtain filtering problems;
and under the condition that the filtering questions comprise at least one similar question, constructing the query prompt words according to the query questions, the filtering questions and answers of the filtering questions.
In a second aspect, an embodiment of the present application provides a knowledge base question-answering apparatus, including:
The similar problem acquisition module is used for acquiring a query problem, and searching a plurality of similar problems of the query problem and answers corresponding to the similar problems from a question-answer knowledge base by utilizing a pre-trained vector coding model; the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode;
the query prompt word construction module is used for constructing query prompt words according to the query questions, the similar questions and answers of the similar questions;
and the query answer generation module is used for generating the query answer of the query prompt word by utilizing the pre-trained large language model.
In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and capable of running on the processor, where the steps of the knowledge base question-answering method according to the first aspect are implemented when the processor executes the computer program.
In a fourth aspect, embodiments of the present application provide a computer readable storage medium storing a computer program, where the computer program implements the steps of the knowledge base question-answering method according to the first aspect when executed by a processor.
In a fifth aspect, embodiments of the present application provide a computer program product, which when run on an electronic device, causes the electronic device to perform the knowledge base question-answering method according to any one of the first aspects above.
Compared with the prior art, the embodiment of the application has the beneficial effects that:
in the embodiment of the application, the plurality of similar questions of the query questions are retrieved from the question-answer knowledge base, the query prompt words are constructed by utilizing the similar questions, and the query answers can be accurately generated according to the pre-trained large language model. Specifically, since the questions are recalled from the question-answer knowledge base based on the form of vector retrieval by the vector encoding model, and the vector retrieval can quickly query the question data in the question-answer database, a plurality of similar questions of the query questions can be quickly retrieved from the question-answer knowledge base. After obtaining a plurality of similar questions, because the query prompt words are constructed according to the query questions, the similar questions and answers of the similar questions, when the query answers of the query prompt words are generated by utilizing the pre-trained large language model, the large language model is guided to generate the query answers according to the similar questions and answers of the similar questions, so that the questions of a user deviating from a question answering system are avoided, and the accuracy of generating the query answers is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following description will briefly introduce the drawings that are needed in the embodiments or the description of the prior art, it is obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a flowchart of a knowledge base question-answering method according to an embodiment of the present application;
fig. 2 is a schematic structural diagram of a knowledge base question-answering device provided in an embodiment of the present application;
fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system configurations, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It should be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
As used in this specification and the appended claims, the term "if" may be interpreted as "when..once" or "in response to a determination" or "in response to detection" depending on the context. Similarly, the phrase "if a determination" or "if a [ described condition or event ] is detected" may be interpreted in the context of meaning "upon determination" or "in response to determination" or "upon detection of a [ described condition or event ]" or "in response to detection of a [ described condition or event ]".
Reference in the specification to "one embodiment" or "some embodiments" or the like means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," and the like in the specification are not necessarily all referring to the same embodiment, but mean "one or more but not all embodiments" unless expressly specified otherwise. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless expressly specified otherwise.
In the intelligent question-answering, a local knowledge base is generally maintained in combination with a service scene, standard questions and standard answers under the service scene are recorded in the local knowledge base, and the local knowledge base is used for inquiring similar questions from the question-answering knowledge base according to questions input by a user and feeding back corresponding standard answers to the user; with the development of artificial intelligence, corresponding answers can be directly generated based on questions input by users through a language model, but as business scenes can be subdivided into different fields, when the language model learns knowledge in different fields, a catastrophic forgetting phenomenon exists, namely, the language model forgets knowledge learned in the previous field when learning knowledge in a specific field, so when generating answers to questions of users through the language model, the language model often deviates from the questions of the users for the questions of the different fields, and the generated answers are inaccurate.
In order to improve the accuracy of query answer generation, the application provides a knowledge base question-answering method based on query prompt words and a large language model.
Fig. 1 shows a flow chart of a knowledge base question-answering method provided in the embodiment of the present application, which is described in detail below:
s1, acquiring a query question, and searching a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base by using a pre-trained vector coding model; the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode.
In this embodiment of the present application, the query question refers to a question input by a user through a client, a web page end, etc., for example, in a supermarket intelligent customer service scenario, the user inputs a query question about a commodity through an APP client. The question-answer knowledge base refers to a high-quality question-answer database maintained by operation staff according to a service scene, for example, the high-quality question-answer database is adjusted and constructed by the operation staff based on a historical dialogue record of a customer service system, a manually constructed standard question-answer operation and the like.
The vector coding model refers to a text vectorization model, which is used for vectorizing texts and processing data by using the vectorized texts. Alternatively, the vector coding model may be a text2vec-large-Chinese model, a BERT model, or the like.
In the embodiment of the application, the questions in the question-answering knowledge base can be vectorized and encoded first, vectorized results are stored, the query questions are vectorized and encoded according to a vector encoding model, the vectors of the questions in the question-answering knowledge base are searched through the vectors after the query questions are encoded, the similarity degree of the vectors after the query questions are encoded and the vectors of the questions after the query questions are encoded in the searched question-answering knowledge base is calculated, the similar questions of the query questions are recalled from the question-answering knowledge base according to the similarity degree, and the data processing capacity can be improved due to vector searching, so that a plurality of similar questions of the query questions and answers corresponding to the similar questions can be quickly searched from the question-answering knowledge base through the vector encoding model.
S2, constructing a query prompt word according to the query question, the similar question and the answer of the similar question.
In this embodiment of the present application, the query term may be constructed according to a query term (prompt) template, and the query term is constructed by using the query term template, so that answers of a query question, a similar question, and a similar question may be unified in one query term. The query prompt words not only comprise the query questions, but also comprise similar questions of the query questions and answers of the similar questions, so that the subsequent large language model can be helped to better understand the intention of the query questions input by the user.
In some embodiments, the query term template may be "known information: { context }, based on the above known information, compact and professional answers to the user's questions. If an answer cannot be obtained from the answer, please say "the question cannot be answered according to the known information" or "sufficient relevant information is not provided", the addition of the composition to the answer is not allowed, and the answer is made using Chinese. The problems are: { query } ", wherein context is formed by splicing a plurality of similar questions recalled and the contents of answers of the similar questions, and query is a query question of a user.
S3, generating query answers of the query prompt words by utilizing the pre-trained large language model.
In this embodiment of the present application, the pre-trained large language model refers to a language model obtained by training on ultra-large scale pre-training data, including: a transducer-Based large language Model (transducers-Based Models), a self-encoder-Based large language Model (Autoencoder-Based Models), and the like. For example, the large language model may be a Transformer-based Universal-thousand (Qwen-7 b) model. The query prompt word can prompt the query intention of the query question for the large language model, which means that when the large language model is used for generating the query answer, the query prompt word can enable the model to recall the knowledge learned in advance, thereby avoiding the occurrence of catastrophic forgetting phenomenon and improving the accuracy of generating the query answer.
In the embodiment of the application, the plurality of similar questions of the query questions are retrieved from the question-answer knowledge base, the query prompt words are constructed by utilizing the similar questions, and the query answers can be accurately generated according to the pre-trained large language model. Specifically, since the questions are recalled from the question-answer knowledge base based on the form of vector retrieval by the vector encoding model, and the vector retrieval can quickly query the question data in the question-answer database, a plurality of similar questions of the query questions can be quickly retrieved from the question-answer knowledge base. After obtaining a plurality of similar questions, because the query prompt words are constructed according to the query questions, the similar questions and answers of the similar questions, when the query answers of the query prompt words are generated by utilizing the pre-trained large language model, the large language model is guided to generate the query answers according to the similar questions and answers of the similar questions, so that the questions of a user deviating from a question answering system are avoided, and the accuracy of generating the query answers is improved.
In another optional embodiment of the present application, before the searching the multiple similar questions of the query question and the answers corresponding to the similar questions from the question-answer knowledge base by using the pre-trained vector coding model, the method further includes:
Acquiring a history dialogue set and a preset text vectorization model;
constructing a similar problem set based on the historical dialogue set and the question-answering knowledge base;
and fine tuning the text vectorization model by using the historical dialogue set, the question-answering knowledge base and the similar problem set to obtain the pre-trained vector coding model.
In some embodiments, the historical dialogue collection refers to dialogue records that different users communicate with customer service personnel, after-sales personnel, etc. in a supermarket intelligent customer service scene. The Text vectorization model can characterize texts (including words, sentences, paragraphs and the like) as vector matrixes, and calculate the similarity between the texts on the basis of the vector characterization, and the Text vectorization model can be Text2vec-large-Chinese. The Fine Tuning (Fine Tuning) refers to adjusting model parameters of a pre-trained model by using data in a real service scene, so that the model learns knowledge of the real service scene and meets the requirements of the real service scene. By constructing the historical dialogue set and the question-answering knowledge base into a similar problem set, more similar problems related to business scenes can be obtained. When the text vectorization model is finely tuned by using the historical dialogue set, the question-answering knowledge base and the similar problem set, the historical dialogue set and the question-answering knowledge base reflect the domain knowledge in the real service scene, and the similar problem set is constructed by the historical dialogue set and the question-answering knowledge base to indicate that the similar problem set is the domain knowledge expanded according to the real service scene, so that the text vectorization model is finely tuned by using the historical dialogue set, the question-answering knowledge base and the similar problem set, the text vectorization model can learn richer domain knowledge, and the finely tuned vector coding model accords with the requirement of the real service scene more.
In this embodiment of the present application, the constructing a similar problem set based on the historical dialog set and the question-answering knowledge base includes:
acquiring an open source problem pair set, and constructing a training prompt word based on the problem pairs in the open source problem pair set and the problems in the question-answering knowledge base;
determining a first similar problem according to the training prompt word;
recall a second similar problem from the set of historical conversations; the second similar problem is a problem in the historical dialogue collection similar to a problem in the question-answer knowledge base;
and marking the first similar problem and the second similar problem, and obtaining the similar problem set based on the marked first similar problem and second similar problem.
In some embodiments, in order to obtain more abundant similar questions conforming to the real business scenario, the present application obtains different similar questions through the history dialogue set and the question-answering knowledge base respectively. Wherein the open source question pair set refers to a question set containing similar question pairs, the training prompt word (prompt) can be constructed based on a training prompt word (prompt) template, and because the training prompt word (prompt) includes similar question pairs and questions in a question-and-answer knowledge base, questions similar to the questions in the question-and-answer knowledge base, namely the first similar questions, can be generated based on the similar question pairs, and questions similar to the questions in the question-and-answer knowledge base, namely the second similar questions, can be recalled from a history dialogue set in a real business scene; labeling the similarity degree of the first similar problem and the second similar problem and the problems in the question-answering knowledge base to obtain the similar problem set.
In an alternative embodiment, the training prompt template may be "give you a question: { problem 1}, its similar problem is: { problem 2}; now give you a question again; { problem 3}, giving 5 similar problems to it). A text generation model (e.g., a GPT model) may be used to generate a first similar question, e.g., filling similar question pairs in the set of open source question pairs into question 1 and question 2, filling questions in the question-answer knowledge base into question 3, and obtaining the training prompt word "give you a question: how to replace a bound bank card, its similar problems are: changing the binding bank card; now give you a question again; r3 system-why the commodity is automatically stopped, giving 5 questions similar to it). By entering a text generation model (e.g., a GPT model), a first similar problem may be obtained including: "why does the merchandise in the R3 system automatically cease to purchase? "," why will the merchandise in the R3 system automatically cease to be purchased? How do "explain the problem of automatic stop of merchandise in R3 systems? What is the reason why the commodity was automatically purchased in the "R3 system? "," can the merchandise sales be stopped manually in the R3 system? ", thereby performing data enhancement based on few-shot capability of a text generation model (such as a GPT model); for the second similar problem, the history dialogue set may be split into separate sentences, the Text vectorization model (e.g. Text2 vec-large-Chinese) is directly used to vectorize the sentences, the sentences are stored in the vector index library, the similar problem of top5 is recalled from the history dialogue set as the second similar problem by using the problem in the knowledge question-answering library, and the problem with lower similarity can be filtered by similarity, for example, for the problem "R3 system-commodity is automatically purchased? By way of example, the filtered second similar problem may include: "the commodity is stopped and purchased yesterday, the stop purchase list is not found, the user can watch the commodity with help, the user can see how the two single products are stopped and purchased, and the commodity stock treatment standard is eliminated when the food commodity in supermarket is stopped and purchased. And finally, labeling all the first similar problems and the second similar problems according to a 0 or 1 label, wherein if the first similar problems and the second similar problems are similar to the problems in the knowledge question-answering library, the label is 1, and if the first similar problems and the second similar problems are dissimilar to the problems in the knowledge question-answering library, the label is 0.
In an alternative embodiment of the present application, in order to improve the efficiency of data retrieval, the questions in the history dialogue set may be vectorized and then stored in the fasss vector engine, so as to provide an efficient and reliable similarity clustering and retrieval method.
In this embodiment of the present application, the fine tuning of the text vectorization model by using the historical dialogue set, the question-answering knowledge base, and the similarity problem set to obtain the pre-trained vector coding model includes:
taking the similar problem set as a supervised training data set, and taking the historical dialogue set and the question-answering knowledge base as an unsupervised training data set;
calculating a first loss using the supervised training data set and the text vectorization model;
calculating a second loss using the unsupervised training data set and the text vectorization model;
and fine-tuning the text vectorization model based on the first loss and the second loss to obtain the vector coding model.
In some embodiments, since the questions in the similar question set include labels, and the data in the historical dialogue set and the knowledge question-answering library do not include labels, the text vectorization model is fine-tuned by using the two types of data, so that the vector coding model can better learn different types of knowledge, and the accuracy of the vector coding model according to the vector recall questions is improved. Specifically, by using the similar problem set as the supervised training data set, and using the historical dialogue set and the question-answer knowledge base as the unsupervised training data set, and combining the supervised training (i.e., calculating the first loss by using the supervised training data set and the text vectorization model) and the unsupervised training (i.e., calculating the second loss by using the unsupervised training data set and the text vectorization model), the text vectorization model is finely tuned, so that a vector coding model with higher precision can be obtained.
In an alternative embodiment of the present application, when supervised training is performed, for a similar problem pair (i.e., a question summarized by a knowledge question-answering library and a corresponding first similar problem or a second similar problem) in a supervised training data set, splitting two texts of the similar problem pair into a plurality of character identifiers (token), converting the texts into token sequences, extracting deep semantic features from the token sequences by using text vectorization, obtaining a sentence feature sequence composed of text feature vectors corresponding to each token, obtaining a classification confidence coefficient according to the sentence feature sequences of the similar problem pair, and calculating a first loss between the classification confidence coefficient and a label, wherein the first loss can be calculated by using a cosineeingedingLoss loss function; in the non-supervision training, a simcse contrast learning method can be used, namely, for the same text in the non-supervision training data set, a text vectorization model is used for carrying out 2 times of reasoning to obtain 2 different vectors (2 vectors can be different because of the random process of dropouts in the text vectorization model), in one batch (namely, a small batch of training samples can divide the non-supervision training data set into a plurality of batches), 2 vectors obtained by one text are regarded as positive samples, the current text and other texts in the batches are regarded as negative samples, and a second loss is calculated according to the positive samples and the negative samples, wherein the second loss can be calculated by using a multiple negative rank loss function; and stopping training the text vectorization model after the first loss and the second loss meet a preset loss threshold value or the training number of the text vectorization model reaches a preset number of rounds to obtain the vector coding model.
In another optional embodiment of the present application, before the generating the query answer of the query term using the pre-trained large language model, the method further includes:
utilizing a preset fine tuning instruction template to adjust the format of the question-answer data in the question-answer knowledge base to obtain a fine tuning data set; the fine tuning instruction template is a standard format template for adjusting the format of question-answering data;
and performing fine tuning on the preset language model based on the fine tuning data set to obtain the pre-trained large language model.
In some embodiments, the preset trimming instruction template is a fixed instruction text, and is used for normalizing the format of the input data of the language model, and the trimming instruction template provides a fixed trimming instruction for the language model, so that the trimming instruction template performs parameter trimming on the instruction (which can be regarded as a special task), and the large language model can be better adapted to different tasks and fields, thereby improving the precision of the large language model.
In an alternative embodiment of the present application, the foregoing fine tuning Instruction template may include "instruction+input+output", and the fine tuning data to be adjusted is "Instruction: you are now a fine tuned model, please generate appropriate answers according to the following questions: input: what is company a? Output: company a was established in 1984 with company B in control, including … … ".
In another alternative embodiment of the present application, for the trimmed large language model, the answer generating capability of the large language model may be evaluated in the form of index evaluation, for example, indexes such as blu, rouge_Chinese, and the like may be used.
In this embodiment of the present application, fine tuning the preset language model based on the fine tuning data set includes:
freezing part of parameters in the language model;
calculating a third loss using the frozen language model and the fine-tuning data set;
and adjusting unfrozen parameters in the language model based on the third loss.
In an alternative embodiment, because the large language model has more parameters, the language model can learn the knowledge in the specific field by freezing the parameters, and meanwhile, the catastrophic forgetting phenomenon is avoided, so that the large language model has both specificity and universality. Assuming that the language model is Qwen-7b model, when performing fine-tuning of the language model, the input data is instruct+input in the fine-tuning data set, for example: you are now a fine-tuned model, please generate the appropriate answer to the following questions: what is company a? And splitting input data into a plurality of token types by using the language model, converting a text sequence into a token type sequence, extracting deep semantic features from the token type sequence by an encoder of a Qwen-7b model to obtain a sentence feature sequence formed by deep semantic features corresponding to each token type, outputting a final predicted answer by a decoder, calculating a third loss according to the predicted answer and a target answer (i.e. Output in a fine tuning data set) in the fine tuning data set, and carrying out back propagation and gradient updating on the language model according to the third loss when the language model training does not meet a preset training condition (including that the third loss does not meet a preset loss threshold or the number of model training rounds does not reach a preset round number and the like). And simultaneously, when the parameters are updated, freezing all parameters except the last 4 layers of transformers-blocks in the language model according to the freeze fine tuning method, namely updating network parameters of the last 4 layers only until the training of the language model meets preset training conditions. Alternatively, the parameter update may be performed according to a Low-order adaptive (LoRA) fine tuning method, a P-tuning v2 fine tuning method, or the like of the large language model.
In this embodiment of the present application, the searching, by using a pre-trained vector coding model, a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base includes:
vectorizing the query problem by using the vector coding model to obtain a query vector;
and obtaining a plurality of similar questions of the query questions and answers corresponding to the similar questions from the question-answering knowledge base according to the matched vector data by utilizing the vector data in the query vector matching vector database, wherein the vector data in the vector database is obtained by carrying out vectorization processing on the questions in the question-answering knowledge base through the vector coding model.
In some embodiments, for a local knowledge question-answering library, vector encoding can be performed through the vector encoding model and the information is stored in the vector database, for a query question, vector encoding is performed according to the vector encoding model to obtain a query vector, a plurality of vectors similar to the query vector are rapidly searched from the vector database through the vector encoding model, a plurality of questions corresponding to the plurality of vectors are used as a plurality of similar questions of the query question, and answers corresponding to the similar questions are obtained.
In an optional embodiment of the present application, the constructing a query term according to the query question, the similar question, and an answer to the similar question includes:
filtering abnormal problems in the similar problems according to the query problems to obtain filtering problems;
and under the condition that the filtering questions comprise at least one similar question, constructing the query prompt words according to the query questions, the filtering questions and answers of the filtering questions.
In some embodiments, since the similarity problem recalled by the vector encoding model may be abnormal, for example, the similarity degree with the query problem is low, the similarity problem lacks key information, and the like, in order to further improve the accuracy of generating the answer and the relativity with the query problem of the large language model, the multiple similarity problems may be filtered according to the similarity score of the similarity problem and the query problem and a preset similarity threshold, that is, the similarity problem with the similarity score lower than the similarity threshold is filtered, if the filtered problem still includes at least one similarity problem after the threshold is filtered, a query prompt word is constructed according to the query problem, the filtered problem, and the answer of the filtered problem, and the large language model is indicated to generate the query answer through the query prompt word.
If all the similar questions are filtered after the threshold filtering, the query questions of the user are directly used as the input of the fine-tuned large language model, and the query answers required by the user are generated based on the language organization, logical reasoning and other capabilities of the large model.
It should be understood that the sequence number of each step in the foregoing embodiment does not mean that the execution sequence of each process should be determined by the function and the internal logic of each process, and should not limit the implementation process of the embodiment of the present application in any way.
Corresponding to the knowledge base question-answering method described in the above embodiments, fig. 2 shows a schematic structural diagram of the knowledge base question-answering device provided in the embodiment of the present application, and for convenience of explanation, only the portions relevant to the embodiment of the present application are shown.
Referring to fig. 2, the apparatus may be a knowledge base question-answering apparatus 21, and the knowledge base question-answering apparatus 21 may include a similar question acquisition module 211, a query hint word construction module 212, and a query answer generation module 213.
Referring to fig. 2, the knowledge base question-answering apparatus 21 includes:
the similar problem obtaining module 211 is configured to obtain a query problem, and retrieve a plurality of similar problems of the query problem and answers corresponding to the similar problems from a question-answer knowledge base by using a pre-trained vector coding model; the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode;
The query term construction module 212 is configured to construct a query term according to the query question, the similar question, and an answer to the similar question;
the query answer generation module 213 is configured to generate a query answer of the query prompt word by using a pre-trained large language model.
In some embodiments, the knowledge base question-answering device 21 further includes a first model fine-tuning module, where before retrieving, from a question-answering knowledge base, a plurality of similar questions of the query question and answers corresponding to the similar questions by using a pre-trained vector coding model, the first model fine-tuning module includes:
acquiring a history dialogue set and a preset text vectorization model;
constructing a similar problem set based on the historical dialogue set and the question-answering knowledge base;
and fine tuning the text vectorization model by using the historical dialogue set, the question-answering knowledge base and the similar problem set to obtain the pre-trained vector coding model.
Correspondingly, the first model fine tuning module constructs a similar problem set based on the historical dialog set and the question-answering knowledge base by:
acquiring an open source problem pair set, and constructing a training prompt word based on problem pairs in the open source problem pair set and problems in the question-answering knowledge base;
Determining a first similar problem according to the training prompt word;
recall a second similar problem from the historical dialog collection; the second similar question is a question similar to a question in the question-and-answer knowledge base in the historical dialog set;
and marking the first similar problem and the second similar problem, and obtaining the similar problem set based on the marked first similar problem and second similar problem.
Optionally, the first model fine tuning module fine-tunes the text vectorization model by using the historical dialogue set, the question-answering knowledge base, and the similar problem set to obtain the pre-trained vector coding model, which includes:
taking the similar problem set as a supervised training data set, and taking the historical dialogue set and the question-answering knowledge base as an unsupervised training data set;
calculating a first loss using the supervised training data set and the text vectorization model;
calculating a second loss using the unsupervised training data set and the text vectorization model;
and fine tuning the text vectorization model based on the first loss and the second loss to obtain the vector coding model.
In some embodiments, the knowledge base question-answering device 21 further includes a second model fine-tuning module, where before the second model fine-tuning module is configured to generate the query answer of the query prompt word by using the pre-trained large language model, the second model fine-tuning module includes:
utilizing a preset fine tuning instruction template to adjust the format of the question-answer data in the question-answer knowledge base to obtain a fine tuning data set; the fine tuning instruction template is a standard format template for adjusting the question-answer data format;
and performing fine tuning on a preset language model based on the fine tuning data set to obtain the pre-trained large language model.
Optionally, the second model fine tuning module performs fine tuning on a preset language model based on the fine tuning data set, including:
freezing a portion of the parameters in the language model;
calculating a third loss using the frozen language model and the fine tuning data set;
and adjusting unfrozen parameters in the language model based on the third loss.
Optionally, the similar question obtaining module 211 retrieves a plurality of similar questions of the query question and answers corresponding to the similar questions from a knowledge base of questions and answers using a pre-trained vector coding model, including:
Carrying out vectorization processing on the query problem by using the vector coding model to obtain a query vector;
and obtaining a plurality of similar questions of the query questions and answers corresponding to the similar questions from the question-answering knowledge base according to the matched vector data by utilizing the vector data in the query vector matching vector database, wherein the vector data in the vector database is obtained by carrying out vectorization processing on the questions in the question-answering knowledge base through the vector coding model.
Optionally, the query term construction module 212 constructs a query term according to the query question, the similar question, and the answer of the similar question, including:
filtering abnormal problems in the similar problems according to the query problems to obtain filtering problems;
and under the condition that the filtering questions comprise at least one similar question, constructing the query prompt words according to the query questions, the filtering questions and answers of the filtering questions.
It should be noted that, because the content of information interaction and execution process between the devices/units is based on the same concept as the method embodiment of the present application, specific functions and technical effects thereof may be referred to in the method embodiment section, and details thereof are not repeated herein.
Fig. 3 is a schematic structural diagram of an electronic device according to an embodiment of the present application. As shown in fig. 3, the electronic apparatus 3 of this embodiment includes: at least one processor 30 (only one shown in fig. 3), a memory 31 and a computer program 33 stored in the memory 31 and executable on the at least one processor 30. The steps of any of the various method embodiments are performed by the processor 30 when executing the computer program 33.
The electronic device 3 may be a computing device such as a desktop computer, a notebook computer, a palm computer, a cloud server, etc. The electronic device may include, but is not limited to, a processor 30, a memory 31. It will be appreciated by those skilled in the art that fig. 3 is merely an example of the electronic device 3 and does not constitute a limitation of the electronic device 3, and may include more or fewer components than shown, or may combine certain components, or different components, e.g., the electronic device may further include an input transmitting device, a network access device, a bus, etc.
The processor 30 may be a central processing unit (Central Processing Unit, CPU), other general purpose processors, digital signal processors (Digital Signal Processor, DSP), application specific integrated circuits (Application Specific Integrated Circuit, ASIC), off-the-shelf programmable gate arrays (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 31 may in some embodiments be an internal storage unit of the electronic device 3, such as a hard disk or a memory of the electronic device 3. The memory 31 may be an external storage device of the electronic device 3, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card) or the like, which are provided on the electronic device 3. Further, the memory 31 may also include both an internal storage unit and an external storage device of the electronic device 3. The memory 31 is used for storing an operating system, application programs, boot loader (BootLoader), data, other programs etc., such as program codes of the computer program etc. The memory 31 may also be used for temporarily storing data that has been transmitted or is to be transmitted.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the division of the functional units and modules is illustrated, and in practical application, the functional distribution may be performed by different functional units and modules, that is, the internal structure of the apparatus is divided into different functional units or modules, so as to perform all or part of the functions described above. The functional units and modules in the embodiment may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit, where the integrated units may be implemented in a form of hardware or a form of a software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working process of the units and modules in the system may refer to the corresponding process in the foregoing method embodiment, which is not described herein again.
The embodiment of the application also provides a network device, which comprises: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, the processor implementing the steps in any of the various method embodiments when the computer program is executed.
Embodiments of the present application also provide a computer readable storage medium storing a computer program which, when executed by a processor, implements steps in the various method embodiments.
Embodiments of the present application provide a computer program product which, when run on an electronic device, causes the electronic device to perform steps that may be implemented in the various method embodiments described.
The integrated units, if implemented in the form of software functional units and sold or used as stand-alone products, may be stored in a computer readable storage medium. With such understanding, the present application implements all or part of the flow of the method of the embodiments, and may be implemented by a computer program to instruct related hardware, where the computer program may be stored in a computer readable storage medium, where the computer program, when executed by a processor, may implement the steps of the method embodiments. Wherein the computer program comprises computer program code which may be in source code form, object code form, executable file or some intermediate form etc. The computer readable medium may include at least: any entity or device capable of carrying computer program code to a camera device/electronic apparatus, a recording medium, a computer Memory, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), an electrical carrier signal, a telecommunications signal, and a software distribution medium. Such as a U-disk, removable hard disk, magnetic or optical disk, etc. In some jurisdictions, computer readable media may not be electrical carrier signals and telecommunications signals in accordance with legislation and patent practice.
In the embodiments, the descriptions of the embodiments are focused on, and the parts of a certain embodiment that are not described or depicted in detail can be referred to for related descriptions of other embodiments.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/network device and method may be implemented in other manners. For example, the apparatus/network device embodiments described above are merely illustrative, e.g., the division of the modules or units is merely a logical functional division, and there may be additional divisions in actual implementation, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection via interfaces, devices or units, which may be in electrical, mechanical or other forms.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
The above embodiments are only for illustrating the technical solution of the present application, and are not limiting; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present application, and are intended to be included in the scope of the present application.

Claims (10)

1. A knowledge base question-answering method, comprising:
acquiring a query question, and retrieving a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answer knowledge base by using a pre-trained vector coding model; the vector coding model recalls similar questions of the query questions from the question-answer knowledge base in a vector retrieval mode;
Constructing a query prompt word according to the query question, the similar question and the answer of the similar question;
and generating query answers of the query prompt words by utilizing a pre-trained large language model.
2. The knowledge base question-answering method according to claim 1, wherein before retrieving a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answering knowledge base using a pre-trained vector coding model, further comprising:
acquiring a history dialogue set and a preset text vectorization model;
constructing a similar problem set based on the historical dialogue set and the question-answering knowledge base;
and fine tuning the text vectorization model by using the historical dialogue set, the question-answering knowledge base and the similar problem set to obtain the pre-trained vector coding model.
3. The knowledge base question-answering method according to claim 2, wherein the constructing a set of similar questions based on the set of historical dialogs and the question-answering knowledge base includes:
acquiring an open source problem pair set, and constructing a training prompt word based on problem pairs in the open source problem pair set and problems in the question-answering knowledge base;
Determining a first similar problem according to the training prompt word;
recall a second similar problem from the historical dialog collection; the second similar question is a question similar to a question in the question-and-answer knowledge base in the historical dialog set;
and marking the first similar problem and the second similar problem, and obtaining the similar problem set based on the marked first similar problem and second similar problem.
4. The knowledge base question-answering method according to claim 2, wherein the fine tuning of the text vectorization model using the historical dialogue set, the question-answering knowledge base, and the similar problem set to obtain the pre-trained vector coding model includes:
taking the similar problem set as a supervised training data set, and taking the historical dialogue set and the question-answering knowledge base as an unsupervised training data set;
calculating a first loss using the supervised training data set and the text vectorization model;
calculating a second loss using the unsupervised training data set and the text vectorization model;
and fine tuning the text vectorization model based on the first loss and the second loss to obtain the vector coding model.
5. The knowledge base question-answering method according to claim 1, wherein before generating a query answer of the query term using a pre-trained large language model, further comprising:
utilizing a preset fine tuning instruction template to adjust the format of the question-answer data in the question-answer knowledge base to obtain a fine tuning data set; the fine tuning instruction template is a standard format template for adjusting the question-answer data format;
and performing fine tuning on a preset language model based on the fine tuning data set to obtain the pre-trained large language model.
6. The knowledge base question-answering method according to claim 5, wherein the performing fine-tuning on a preset language model based on the fine-tuning data set comprises:
freezing a portion of the parameters in the language model;
calculating a third loss using the frozen language model and the fine tuning data set;
and adjusting unfrozen parameters in the language model based on the third loss.
7. The knowledge base question-answering method according to any one of claims 1-6, wherein retrieving a plurality of similar questions of the query question and answers corresponding to the similar questions from a question-answering knowledge base using a pre-trained vector coding model comprises:
Carrying out vectorization processing on the query problem by using the vector coding model to obtain a query vector;
and obtaining a plurality of similar questions of the query questions and answers corresponding to the similar questions from the question-answering knowledge base according to the matched vector data by utilizing the vector data in the query vector matching vector database, wherein the vector data in the vector database is obtained by carrying out vectorization processing on the questions in the question-answering knowledge base through the vector coding model.
8. The knowledge base question-answering method according to any one of claims 1-6, wherein said constructing a query term from said query question, said similar question, answers to said similar question, comprises:
filtering abnormal problems in the similar problems according to the query problems to obtain filtering problems;
and under the condition that the filtering questions comprise at least one similar question, constructing the query prompt words according to the query questions, the filtering questions and answers of the filtering questions.
9. An electronic device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the method of any one of claims 1 to 8 when the computer program is executed.
10. A computer readable storage medium storing a computer program, characterized in that the computer program when executed by a processor implements the method according to any one of claims 1 to 8.
CN202311587827.2A 2023-11-27 2023-11-27 Knowledge base question-answering method and device, electronic equipment and storage medium Pending CN117290492A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311587827.2A CN117290492A (en) 2023-11-27 2023-11-27 Knowledge base question-answering method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311587827.2A CN117290492A (en) 2023-11-27 2023-11-27 Knowledge base question-answering method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117290492A true CN117290492A (en) 2023-12-26

Family

ID=89244841

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311587827.2A Pending CN117290492A (en) 2023-11-27 2023-11-27 Knowledge base question-answering method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117290492A (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117573848A (en) * 2024-01-16 2024-02-20 北京数慧时空信息技术有限公司 Dialogue method, dialogue device, electronic equipment and medium
CN117573857A (en) * 2024-01-16 2024-02-20 北京凌云雀科技有限公司 Intelligent document implementation method, device equipment and medium based on large model
CN117688163A (en) * 2024-01-29 2024-03-12 杭州有赞科技有限公司 Online intelligent question-answering method and device based on instruction fine tuning and retrieval enhancement generation
CN117708307A (en) * 2024-02-06 2024-03-15 西北工业大学 Method and device for fusing micro-tuning and Adapter of large language model
CN117725186A (en) * 2024-02-08 2024-03-19 北京健康有益科技有限公司 Method and device for generating dialogue sample of specific disease diet scheme
CN117743559A (en) * 2024-02-20 2024-03-22 厦门国际银行股份有限公司 Multi-round dialogue processing method, device and equipment based on RAG
CN117952121A (en) * 2024-03-27 2024-04-30 北方健康医疗大数据科技有限公司 Medical text quality assessment method, system, electronic equipment and medium
CN117992599A (en) * 2024-04-07 2024-05-07 腾讯科技(深圳)有限公司 Question and answer method and device based on large language model and computer equipment
CN118093841A (en) * 2024-04-25 2024-05-28 浙江大学 Model training method and question-answering method for question-answering system
CN118095292A (en) * 2024-04-19 2024-05-28 贵州省通信产业服务有限公司 Text generation method and system based on prompt engineering and fine tuning technology
CN118132735A (en) * 2024-05-07 2024-06-04 支付宝(杭州)信息技术有限公司 Medical rule base generation method and device
CN118211183A (en) * 2024-05-21 2024-06-18 浪潮通用软件有限公司 Cross-space-time data continuous fusion method, device and medium based on large model
CN118277513A (en) * 2024-06-04 2024-07-02 深圳依时货拉拉科技有限公司 Method for processing dispute event of freight platform, storage medium and computer equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021217935A1 (en) * 2020-04-29 2021-11-04 深圳壹账通智能科技有限公司 Method for training question generation model, question generation method, and related device
CN114416927A (en) * 2022-01-24 2022-04-29 招商银行股份有限公司 Intelligent question and answer method, device, equipment and storage medium
CN116775846A (en) * 2023-07-28 2023-09-19 北京宝兰德软件股份有限公司 Domain knowledge question and answer method, system, equipment and medium
CN117093698A (en) * 2023-10-19 2023-11-21 四川蜀天信息技术有限公司 Knowledge base-based dialogue generation method and device, electronic equipment and storage medium

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021217935A1 (en) * 2020-04-29 2021-11-04 深圳壹账通智能科技有限公司 Method for training question generation model, question generation method, and related device
CN114416927A (en) * 2022-01-24 2022-04-29 招商银行股份有限公司 Intelligent question and answer method, device, equipment and storage medium
CN116775846A (en) * 2023-07-28 2023-09-19 北京宝兰德软件股份有限公司 Domain knowledge question and answer method, system, equipment and medium
CN117093698A (en) * 2023-10-19 2023-11-21 四川蜀天信息技术有限公司 Knowledge base-based dialogue generation method and device, electronic equipment and storage medium

Cited By (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117573857A (en) * 2024-01-16 2024-02-20 北京凌云雀科技有限公司 Intelligent document implementation method, device equipment and medium based on large model
CN117573848B (en) * 2024-01-16 2024-04-02 北京数慧时空信息技术有限公司 Dialogue method, dialogue device, electronic equipment and medium
CN117573848A (en) * 2024-01-16 2024-02-20 北京数慧时空信息技术有限公司 Dialogue method, dialogue device, electronic equipment and medium
CN117688163A (en) * 2024-01-29 2024-03-12 杭州有赞科技有限公司 Online intelligent question-answering method and device based on instruction fine tuning and retrieval enhancement generation
CN117688163B (en) * 2024-01-29 2024-04-23 杭州有赞科技有限公司 Online intelligent question-answering method and device based on instruction fine tuning and retrieval enhancement generation
CN117708307B (en) * 2024-02-06 2024-05-14 西北工业大学 Method and device for fusing micro-tuning and Adapter of large language model
CN117708307A (en) * 2024-02-06 2024-03-15 西北工业大学 Method and device for fusing micro-tuning and Adapter of large language model
CN117725186A (en) * 2024-02-08 2024-03-19 北京健康有益科技有限公司 Method and device for generating dialogue sample of specific disease diet scheme
CN117743559A (en) * 2024-02-20 2024-03-22 厦门国际银行股份有限公司 Multi-round dialogue processing method, device and equipment based on RAG
CN117743559B (en) * 2024-02-20 2024-06-04 厦门国际银行股份有限公司 Multi-round dialogue processing method, device and equipment based on RAG
CN117952121A (en) * 2024-03-27 2024-04-30 北方健康医疗大数据科技有限公司 Medical text quality assessment method, system, electronic equipment and medium
CN117992599A (en) * 2024-04-07 2024-05-07 腾讯科技(深圳)有限公司 Question and answer method and device based on large language model and computer equipment
CN117992599B (en) * 2024-04-07 2024-07-09 腾讯科技(深圳)有限公司 Question and answer method and device based on large language model and computer equipment
CN118095292A (en) * 2024-04-19 2024-05-28 贵州省通信产业服务有限公司 Text generation method and system based on prompt engineering and fine tuning technology
CN118093841A (en) * 2024-04-25 2024-05-28 浙江大学 Model training method and question-answering method for question-answering system
CN118132735A (en) * 2024-05-07 2024-06-04 支付宝(杭州)信息技术有限公司 Medical rule base generation method and device
CN118211183A (en) * 2024-05-21 2024-06-18 浪潮通用软件有限公司 Cross-space-time data continuous fusion method, device and medium based on large model
CN118277513A (en) * 2024-06-04 2024-07-02 深圳依时货拉拉科技有限公司 Method for processing dispute event of freight platform, storage medium and computer equipment

Similar Documents

Publication Publication Date Title
CN117290492A (en) Knowledge base question-answering method and device, electronic equipment and storage medium
CN117033608B (en) Knowledge graph generation type question-answering method and system based on large language model
CN109918560B (en) Question and answer method and device based on search engine
CN109815487B (en) Text quality inspection method, electronic device, computer equipment and storage medium
CN112016313B (en) Spoken language element recognition method and device and warning analysis system
CN112036184A (en) Entity identification method, device, computer device and storage medium based on BilSTM network model and CRF model
CN117688163B (en) Online intelligent question-answering method and device based on instruction fine tuning and retrieval enhancement generation
CN116662518A (en) Question answering method, question answering device, electronic equipment and readable storage medium
CN114218945A (en) Entity identification method, device, server and storage medium
CN117520503A (en) Financial customer service dialogue generation method, device, equipment and medium based on LLM model
CN116150306A (en) Training method of question-answering robot, question-answering method and device
CN115374259A (en) Question and answer data mining method and device and electronic equipment
CN117609444B (en) Searching question-answering method based on large model
CN117056575B (en) Method for data acquisition based on intelligent book recommendation system
CN112487813B (en) Named entity recognition method and system, electronic equipment and storage medium
CN116049376B (en) Method, device and system for retrieving and replying information and creating knowledge
CN113468323A (en) Dispute focus category and similarity judgment method, dispute focus category and similarity judgment system, dispute focus category and similarity judgment device and dispute focus category and similarity judgment recommendation method
CN116186232A (en) Standard knowledge intelligent question-answering implementation method, device, equipment and medium
CN111858860A (en) Search information processing method and system, server, and computer readable medium
CN111324722B (en) Method and system for training word weight model
CN111400413B (en) Method and system for determining category of knowledge points in knowledge base
CN114239606A (en) Information processing method, device and equipment and computer storage medium
CN114510561A (en) Answer selection method, device, equipment and storage medium
CN113836296A (en) Method, device, equipment and storage medium for generating Buddhist question-answer abstract
CN113449094A (en) Corpus obtaining method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination