CN117493524A - Intelligent question-answering control method, device, equipment and storage medium - Google Patents

Intelligent question-answering control method, device, equipment and storage medium Download PDF

Info

Publication number
CN117493524A
CN117493524A CN202311585908.9A CN202311585908A CN117493524A CN 117493524 A CN117493524 A CN 117493524A CN 202311585908 A CN202311585908 A CN 202311585908A CN 117493524 A CN117493524 A CN 117493524A
Authority
CN
China
Prior art keywords
knowledge
question
data
classification
content
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
CN202311585908.9A
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.)
China Mobile Communications Group Co Ltd
China Mobile Information Technology Co Ltd
Original Assignee
China Mobile Communications Group Co Ltd
China Mobile Information 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 China Mobile Communications Group Co Ltd, China Mobile Information Technology Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN202311585908.9A priority Critical patent/CN117493524A/en
Publication of CN117493524A publication Critical patent/CN117493524A/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/35Clustering; Classification
    • G06F16/353Clustering; Classification into predefined classes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/213Feature extraction, e.g. by transforming the feature space; Summarisation; Mappings, e.g. subspace methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/04Architecture, e.g. interconnection topology
    • G06N3/044Recurrent networks, e.g. Hopfield networks
    • G06N3/0442Recurrent networks, e.g. Hopfield networks characterised by memory or gating, e.g. long short-term memory [LSTM] or gated recurrent units [GRU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N5/00Computing arrangements using knowledge-based models
    • G06N5/02Knowledge representation; Symbolic representation
    • G06N5/022Knowledge engineering; Knowledge acquisition
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N5/00Computing arrangements using knowledge-based models
    • G06N5/04Inference or reasoning models

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • Evolutionary Computation (AREA)
  • Mathematical Physics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Computational Linguistics (AREA)
  • Software Systems (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Computing Systems (AREA)
  • Databases & Information Systems (AREA)
  • Human Computer Interaction (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Biophysics (AREA)
  • General Health & Medical Sciences (AREA)
  • Molecular Biology (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to the technical field of artificial intelligence, and discloses an intelligent question-answering control method, device, equipment and storage medium, wherein the method comprises the following steps: carrying out knowledge classification on the current knowledge data through a knowledge classification model to obtain a customer service classification knowledge base; determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base; performing problem reconstruction on the problem content according to the similarity; reasoning the reconstructed question content to obtain an answer corresponding to the question content; through the method, after the customer service classification knowledge base is classified by knowledge of the knowledge classification model, the similarity of the problem content and the knowledge data is determined, then the problem is reconstructed according to the similarity, and the answer corresponding to the problem content is inferred based on the reconstructed problem content, so that the question and answer quality and efficiency of intelligent customer service can be effectively improved, the experience of a user is improved, and the format of the input knowledge data is not required to be considered.

Description

Intelligent question-answering control method, device, equipment and storage medium
Technical Field
The invention relates to the technical field of artificial intelligence, in particular to an intelligent question-answering control method, an intelligent question-answering control device, intelligent question-answering equipment and a storage medium.
Background
The new generation communication technology represented by 5G and artificial intelligence are mutually fused and promoted, which is the basis for constructing future digital business and ecological systems, and the fusion and promotion are perfectly embodied in the aspect of intelligent customer service, for example, the introduction of artificial intelligence enables various performance indexes of operator service to be greatly improved, especially enterprise operation, cost and customer satisfaction, at present, a commonly used question-answering system of intelligent customer service is realized by using a deep learning network model constructed by historical question-answering data, or key information of a question is extracted by using a knowledge graph, and then corresponding answers are matched in an enterprise knowledge base, but the knowledge graph mode is greatly limited in constructing the knowledge base, and the semantic understanding capability is limited for more complex example relations, and likewise, the language understanding capability of the knowledge-question-answering system trained by using a large amount of labeled question-answering data is limited, so that the quality and efficiency of intelligent question-answering are finally lower.
The foregoing is provided merely for the purpose of facilitating understanding of the technical solutions of the present invention and is not intended to represent an admission that the foregoing is prior art.
Disclosure of Invention
The invention mainly aims to provide an intelligent question-answering control method, device, equipment and storage medium, and aims to solve the technical problem that the quality and efficiency of intelligent question-answering are low in the prior art.
In order to achieve the above purpose, the present invention provides an intelligent question-answering control method, which includes the following steps:
carrying out knowledge classification on the current knowledge data through a knowledge classification model to obtain a customer service classification knowledge base;
determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base;
performing problem reconstruction on the problem content according to the similarity;
and reasoning the reconstructed question content to obtain an answer corresponding to the question content.
Optionally, before the knowledge classification is performed on the current knowledge data through the knowledge classification model to obtain the customer service classification knowledge base, the method further includes:
collecting various knowledge text data according to the knowledge question-answering application field;
preprocessing the various knowledge text data, and distributing target type labels for the preprocessed various knowledge text data;
converting various knowledge text data after label allocation through a text vectorization model to obtain a current knowledge vector;
extracting features of the current knowledge vector through a character feature extraction model to obtain a knowledge feature vector;
and inputting the knowledge feature vector into a text classification network constructed based on the GRU structure and the Softmax layer, and constructing a knowledge classification model.
Optionally, the performing knowledge classification on the current knowledge data through the knowledge classification model to obtain a customer service classification knowledge base includes:
converting the current knowledge data through a text vectorization model to obtain an initial knowledge vector;
extracting features of the initial knowledge vector through a character feature extraction model to obtain a target knowledge feature vector;
carrying out knowledge classification on the target knowledge feature vector through a knowledge classification model to obtain various knowledge feature vectors;
generating each knowledge tuple according to the knowledge feature vectors and knowledge data corresponding to the knowledge feature vectors;
and generating a customer service classification knowledge base according to the knowledge tuples.
Optionally, the determining the similarity between the input problem content and each knowledge data in the corresponding category of the customer service classification knowledge base includes:
converting the input problem content through a text vectorization model to obtain a problem content vector;
extracting features of the problem content vectors through a character feature extraction model to obtain problem content feature vectors;
classifying the problem content feature vectors through a language classification model to obtain knowledge categories to which the problem content belongs;
determining a category corresponding to the knowledge category in the customer service classification knowledge base, and determining a feature vector of each knowledge data in the category;
respectively calculating cosine distances between the feature vectors of the problem content and the feature vectors of the knowledge data in the category;
and determining the similarity between the problem content and each knowledge data in the category according to the cosine distance.
Optionally, the performing the problem reconstruction on the problem content according to the similarity includes:
sequencing the knowledge data in the corresponding category of the customer service classification knowledge base according to the similarity;
based on the sorted knowledge data, taking the knowledge data corresponding to the maximum similarity as target knowledge data;
splicing the target knowledge data, and counting the word number length of the spliced knowledge data in real time;
stopping splicing when the word length is greater than a preset length threshold value, obtaining splicing knowledge data, and generating a target context basis according to the splicing knowledge data;
the target context basis is combined with the problem content.
Optionally, the combining the target context according to the content of the problem includes:
obtaining a context according to the filling position and the problem content filling position according to the target question structure;
and filling the target context into the context according to the filling position, and filling the problem content into the problem content filling position.
Optionally, the reasoning is performed on the reconstructed question content to obtain an answer corresponding to the question content, including:
inputting the reconstructed problem content into a target large language model;
and outputting an answer corresponding to the content of the question through the target large language model.
In addition, in order to achieve the above object, the present invention also provides an intelligent question-answering control device, which includes:
the classification module is used for carrying out knowledge classification on the current knowledge data through the knowledge classification model to obtain a customer service classification knowledge base;
the determining module is used for determining the similarity between the input problem content and each knowledge data in the corresponding category of the customer service classification knowledge base;
the reconstruction module is used for carrying out problem reconstruction on the problem content according to the similarity;
and the reasoning module is used for reasoning the reconstructed question content and obtaining an answer corresponding to the question content.
In addition, to achieve the above object, the present invention also proposes an intelligent question-answering control apparatus, comprising: the system comprises a memory, a processor and an intelligent question-answer control program stored on the memory and capable of running on the processor, wherein the intelligent question-answer control program is configured to realize the intelligent question-answer control method.
In addition, in order to achieve the above object, the present invention also proposes a storage medium having stored thereon an intelligent question-answer control program which, when executed by a processor, implements the intelligent question-answer control method as described above.
According to the intelligent question-answering control method provided by the invention, the knowledge classification is carried out on the current knowledge data through the knowledge classification model, so that a customer service classification knowledge base is obtained; determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base; performing problem reconstruction on the problem content according to the similarity; reasoning the reconstructed question content to obtain an answer corresponding to the question content; through the method, after the customer service classification knowledge base is classified by knowledge of the knowledge classification model, the similarity of the problem content and the knowledge data is determined, then the problem is reconstructed according to the similarity, and the answer corresponding to the problem content is inferred based on the reconstructed problem content, so that the question and answer quality and efficiency of intelligent customer service can be effectively improved, the experience of a user is improved, and the format of the input knowledge data is not required to be considered.
Drawings
FIG. 1 is a schematic diagram of the architecture of an intelligent question-answering control device of a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a flowchart of a first embodiment of the intelligent question-answering control method of the present invention;
FIG. 3 is a schematic diagram of a knowledge classification model constructed according to a first embodiment of the intelligent question-answering control method of the present invention;
FIG. 4 is a schematic diagram of an overall question-answering structure of a first embodiment of the intelligent question-answering control method of the present invention;
FIG. 5 is a flowchart of a second embodiment of the intelligent question-answering control method of the present invention;
fig. 6 is a schematic diagram of functional modules of a first embodiment of the intelligent question-answering control device according to the present invention.
The achievement of the objects, functional features and advantages of the present invention will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of an intelligent question-answering control device in a hardware running environment according to an embodiment of the present invention.
As shown in fig. 1, the intelligent question-answering control device may include: a processor 1001, such as a central processing unit (Central Processing Unit, CPU), a communication bus 1002, a user interface 1003, a network interface 1004, a memory 1005. Wherein the communication bus 1002 is used to enable connected communication between these components. The user interface 1003 may include a Display, an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may further include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a Wireless interface (e.g., a Wireless-Fidelity (Wi-Fi) interface). The Memory 1005 may be a high-speed random access Memory (Random Access Memory, RAM) or a stable nonvolatile Memory (NVM), such as a disk Memory. The memory 1005 may also optionally be a storage device separate from the processor 1001 described above.
It will be appreciated by those skilled in the art that the structure shown in fig. 1 is not limiting of the intelligent question and answer control device and may include more or fewer components than shown, or may combine certain components, or a different arrangement of components.
As shown in fig. 1, an operating system, a network communication module, a user interface module, and an intelligent question-answering control program may be included in the memory 1005, which is one type of storage medium.
In the intelligent question-answering control device shown in fig. 1, the network interface 1004 is mainly used for data communication with a workstation of a network integration platform; the user interface 1003 is mainly used for data interaction with a user; the processor 1001 and the memory 1005 in the intelligent question-answer control device of the present invention may be provided in the intelligent question-answer control device, and the intelligent question-answer control device invokes the intelligent question-answer control program stored in the memory 1005 through the processor 1001 and executes the intelligent question-answer control method provided by the embodiment of the present invention.
Based on the hardware structure, the embodiment of the intelligent question-answering control method is provided.
Referring to fig. 2, fig. 2 is a flowchart of a first embodiment of the intelligent question-answering control method according to the present invention.
In a first embodiment, the intelligent question-answering control method includes the steps of:
and S10, carrying out knowledge classification on the current knowledge data through a knowledge classification model to obtain a customer service classification knowledge base.
It should be noted that, the execution body of the embodiment is an intelligent question-answering control device, and may be other devices that can implement the same or similar functions, for example, an intelligent question-answering system, etc., which is not limited in this embodiment, and in this embodiment, an intelligent question-answering system is taken as an example for explanation.
It should be understood that the current knowledge data includes, but is not limited to, various text data such as policy regulations, business processes, office documents, history service records, service experience text contents, and the like, and is not limited to text organization formats of the current knowledge data, and the customer service classification knowledge base refers to a knowledge base for searching intelligent clients for answering, and the function of using the customer service classification knowledge base to classify the customer service classification knowledge base is to search the whole knowledge base in the subsequent question-answering process without searching the knowledge base, and only searching in the corresponding category of knowledge data, so that knowledge searching efficiency can be effectively improved.
Further, before step S10, the method further includes: collecting various knowledge text data according to the knowledge question-answering application field; preprocessing the various knowledge text data, and distributing target type labels for the preprocessed various knowledge text data; converting various knowledge text data after label allocation through a text vectorization model to obtain a current knowledge vector; extracting features of the current knowledge vector through a character feature extraction model to obtain a knowledge feature vector; and inputting the knowledge feature vector into a text classification network constructed based on the GRU structure and the Softmax layer, and constructing a knowledge classification model.
It should be noted that, referring to fig. 3, fig. 3 is a schematic structural diagram of building a knowledge classification model, where the structure includes 6 modules, which are a data acquisition module, a data processing module, a label distribution module, a feature extraction module, a model building module, and a model evaluation optimization module, respectively.
It may be understood that the knowledge question-answering application field refers to an application field for question-answering in this embodiment, for example, when the knowledge question-answering field is an operator field, the various knowledge text data includes but is not limited to text data of policy and system class, business process class and package activity class, then various knowledge text data is preprocessed, the preprocessing may be data cleaning to remove special characters, punctuation marks, stop words and the like in the various knowledge text data, in order to train a supervised knowledge classification model, a target type tag needs to be allocated to the preprocessed various knowledge text data, for example, the tag of knowledge data of policy and system class is 0, the tag of knowledge data of business process class is 1, the tag of knowledge data of package activity class is 2, then various knowledge text data after the tag allocation is converted into a numerical feature expression form understandable by a computer through a text vectorization model, that is, then a knowledge feature vector is extracted through a text feature extraction model, and the text feature extraction model may be a GPT-3 model.
It should be understood that after obtaining the knowledge feature vector, inputting the knowledge feature vector into a text classification network constructed based on the GRU structure and the Softmax layer, performing model training until an error converges, enabling the model to learn a mapping relation between a knowledge text and a target type label, and then evaluating performance of the trained knowledge classification model on new data by using a reserved test set, wherein common evaluation indexes comprise accuracy, recall rate, F1 score and the like, the classification performance of the knowledge classification model can be judged according to an evaluation result, and iteration and adjustment are not needed when the classification performance of the knowledge classification model meets preset requirements.
Further, step S10 includes: converting the current knowledge data through a text vectorization model to obtain an initial knowledge vector; extracting features of the initial knowledge vector through a character feature extraction model to obtain a target knowledge feature vector; carrying out knowledge classification on the target knowledge feature vector through a knowledge classification model to obtain various knowledge feature vectors; generating each knowledge tuple according to the knowledge feature vectors and knowledge data corresponding to the knowledge feature vectors; and generating a customer service classification knowledge base according to the knowledge tuples.
It should be understood that after the current knowledge data is obtained, the current knowledge data is converted by a text vectorization model and extracted by a text feature extraction model, then the target knowledge feature vector is subjected to knowledge classification by a knowledge classification model, for example, the output result is 0, which indicates that the target knowledge feature vector is a policy and system class, the output result is 1, which indicates that the target knowledge feature vector is a business process class, the output result is 2, which indicates that the target knowledge feature vector is a customer service daily knowledge class, and then each knowledge tuple is generated by knowledge data corresponding to each type of knowledge feature vector and each type of knowledge feature vector, for example, [ "knowledge feature vector", "knowledge data" ], and if the class is 0, the target knowledge feature vector is stored in a policy and system class data table to generate a customer service classification knowledge base.
And step S20, determining the similarity between the input problem content and each knowledge data in the corresponding category of the customer service classification knowledge base.
It can be understood that the similarity refers to the degree of similarity between the problem content and each knowledge data in the corresponding category of the customer service classification knowledge base, and the similarity can be indirectly obtained by calculating the feature vector of the problem content corresponding to the problem content and the feature vector of each knowledge data.
Further, step S20 includes: converting the input problem content through a text vectorization model to obtain a problem content vector; extracting features of the problem content vectors through a character feature extraction model to obtain problem content feature vectors; classifying the problem content feature vectors through a language classification model to obtain knowledge categories to which the problem content belongs; determining a category corresponding to the knowledge category in the customer service classification knowledge base, and determining a feature vector of each knowledge data in the category; respectively calculating cosine distances between the feature vectors of the problem content and the feature vectors of the knowledge data in the category; and determining the similarity between the problem content and each knowledge data in the category according to the cosine distance.
It should be understood that the cosine distance is inversely proportional to the similarity, that is, the smaller the cosine distance is, the higher the similarity is, the stronger the correlation between the problem content and the knowledge data in the category is, after the input problem content is obtained, the problem content feature vector is classified by the language classification model through converting by the text vectorization model and extracting features by the text feature extraction model, the language classification model is determined to classify the problem content feature vector, and then the cosine distance between the problem content feature vector and the feature vector of each knowledge data in the category is calculated respectively, specifically as follows:
wherein cos θ represents the cosine distance between the feature vector of the content of the problem and the feature vector of certain knowledge data in the category, X represents the feature vector of the content of the problem, Y represents the feature vector of certain knowledge data, and n represents the sequence number of the feature vector.
And step S30, carrying out problem reconstruction on the problem content according to the similarity.
It should be understood that problem reconstruction refers to combining the problem content with a target context basis determined using similarity, the format of the reconstructed problem content being a constrained question format.
And S40, reasoning the reconstructed problem content to obtain an answer corresponding to the problem content.
Further, step S40 includes: inputting the reconstructed problem content into a target large language model; and outputting an answer corresponding to the content of the question through the target large language model.
It should be understood that the target large language model may be a GPT-3 (General Pre-trained Transformer-3, third generation generic Pre-training transformer) model, which is one of the largest and most powerful language models from the past, has 1750 hundred million parameters, has excellent language understanding ability, inputs the reconstructed question contents into the target large language model after obtaining the reconstructed question contents, automatically generalizes and summarizes the reconstructed question contents by the target large language model, and outputs answers corresponding to the question contents.
It should be noted that, referring to fig. 4, fig. 4 is a schematic diagram of an overall question-answering structure, and the structure includes 8 modules, which are a question content input module, a feature extraction module, a question content classification module, a knowledge data ordering module, a context basis determination module, a question reconstruction module, an inference module, and a result output module, respectively.
In the embodiment, the current knowledge data is subjected to knowledge classification through a knowledge classification model to obtain a customer service classification knowledge base; determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base; performing problem reconstruction on the problem content according to the similarity; reasoning the reconstructed question content to obtain an answer corresponding to the question content; through the method, after the customer service classification knowledge base is classified by knowledge of the knowledge classification model, the similarity of the problem content and the knowledge data is determined, then the problem is reconstructed according to the similarity, and the answer corresponding to the problem content is inferred based on the reconstructed problem content, so that the question and answer quality and efficiency of intelligent customer service can be effectively improved, the experience of a user is improved, and the format of the input knowledge data is not required to be considered.
In an embodiment, as shown in fig. 5, a second embodiment of the intelligent question-answering control method according to the present invention is provided based on the first embodiment, and the step S30 includes:
step S301, sorting the knowledge data in the corresponding category of the customer service classification knowledge base according to the similarity.
It should be understood that after the similarity is obtained, the knowledge data in the corresponding category of the customer service classification knowledge base is ranked according to a preset ranking rule, where the preset ranking rule may be a ranking rule from large to small.
Step S302, based on the sorted knowledge data, the knowledge data corresponding to the maximum similarity is used as target knowledge data.
It is understood that the target knowledge data refers to knowledge data corresponding to the maximum similarity, and since the number of cosine distances between the feature vector of the problem content and the feature vector of each knowledge data in the category is plural, the number of similarities determined by the cosine distances is plural, at this time, the maximum similarity among the plural similarities is traversed, and knowledge data corresponding to the maximum similarity is taken as the target knowledge data.
Step S303, splicing the target knowledge data, and counting the word length of the spliced knowledge data in real time.
It should be appreciated that after determining the target knowledge data, the target knowledge data is spliced, and the word length of the spliced knowledge data is counted in real time until the word length of the spliced knowledge data is greater than a preset length threshold, which may be 1800.
And step S304, stopping splicing when the word number length is greater than a preset length threshold value, obtaining splicing knowledge data, and generating a target context basis according to the splicing knowledge data.
It can be appreciated that when the word count length is determined to be greater than the preset length threshold, the stitching is stopped, and a target context basis is generated from stitching knowledge data for which the stitching knowledge data does not exceed the preset length threshold.
Step S305, combining the target context with the problem content.
Further, step S305 includes: obtaining a context according to the filling position and the problem content filling position according to the target question structure; and filling the target context into the context according to the filling position, and filling the problem content into the problem content filling position.
It can be understood that the Context-based filling location refers to a location where a target Context is dynamically filled, and similarly, the Question-content filling location refers to a location where a Question content is dynamically filled, for example, the target Context is Context, the Question content is Question, and the structural Question of the reconstructed Question content is "please answer Question according to Context", if it cannot answer according to Context, ' i don't know ', context: { fill in Context content }, question: { fill request content } ", wherein the content in the { position is the content that needs to be dynamically filled, specifically, the target context is filled into the context according to the filling position, and the problem content is filled into the problem content filling position.
According to the embodiment, all knowledge data in the corresponding category of the customer service classification knowledge base are ordered according to the similarity; based on the sorted knowledge data, taking the knowledge data corresponding to the maximum similarity as target knowledge data; splicing the target knowledge data, and counting the word number length of the spliced knowledge data in real time; stopping splicing when the word length is greater than a preset length threshold value, obtaining splicing knowledge data, and generating a target context basis according to the splicing knowledge data; combining the target context basis with the problem content; according to the method, after the target knowledge data are spliced, whether the word number length of the spliced knowledge data is larger than the preset length threshold value is counted in real time, if yes, the splicing is stopped, the target context basis is generated according to the spliced knowledge data, and then the target context basis and the problem content are combined, so that accuracy of reconstructing the problem content can be effectively improved.
In addition, the embodiment of the invention also provides a storage medium, wherein the storage medium is stored with an intelligent question-answer control program, and the intelligent question-answer control program realizes the steps of the intelligent question-answer control method when being executed by a processor.
Because the storage medium adopts all the technical schemes of all the embodiments, the storage medium has at least all the beneficial effects brought by the technical schemes of the embodiments, and the description is omitted here.
In addition, referring to fig. 6, an embodiment of the present invention further provides an intelligent question-answering control device, where the intelligent question-answering control device includes:
the classification module 10 is configured to perform knowledge classification on the current knowledge data through a knowledge classification model, so as to obtain a customer service classification knowledge base.
And the determining module 20 is configured to determine similarity between the inputted problem content and each knowledge data in the corresponding category of the customer service classification knowledge base.
And the reconstruction module 30 is configured to reconstruct the problem content according to the similarity.
And the reasoning module 40 is used for reasoning the reconstructed question content to obtain an answer corresponding to the question content.
In the embodiment, the current knowledge data is subjected to knowledge classification through a knowledge classification model to obtain a customer service classification knowledge base; determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base; performing problem reconstruction on the problem content according to the similarity; reasoning the reconstructed question content to obtain an answer corresponding to the question content; through the method, after the customer service classification knowledge base is classified by knowledge of the knowledge classification model, the similarity of the problem content and the knowledge data is determined, then the problem is reconstructed according to the similarity, and the answer corresponding to the problem content is inferred based on the reconstructed problem content, so that the question and answer quality and efficiency of intelligent customer service can be effectively improved, the experience of a user is improved, and the format of the input knowledge data is not required to be considered.
It should be noted that the above-described working procedure is merely illustrative, and does not limit the scope of the present invention, and in practical application, a person skilled in the art may select part or all of them according to actual needs to achieve the purpose of the embodiment, which is not limited herein.
In addition, technical details not described in detail in this embodiment may refer to the intelligent question-answering control method provided in any embodiment of the present invention, which is not described herein.
In an embodiment, the classification module 10 is further configured to collect various knowledge text data according to the knowledge question-answering application field; preprocessing the various knowledge text data, and distributing target type labels for the preprocessed various knowledge text data; converting various knowledge text data after label allocation through a text vectorization model to obtain a current knowledge vector; extracting features of the current knowledge vector through a character feature extraction model to obtain a knowledge feature vector; and inputting the knowledge feature vector into a text classification network constructed based on the GRU structure and the Softmax layer, and constructing a knowledge classification model.
In an embodiment, the classification module 10 is further configured to convert the current knowledge data through a text vectorization model to obtain an initial knowledge vector; extracting features of the initial knowledge vector through a character feature extraction model to obtain a target knowledge feature vector; carrying out knowledge classification on the target knowledge feature vector through a knowledge classification model to obtain various knowledge feature vectors; generating each knowledge tuple according to the knowledge feature vectors and knowledge data corresponding to the knowledge feature vectors; and generating a customer service classification knowledge base according to the knowledge tuples.
In an embodiment, the determining module 20 is further configured to convert the input problem content through a text vectorization model to obtain a problem content vector; extracting features of the problem content vectors through a character feature extraction model to obtain problem content feature vectors; classifying the problem content feature vectors through a language classification model to obtain knowledge categories to which the problem content belongs; determining a category corresponding to the knowledge category in the customer service classification knowledge base, and determining a feature vector of each knowledge data in the category; respectively calculating cosine distances between the feature vectors of the problem content and the feature vectors of the knowledge data in the category; and determining the similarity between the problem content and each knowledge data in the category according to the cosine distance.
In an embodiment, the reconstruction module 30 is further configured to sort the knowledge data in the corresponding category of the customer service classification knowledge base according to the similarity; based on the sorted knowledge data, taking the knowledge data corresponding to the maximum similarity as target knowledge data; splicing the target knowledge data, and counting the word number length of the spliced knowledge data in real time; stopping splicing when the word length is greater than a preset length threshold value, obtaining splicing knowledge data, and generating a target context basis according to the splicing knowledge data; the target context basis is combined with the problem content.
In one embodiment, the reconstruction module 30 is further configured to obtain a context according to the filling location and the question content filling location according to the target question structure; and filling the target context into the context according to the filling position, and filling the problem content into the problem content filling position.
In one embodiment, the inference module 40 is further configured to input the reconstructed problem content into a target large language model; and outputting an answer corresponding to the content of the question through the target large language model.
Other embodiments of the intelligent question-answering control device or the implementation method thereof can refer to the above method embodiments, and are not repeated here.
Furthermore, it should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system 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 system. 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 system that comprises the element.
The foregoing embodiment numbers of the present invention are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
From the above description of the embodiments, it will be clear to those skilled in the art that the above-described embodiment method may be implemented by means of software plus a necessary general hardware platform, but of course may also be implemented by means of hardware, but in many cases the former is a preferred embodiment. Based on such understanding, the technical solution of the present invention may be embodied essentially or in a part contributing to the prior art in the form of a software product stored in a storage medium (e.g. Read Only Memory)/RAM, magnetic disk, optical disk) and including several instructions for causing a terminal device (which may be a mobile phone, a computer, an integrated platform workstation, or a network device, etc.) to perform the method according to the embodiments of the present invention.
The foregoing description is only of the preferred embodiments of the present invention, and is not intended to limit the scope of the invention, but rather is intended to cover any equivalents of the structures or equivalent processes disclosed herein or in the alternative, which may be employed directly or indirectly in other related arts.

Claims (10)

1. The intelligent question-answering control method is characterized by comprising the following steps of:
carrying out knowledge classification on the current knowledge data through a knowledge classification model to obtain a customer service classification knowledge base;
determining the similarity of the input problem content and knowledge data in the corresponding category of the customer service classification knowledge base;
performing problem reconstruction on the problem content according to the similarity;
and reasoning the reconstructed question content to obtain an answer corresponding to the question content.
2. The intelligent question-answering control method according to claim 1, wherein before the knowledge classification is performed on the current knowledge data by the knowledge classification model to obtain the customer service classification knowledge base, further comprising:
collecting various knowledge text data according to the knowledge question-answering application field;
preprocessing the various knowledge text data, and distributing target type labels for the preprocessed various knowledge text data;
converting various knowledge text data after label allocation through a text vectorization model to obtain a current knowledge vector;
extracting features of the current knowledge vector through a character feature extraction model to obtain a knowledge feature vector;
and inputting the knowledge feature vector into a text classification network constructed based on the GRU structure and the Softmax layer, and constructing a knowledge classification model.
3. The intelligent question-answering control method according to claim 1, wherein the performing knowledge classification on the current knowledge data through the knowledge classification model to obtain a customer service classification knowledge base comprises:
converting the current knowledge data through a text vectorization model to obtain an initial knowledge vector;
extracting features of the initial knowledge vector through a character feature extraction model to obtain a target knowledge feature vector;
carrying out knowledge classification on the target knowledge feature vector through a knowledge classification model to obtain various knowledge feature vectors;
generating each knowledge tuple according to the knowledge feature vectors and knowledge data corresponding to the knowledge feature vectors;
and generating a customer service classification knowledge base according to the knowledge tuples.
4. The intelligent question-answering control method according to claim 1, wherein the determining the similarity of the inputted question content and each knowledge data in the corresponding category of the customer service classification knowledge base includes:
converting the input problem content through a text vectorization model to obtain a problem content vector;
extracting features of the problem content vectors through a character feature extraction model to obtain problem content feature vectors;
classifying the problem content feature vectors through a language classification model to obtain knowledge categories to which the problem content belongs;
determining a category corresponding to the knowledge category in the customer service classification knowledge base, and determining a feature vector of each knowledge data in the category;
respectively calculating cosine distances between the feature vectors of the problem content and the feature vectors of the knowledge data in the category;
and determining the similarity between the problem content and each knowledge data in the category according to the cosine distance.
5. The intelligent question-answering control method according to claim 1, wherein the performing the question reconstruction on the question content according to the similarity comprises:
sequencing the knowledge data in the corresponding category of the customer service classification knowledge base according to the similarity;
based on the sorted knowledge data, taking the knowledge data corresponding to the maximum similarity as target knowledge data;
splicing the target knowledge data, and counting the word number length of the spliced knowledge data in real time;
stopping splicing when the word length is greater than a preset length threshold value, obtaining splicing knowledge data, and generating a target context basis according to the splicing knowledge data;
the target context basis is combined with the problem content.
6. The intelligent question-answering control method according to claim 5, wherein the combining the target context basis with the question content comprises:
obtaining a context according to the filling position and the problem content filling position according to the target question structure;
and filling the target context into the context according to the filling position, and filling the problem content into the problem content filling position.
7. The intelligent question-answering control method according to any one of claims 1 to 6, wherein the reasoning about the reconstructed question contents to obtain answers corresponding to the question contents, comprises:
inputting the reconstructed problem content into a target large language model;
and outputting an answer corresponding to the content of the question through the target large language model.
8. An intelligent question-answering control device, characterized in that the intelligent question-answering control device comprises:
the classification module is used for carrying out knowledge classification on the current knowledge data through the knowledge classification model to obtain a customer service classification knowledge base;
the determining module is used for determining the similarity between the input problem content and each knowledge data in the corresponding category of the customer service classification knowledge base;
the reconstruction module is used for carrying out problem reconstruction on the problem content according to the similarity;
and the reasoning module is used for reasoning the reconstructed question content and obtaining an answer corresponding to the question content.
9. An intelligent question-answering control device, characterized in that the intelligent question-answering control device comprises: a memory, a processor and a smart question-answer control program stored on the memory and executable on the processor, the smart question-answer control program being configured to implement the smart question-answer control method of any one of claims 1 to 7.
10. A storage medium having stored thereon an intelligent question-answer control program which, when executed by a processor, implements the intelligent question-answer control method of any one of claims 1 to 7.
CN202311585908.9A 2023-11-24 2023-11-24 Intelligent question-answering control method, device, equipment and storage medium Pending CN117493524A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311585908.9A CN117493524A (en) 2023-11-24 2023-11-24 Intelligent question-answering control method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311585908.9A CN117493524A (en) 2023-11-24 2023-11-24 Intelligent question-answering control method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN117493524A true CN117493524A (en) 2024-02-02

Family

ID=89676126

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311585908.9A Pending CN117493524A (en) 2023-11-24 2023-11-24 Intelligent question-answering control method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN117493524A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117725423A (en) * 2024-02-18 2024-03-19 青岛海尔科技有限公司 Method and device for generating feedback information based on large model

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117725423A (en) * 2024-02-18 2024-03-19 青岛海尔科技有限公司 Method and device for generating feedback information based on large model
CN117725423B (en) * 2024-02-18 2024-05-24 青岛海尔科技有限公司 Method and device for generating feedback information based on large model

Similar Documents

Publication Publication Date Title
CN110175227B (en) Dialogue auxiliary system based on team learning and hierarchical reasoning
CN111027327B (en) Machine reading understanding method, device, storage medium and device
CN111026842B (en) Natural language processing method, natural language processing device and intelligent question-answering system
KR102288249B1 (en) Information processing method, terminal, and computer storage medium
CN109284399B (en) Similarity prediction model training method and device and computer readable storage medium
CN113377936B (en) Intelligent question and answer method, device and equipment
CN111062220B (en) End-to-end intention recognition system and method based on memory forgetting device
CN111680147A (en) Data processing method, device, equipment and readable storage medium
CN117493524A (en) Intelligent question-answering control method, device, equipment and storage medium
CN111339277A (en) Question-answer interaction method and device based on machine learning
CN115470338B (en) Multi-scenario intelligent question answering method and system based on multi-path recall
CN111026840A (en) Text processing method, device, server and storage medium
CN113297351A (en) Text data labeling method and device, electronic equipment and storage medium
CN111782793A (en) Intelligent customer service processing method, system and equipment
CN111666376A (en) Answer generation method and device based on paragraph boundary scan prediction and word shift distance cluster matching
CN113282711A (en) Internet of vehicles text matching method and device, electronic equipment and storage medium
CN115827819A (en) Intelligent question and answer processing method and device, electronic equipment and storage medium
CN110689359A (en) Method and device for dynamically updating model
CN117668180A (en) Document question-answering method, document question-answering device, and readable storage medium
CN117172508B (en) Automatic dispatch method and system based on city complaint worksheet recognition
TW202034207A (en) Dialogue system using intention detection ensemble learning and method thereof
CN116561288B (en) Event query method, device, computer equipment, storage medium and program product
CN112463930A (en) Electric pin AI robot based on artificial intelligence
CN112884009A (en) Classification model training method and system
CN111460114A (en) Retrieval method, device, equipment and computer readable 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