CN117669717A - Knowledge enhancement-based large model question-answering method, device, equipment and medium - Google Patents
Knowledge enhancement-based large model question-answering method, device, equipment and medium Download PDFInfo
- Publication number
- CN117669717A CN117669717A CN202311648000.8A CN202311648000A CN117669717A CN 117669717 A CN117669717 A CN 117669717A CN 202311648000 A CN202311648000 A CN 202311648000A CN 117669717 A CN117669717 A CN 117669717A
- Authority
- CN
- China
- Prior art keywords
- information
- preset
- question
- knowledge
- answered
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 38
- 238000000605 extraction Methods 0.000 claims abstract description 102
- 238000004590 computer program Methods 0.000 claims description 14
- 230000000875 corresponding effect Effects 0.000 description 78
- 238000004891 communication Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 238000013473 artificial intelligence Methods 0.000 description 3
- 238000011156 evaluation Methods 0.000 description 3
- 230000005540 biological transmission Effects 0.000 description 1
- 230000001276 controlling effect Effects 0.000 description 1
- 238000012937 correction Methods 0.000 description 1
- 230000002596 correlated effect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N5/00—Computing arrangements using knowledge-based models
- G06N5/02—Knowledge representation; Symbolic representation
- G06N5/022—Knowledge engineering; Knowledge acquisition
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F40/00—Handling natural language data
- G06F40/30—Semantic analysis
- G06F40/35—Discourse or dialogue representation
-
- Y—GENERAL 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
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE 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/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computational Linguistics (AREA)
- Physics & Mathematics (AREA)
- Artificial Intelligence (AREA)
- General Health & Medical Sciences (AREA)
- Audiology, Speech & Language Pathology (AREA)
- Health & Medical Sciences (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- Computing Systems (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The application discloses a knowledge enhancement-based large model question-answering method, a device, equipment and a medium, which relate to the technical field of computers and comprise the following steps: acquiring a to-be-answered question, and determining initial answer information corresponding to the to-be-answered question based on a preset dialogue large model; performing corresponding information extraction operation on the initial reply information based on a preset information extraction rule to obtain corresponding extracted reply information; searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions; and inputting the enhanced questions into the preset conversation large model to obtain target reply information corresponding to the questions to be answered.
Description
Technical Field
The invention relates to the technical field of computers, in particular to a knowledge-enhancement-based large model question-answering method, a device, equipment and a medium.
Background
Currently, the big model is pre-trained by means of autoregressive mode and predicted in the form of conditional probability, which causes the inherent model illusion problem of the big model, namely the problem that the output of the model has a certain probability of error, error and the like. In view of the above problems, the main solution is shown in fig. 1, in the implementation of this solution, the dependence on the inputted problems is very strongly correlated, and the effective relational terms in the problems are very few (because the user will not generally input too much prompt content). In this way, the content that results in the output of the AI (Artificial Intelligence ) dialogue large model is also referenced very little and evaluated according to a correlation algorithm (e.g., ALCE, automatic LLMs' Citation Evaluation, i.e., automatic LLM quotients evaluation, wherein LLMs are linear least mean-square (error), also known as linear least mean square), or human evaluation, and the quality is to be improved. Therefore, how to perform effective knowledge enhancement to improve the reliability of the large dialogue model is a current urgent problem to be solved.
Disclosure of Invention
In view of the above, the present invention aims to provide a knowledge-based enhanced large model question-answering method, apparatus, device and medium, which can effectively improve the reliability of a large dialogue model and the interpretability of answer information. The specific scheme is as follows:
in a first aspect, the present application provides a knowledge-based enhanced large model question-answering method, including:
acquiring a to-be-answered question, and determining initial answer information corresponding to the to-be-answered question based on a preset dialogue large model;
performing corresponding information extraction operation on the initial reply information based on a preset information extraction rule to obtain corresponding extracted reply information;
searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions;
and inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
Optionally, the performing, based on a preset information extraction rule, a corresponding information extraction operation on the initial reply information includes:
and respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to finish the corresponding information extraction operation.
Optionally, performing a corresponding information extraction operation on the initial reply information based on a preset information extraction rule includes:
and executing corresponding medical entity extraction operation and medical relation extraction operation on the initial reply information by using a preset information extraction model so as to complete corresponding information extraction operation.
Optionally, the combining the obtained search result with the question to be answered according to a preset information combining rule includes:
determining a search result corresponding to the extracted reply information;
and combining the search result with the questions to be answered in a prompt mode based on a preset programming statement.
Optionally, the determining the search result corresponding to the extracted reply information includes:
and determining the information of the corresponding number from all the retrieved information based on a preset value to obtain a retrieval result corresponding to the extracted reply information.
In a second aspect, the present application provides a knowledge-based enhanced large model question-answering apparatus, including:
the initial answer determining module is used for acquiring a to-be-answered question and determining initial answer information corresponding to the to-be-answered question based on a preset conversation big model;
the information extraction module is used for executing corresponding information extraction operation on the initial reply information based on a preset information extraction rule so as to obtain corresponding extracted reply information;
the knowledge enhancement module is used for searching the extracted reply information by utilizing a preset search system and a formatted preset external knowledge source, and combining the obtained search result with the questions to be answered according to a preset information combination rule so as to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions;
and the target answer acquisition module is used for inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
Optionally, the information extraction module includes:
and the information extraction unit is used for respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to complete the corresponding information extraction operation.
Optionally, the knowledge enhancement module includes:
a retrieval result determination sub-module for determining a retrieval result corresponding to the extracted reply information;
and the question combining unit is used for combining the search result with the questions to be answered in a prompt mode based on a preset programming statement.
In a third aspect, the present application provides an electronic device, including:
a memory for storing a computer program;
and a processor for executing the computer program to implement the steps of the knowledge-based enhanced large model question-answering method.
In a fourth aspect, the present application provides a computer readable storage medium storing a computer program which, when executed by a processor, implements the steps of the knowledge-based enhanced large model question-answering method described above.
In the application, firstly, a to-be-answered question is obtained, and initial answer information corresponding to the to-be-answered question is determined based on a preset dialogue large model; then, corresponding information extraction operation is carried out on the initial reply information based on a preset information extraction rule so as to obtain corresponding extracted reply information; then searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions; and then inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered. The method comprises the steps of firstly obtaining initial reply information, then extracting and searching the initial reply information, then combining the initial reply information with a question to be answered to obtain an enhanced question, and inputting the enhanced question into a preset conversation large model to obtain final target reply information. Therefore, the reliability of the large dialogue model and the interpretability of the reply information are effectively improved, and the user experience is further improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings that are required to be used in the embodiments or the description of the prior art will be briefly described below, and it is obvious that the drawings in the following description are only embodiments of the present invention, and that other drawings can be obtained according to the provided drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic flow chart of a specific knowledge-based enhanced large model question-answering method provided in the present application;
FIG. 2 is a flow chart of a knowledge-based enhanced large model question-answering method provided by the present application;
FIG. 3 is a flowchart of a specific knowledge-based enhanced large model question-answering method provided in the present application;
FIG. 4 is a schematic representation of a reply information reference formal representation provided herein;
FIG. 5 is a schematic structural diagram of a knowledge-based enhanced large model question-answering device provided by the present application;
fig. 6 is a block diagram of an electronic device provided in the present application.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
The main solution at present is shown in fig. 1, in the implementation of this solution, the dependence on the inputted questions is very strongly relevant, and the effective relational terms in the questions are very few (because the user will not typically input too much prompt content). In this way, the content that leads to the output of the AI conversation large model is also cited very little and evaluated according to a correlation algorithm or manually, and the quality is to be improved. Therefore, how to perform effective knowledge enhancement to improve the reliability of the large dialogue model is a current urgent problem to be solved. Therefore, the application provides a knowledge-enhancement-based large model question-answer scheme which can effectively improve the reliability of a large dialogue model and the interpretability of answer information.
Referring to fig. 2, the embodiment of the invention discloses a knowledge enhancement-based large model question-answering method, which comprises the following steps:
and S11, acquiring a to-be-answered question, and determining initial answer information corresponding to the to-be-answered question based on a preset dialogue large model.
In this embodiment, after the question to be answered input by the user is obtained as shown in fig. 3, the question to be answered Su Songhu needs to be input into a preset dialogue large model to obtain corresponding initial answer information, that is, the machine answer 1 in fig. 3.
Step S12, corresponding information extraction operation is carried out on the initial reply information based on preset information extraction rules so as to obtain corresponding extracted reply information.
In this embodiment, the performing, based on a preset information extraction rule, a corresponding information extraction operation on the initial reply information may specifically include: and respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to finish the corresponding information extraction operation. The features obtained after the semantic extraction operation are executed can well explain the semantic content expressed by the initial reply information, and the features obtained after the keyword extraction operation and the theme feature extraction operation are executed can be further supplemented so as to add more text feature information to comprehensively analyze the specific content of the initial reply information. In this way, by executing the above operations, the text extraction feature can be effectively enhanced, and further, the correlation of data during subsequent retrieval is improved, and particularly in the medical and medical related fields, the information with strong correlation cannot be effectively retrieved by using a single feature.
Further, performing a corresponding information extraction operation on the initial reply information based on a preset information extraction rule may specifically include: and executing corresponding medical entity extraction operation and medical relation extraction operation on the initial reply information by using a preset information extraction model so as to complete corresponding information extraction operation. In this embodiment, by executing the corresponding medical entity extraction operation and the medical relationship extraction operation, the relationship between various entities in the medical knowledge can be greatly improved, so that the model answer can be effectively avoided from irrelevant content and/or incorrect content.
And step S13, searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combination rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions.
In this embodiment, referring to fig. 3, the combining, according to a preset information combining rule, the obtained search result with the question to be answered may specifically include: determining a search result corresponding to the extracted reply information; and combining the retrieval result with the questions to be answered in a prompt mode based on a preset programming statement. The determining the search result corresponding to the extracted reply information may specifically include: and determining the information of the corresponding number from all the retrieved information based on a preset value to obtain a retrieval result corresponding to the extracted reply information. The preset value (i.e., k in fig. 3) may be configured in advance based on actual requirements. In this embodiment, after obtaining the corresponding post-extraction reply information, the post-extraction reply information is input into a preset retrieval system, and the preset retrieval system will perform retrieval in combination with a formatted preset external knowledge source. The preset external knowledge source may specifically be a relevant local reliable database. In addition, for the searched content output by the preset search system, a plurality of pieces of related information are specifically needed to be simplified, the related ordering is performed, and then the Top-k information in the searched content is determined as the search result. In this way, through the above operation, not only the problem that the to-be-answered question provided by the user is too simple for the professional knowledge such as medical treatment, but also the problem that the model is operated in a low probability mode due to the fact that the text content in the to-be-answered question provided by the user is too small, so that the result output by the model is caused to be quite large, can be solved, and the correction of the error content can be performed based on the preset external knowledge source.
It should be understood that, in the process of combining the search result with the question to be answered in a prompt manner based on a preset programming statement, the instruction [ instruction ] may be specifically designed by please refer to a natural segment [ { [1] calibrated according to: content 1, [2]: content 2 …, [ N ]: content N ] and combining given context information context, and answering the following questions in the form of references [1] [2], so as to enable the preset conversation big model to be completed, and simultaneously obtaining final answer information.
And S14, inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
In this embodiment, after the enhanced question is obtained, the enhanced question needs to be input into the preset dialogue large model to obtain the target answer information corresponding to the question to be answered. And, in a specific embodiment, the manner that is easy to understand and is shown in fig. 4 can be finally output based on the instruction shown in step S13, where q is query, that is, a problem; r is reply, i.e. reply content; s= { S 1 ,S 2 ,S 3 …S n -a set of claims obtained by splitting said answer content; for each claim S in the claim set i All construct a set of possible external knowledge references C i ={C i,1 ,C i,2 ,C i,3 …C i,k 'K' means for statement S i Number of references in terms of); for each C i,j There are two kinds of information, one is u i,j Representing reference addresses, labels, or the like, p i,j Specific references are shown.
It can be seen that, in the embodiment of the present application, a question to be answered is first obtained, and initial answer information corresponding to the question to be answered is determined based on a preset dialogue large model; then, corresponding information extraction operation is carried out on the initial reply information based on a preset information extraction rule so as to obtain corresponding extracted reply information; then searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions; and then inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered. The method comprises the steps of firstly obtaining initial reply information, then extracting and searching the initial reply information, then combining the initial reply information with a question to be answered to obtain an enhanced question, and inputting the enhanced question into a preset conversation large model to obtain final target reply information. Therefore, the reliability of the large dialogue model and the interpretability of the reply information are effectively improved, and the user experience is further improved.
Referring to fig. 5, the embodiment of the application further correspondingly discloses a knowledge enhancement-based large model question-answering device, which comprises:
an initial answer determining module 11, configured to obtain a question to be answered, and determine initial answer information corresponding to the question to be answered based on a preset dialogue large model;
an information extraction module 12, configured to perform a corresponding information extraction operation on the initial reply information based on a preset information extraction rule, so as to obtain corresponding extracted reply information;
the knowledge enhancement module 13 is configured to search the extracted reply information by using a preset search system and a formatted preset external knowledge source, and combine the obtained search result with the question to be answered according to a preset information combination rule, so as to complete a corresponding knowledge enhancement operation and obtain a corresponding enhanced question;
and the target answer acquisition module 14 is used for inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
The more specific working process of each module may refer to the corresponding content disclosed in the foregoing embodiment, and will not be described herein.
Therefore, in the application, firstly, a to-be-answered question is obtained, and initial answer information corresponding to the to-be-answered question is determined based on a preset dialogue large model; then, corresponding information extraction operation is carried out on the initial reply information based on a preset information extraction rule so as to obtain corresponding extracted reply information; then searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions; and then inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered. The method comprises the steps of firstly obtaining initial reply information, then extracting and searching the initial reply information, then combining the initial reply information with a question to be answered to obtain an enhanced question, and inputting the enhanced question into a preset conversation large model to obtain final target reply information. Therefore, the reliability of the large dialogue model and the interpretability of the reply information are effectively improved, and the user experience is further improved.
In some specific embodiments, the information extraction module 12 may specifically include:
and the information extraction unit is used for respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to complete the corresponding information extraction operation.
In some specific embodiments, the knowledge-based enhanced large model question-answering device may specifically include:
and the information extraction unit is used for executing corresponding medical entity extraction operation and medical relation extraction operation on the initial reply information by using a preset information extraction model so as to complete corresponding information extraction operation.
In some specific embodiments, the knowledge enhancement module 13 may specifically include:
a retrieval result determination sub-module for determining a retrieval result corresponding to the extracted reply information;
and the question combining unit is used for combining the search result with the questions to be answered in a prompt mode based on a preset programming statement.
In some specific embodiments, the search result determining submodule may specifically include:
and a result determining unit for determining the information of the corresponding number from all the retrieved information based on the preset value to obtain the retrieval result corresponding to the extracted reply information.
Further, the embodiment of the present application further discloses an electronic device, and fig. 6 is a structural diagram of the electronic device 20 according to an exemplary embodiment, where the content of the drawing is not to be considered as any limitation on the scope of use of the present application.
Fig. 6 is a schematic structural diagram of an electronic device 20 according to an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input output interface 25, and a communication bus 26. Wherein the memory 22 is used for storing a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the knowledge-based enhanced large model question-answering method disclosed in any one of the foregoing embodiments. In addition, the electronic device 20 in the present embodiment may be specifically an electronic computer.
In this embodiment, the power supply 23 is configured to provide an operating voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and an external device, and the communication protocol to be followed is any communication protocol applicable to the technical solution of the present application, which is not specifically limited herein; the input/output interface 25 is used for acquiring external input data or outputting external output data, and the specific interface type thereof may be selected according to the specific application requirement, which is not limited herein.
The memory 22 may be a carrier for storing resources, such as a read-only memory, a random access memory, a magnetic disk, or an optical disk, and the resources stored thereon may include an operating system 221, a computer program 222, and the like, and the storage may be temporary storage or permanent storage.
The operating system 221 is used for managing and controlling various hardware devices on the electronic device 20 and computer programs 222, which may be Windows Server, netware, unix, linux, etc. The computer program 222 may further comprise a computer program that can be used to perform other specific tasks in addition to the computer program that can be used to perform the knowledge-based enhanced large model question-answering method performed by the electronic device 20 as disclosed in any of the previous embodiments.
Further, the application also discloses a computer readable storage medium for storing a computer program; wherein the computer program, when executed by the processor, implements the knowledge-based enhanced large model question-answering method of the foregoing disclosure. For specific steps of the method, reference may be made to the corresponding contents disclosed in the foregoing embodiments, and no further description is given here.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described in a different point from other embodiments, so that the same or similar parts between the embodiments are referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant points refer to the description of the method section.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative elements and steps are described above generally in terms of functionality in order to clearly illustrate the interchangeability of hardware and software. 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.
The steps of a method or algorithm described in connection with the embodiments disclosed herein may be embodied directly in hardware, in a software module executed by a processor, or in a combination of the two. The software modules may be disposed in Random Access Memory (RAM), memory, read Only Memory (ROM), electrically programmable ROM, electrically erasable programmable ROM, registers, hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The foregoing has outlined the detailed description of the preferred embodiment of the present application, and the detailed description of the principles and embodiments of the present application has been provided herein by way of example only to facilitate the understanding of the method and core concepts of the present application; meanwhile, as those skilled in the art will have modifications in the specific embodiments and application scope in accordance with the ideas of the present application, the present description should not be construed as limiting the present application in view of the above.
Claims (10)
1. A knowledge enhancement based large model question-answering method, comprising:
acquiring a to-be-answered question, and determining initial answer information corresponding to the to-be-answered question based on a preset dialogue large model;
performing corresponding information extraction operation on the initial reply information based on a preset information extraction rule to obtain corresponding extracted reply information;
searching the extracted reply information by using a preset searching system and a formatted preset external knowledge source, and combining the obtained searching result with the questions to be answered according to a preset information combining rule to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions;
and inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
2. The knowledge-based enhanced large model question-answering method according to claim 1, wherein the performing a corresponding information extraction operation on the initial answer information based on a preset information extraction rule includes:
and respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to finish the corresponding information extraction operation.
3. The knowledge-based enhanced large model question-answering method according to claim 2, wherein performing a corresponding information extraction operation on the initial answer information based on a preset information extraction rule, comprises:
and executing corresponding medical entity extraction operation and medical relation extraction operation on the initial reply information by using a preset information extraction model so as to complete corresponding information extraction operation.
4. The knowledge-based enhanced large model question-answering method according to claim 1, wherein the combining the obtained search result with the question to be answered according to a preset information combining rule includes:
determining a search result corresponding to the extracted reply information;
and combining the search result with the questions to be answered in a prompt mode based on a preset programming statement.
5. The knowledge-based enhanced large model question-answering method according to claim 4, wherein the determining a search result corresponding to the extracted answer information includes:
and determining the information of the corresponding number from all the retrieved information based on a preset value to obtain a retrieval result corresponding to the extracted reply information.
6. A knowledge enhancement based large model question-answering apparatus, comprising:
the initial answer determining module is used for acquiring a to-be-answered question and determining initial answer information corresponding to the to-be-answered question based on a preset conversation big model;
the information extraction module is used for executing corresponding information extraction operation on the initial reply information based on a preset information extraction rule so as to obtain corresponding extracted reply information;
the knowledge enhancement module is used for searching the extracted reply information by utilizing a preset search system and a formatted preset external knowledge source, and combining the obtained search result with the questions to be answered according to a preset information combination rule so as to complete corresponding knowledge enhancement operation and obtain corresponding enhanced questions;
and the target answer acquisition module is used for inputting the enhanced questions into the preset dialogue large model to obtain target answer information corresponding to the questions to be answered.
7. The knowledge-based enhanced large model question-answering apparatus according to claim 6, wherein the information extraction module includes:
and the information extraction unit is used for respectively executing corresponding information extraction operation, semantic extraction operation, keyword extraction operation and theme feature extraction operation on the initial reply information based on a preset information extraction rule so as to complete the corresponding information extraction operation.
8. The knowledge-based big model question-answering apparatus according to claim 6, wherein the knowledge enhancement module includes:
a retrieval result determination sub-module for determining a retrieval result corresponding to the extracted reply information;
and the question combining unit is used for combining the search result with the questions to be answered in a prompt mode based on a preset programming statement.
9. An electronic device, comprising:
a memory for storing a computer program;
a processor for executing the computer program to implement the knowledge-based enhanced large model question-answering method according to any one of claims 1 to 5.
10. A computer readable storage medium for storing a computer program which when executed by a processor implements the knowledge-based enhanced large model question-answering method according to any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311648000.8A CN117669717A (en) | 2023-12-04 | 2023-12-04 | Knowledge enhancement-based large model question-answering method, device, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202311648000.8A CN117669717A (en) | 2023-12-04 | 2023-12-04 | Knowledge enhancement-based large model question-answering method, device, equipment and medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN117669717A true CN117669717A (en) | 2024-03-08 |
Family
ID=90065604
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202311648000.8A Pending CN117669717A (en) | 2023-12-04 | 2023-12-04 | Knowledge enhancement-based large model question-answering method, device, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117669717A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117874208A (en) * | 2024-03-11 | 2024-04-12 | 羚羊工业互联网股份有限公司 | Method for realizing large model memory sharing, knowledge question-answering method and related equipment thereof |
-
2023
- 2023-12-04 CN CN202311648000.8A patent/CN117669717A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117874208A (en) * | 2024-03-11 | 2024-04-12 | 羚羊工业互联网股份有限公司 | Method for realizing large model memory sharing, knowledge question-answering method and related equipment thereof |
CN117874208B (en) * | 2024-03-11 | 2024-06-07 | 羚羊工业互联网股份有限公司 | Method for realizing large model memory sharing, knowledge question-answering method and related equipment thereof |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN117669717A (en) | Knowledge enhancement-based large model question-answering method, device, equipment and medium | |
CN111159415A (en) | Sequence labeling method and system, and event element extraction method and system | |
CN110929094A (en) | Video title processing method and device | |
CN111191450A (en) | Corpus cleaning method, corpus entry device and computer-readable storage medium | |
CN116521893A (en) | Control method and control device of intelligent dialogue system and electronic equipment | |
CN116737908A (en) | Knowledge question-answering method, device, equipment and storage medium | |
CN112667796B (en) | Dialogue reply method and device, electronic equipment and readable storage medium | |
CN116521841B (en) | Method, device, equipment and medium for generating reply information | |
CN115630146A (en) | Method and device for automatically generating demand document based on human-computer interaction and storage medium | |
CN115827838A (en) | Dialog generation method and system based on story continuous writing and dynamic knowledge base | |
CN109033082B (en) | Learning training method and device of semantic model and computer readable storage medium | |
CN112966076A (en) | Intelligent question and answer generating method and device, computer equipment and storage medium | |
CN115905490A (en) | Man-machine interaction dialogue method, device and equipment | |
CN115409042A (en) | Robot question-answering method and device based on thinking guide diagram | |
CN115114404A (en) | Question and answer method and device for intelligent customer service, electronic equipment and computer storage medium | |
CN112860863A (en) | Machine reading understanding method and device | |
CN117668620A (en) | Method and device for identifying dialogue by using out-of-domain intention | |
CN118093796B (en) | Multi-round dialogue method, device, equipment and storage medium | |
CN110364152B (en) | Voice interaction method, device and computer-readable storage medium | |
CN113468306B (en) | Voice dialogue method and device, electronic equipment and storage medium | |
CN118093778A (en) | Intelligent response method and device for live comments, computer equipment and storage medium | |
CN116340495A (en) | Question-answering task processing method and device, storage medium and computer equipment | |
CN117763122A (en) | Knowledge question and answer method, device and equipment | |
CN117421415A (en) | Data processing method, device, electronic equipment and storage medium | |
CN116955556A (en) | Dialogue response processing method, device, 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 |