Intention analysis method and device based on semantic similarity and knowledge graph fusion
By fusing semantic similarity with knowledge graphs, this intent parsing method addresses the issues of low accuracy and efficiency in existing text intent parsing technologies, achieving more efficient and accurate intent parsing and improving user conversion rates and business processing efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGDONG GUANGXIN COMM SERVICES COMPANY
- Filing Date
- 2025-10-23
- Publication Date
- 2026-04-21
AI Technical Summary
Existing methods of text intent parsing rely on manually written rules and templates, resulting in low accuracy and efficiency when faced with new intents or expressions, and failing to effectively parse the intent of user input.
An intent parsing method based on semantic similarity and knowledge graph fusion is adopted. Through text preprocessing, semantic vectorization, extraction of core intent words and business words, business word completion and final intent parsing operation, combined with LLM and knowledge graph, the final intent parsing result is determined.
It improves the accuracy and efficiency of intent parsing, enhances the comprehensiveness and rationality of intent parsing, and improves user conversion rate and business processing efficiency.
Smart Images

Figure CN121009901B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intent parsing technology, and in particular to an intent parsing method and apparatus based on the fusion of semantic similarity and knowledge graph. Background Technology
[0002] With the digital transformation of customer service in telecommunications, finance, government and other fields, it is becoming increasingly common for users to conduct business inquiries and transactions through text or voice input. Intelligent customer service is gradually replacing traditional human customer service in some aspects. Therefore, interpreting the intent of user input has become a major research focus.
[0003] Currently, the methods for parsing the intent of input text mainly rely on manually written rules and templates. The input text is matched against existing text templates to identify template text content that matches the input text. The preset intent of this template text content is then used as the final intent of the input text. However, when the input text does not exist in existing text templates, or when new intent requirements or expressions arise, the intent of the current input text cannot be determined. Alternatively, the final intent can only be output after real-time and accurate updates to the rule base. Therefore, existing text intent parsing methods suffer from low accuracy and efficiency. It is therefore crucial to provide a solution that improves the accuracy and efficiency of text intent parsing. Summary of the Invention
[0004] This invention provides an intent parsing method and apparatus based on the fusion of semantic similarity and knowledge graph, which can improve the accuracy and efficiency of intent parsing of input text.
[0005] To address the aforementioned technical problems, the first aspect of this invention discloses an intent parsing method based on the fusion of semantic similarity and knowledge graph, the method comprising:
[0006] Obtain the input text that needs to be parsed, and perform corresponding text preprocessing operations on the input text to obtain standardized text;
[0007] Perform corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text to obtain semantic understanding results. The semantic understanding results include at least the target core intent phrase, the target business words, and the semantic vectors of the business words.
[0008] Based on the target business terms and the constructed business knowledge graph, determine the complete word information and business attribute information;
[0009] Based on the target core intent phrase, the business word semantic vector, the completion word information, and the business attribute information, the final intent parsing result is determined. The final intent parsing result includes final intent information, completion information, and confidence result. The final intent parsing result is used in at least one of customer service dialogue scenarios, work order generation scenarios, and knowledge question answering engine scenarios.
[0010] As an optional implementation, in the first aspect of the present invention, performing corresponding semantic vectorization and core intent words and business word extraction operations on the standardized text to obtain semantic understanding results includes:
[0011] Perform corresponding semantic analysis operations on the standardized text to obtain the current semantic analysis result;
[0012] Based on the established current business domain vocabulary, the standardized text, and the established business term extraction method, basic business terms are determined, and based on the basic business terms, the current semantic analysis results, and the established intent term extraction method, basic core intent terms are determined.
[0013] When the number of combinations of the basic core intent words and the basic business words is less than or equal to a preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words.
[0014] When the number of combinations of the basic core intent words and the basic business words is greater than a preset combination number threshold, the target core intent phrase is determined based on all the basic core intent words, and the target business word is determined based on all the basic business words.
[0015] Perform the corresponding semantic vector generation operation on the target business term to obtain the business term semantic vector;
[0016] The semantic understanding result is determined based on the target core intent phrase, the target business term, and the semantic vector of the business term.
[0017] As an optional implementation, in the first aspect of the present invention, determining the basic business terms based on the set current business domain terminology, the standardized text, and the set business term extraction method includes:
[0018] Based on the standardized text, the corresponding entity word recognition result is determined, and the entity word recognition result includes the target entity word;
[0019] Determine the shallow matching degree between the target identification entity word and each set business word in the set current business domain word list, and determine whether the target identification entity word meets the preset shallow business related conditions based on all the shallow matching degrees.
[0020] When it is determined that the target entity word meets the shallow business-related conditions, a target set business word with a shallow matching degree greater than or equal to a preset shallow matching degree threshold is determined from the current business domain word list and used as a basic business word.
[0021] When it is determined that the target entity word does not meet the shallow business-related conditions, the deep matching degree between the target entity word and each set business word in the current business domain lexicon is determined according to the set deep semantic relationship analysis method. The deep semantic relationship analysis method includes at least one of the following: hyper-level semantic relationship analysis method, hypo-level semantic relationship analysis method, synonym semantic relationship analysis method, and attribute analysis method. Based on all the deep matching degrees, it is determined whether the target entity word meets the preset deep business-related conditions.
[0022] When it is determined that the target entity word meets the deep business-related conditions, the target set business word with a corresponding deep matching degree greater than or equal to the preset deep matching degree threshold is determined from the current business domain table and used as the basic business word.
[0023] As an optional implementation, in a first aspect of the present invention, the step of determining the target core intent phrase based on all the said basic core intent words, and determining the target business word based on all the said basic business words, includes:
[0024] Determine whether all the aforementioned basic core intent words meet the preset intent conflict conditions;
[0025] When it is determined that all the basic core intent words do not meet the intent conflict condition, all the basic core intent words are identified as target core intent phrases, and all the basic business words are identified as target business words.
[0026] When all the basic core intent words are determined to meet the intent conflict conditions, the predicted intent is determined based on pre-collected historical dialogue data and / or historical input data; based on the predicted intent, the conflict creation situation of all the basic core intent words is determined; when the conflict creation situation indicates that a subjective input error leads to a conflict, a target basic core intent word matching the predicted intent is determined from all the basic core intent words as the target core intent phrase; when the conflict creation situation indicates that a clear opposite need leads to a conflict, all the basic core intent words are determined as the target core intent phrase; based on the target core intent phrase, a target business word is determined from all the basic business words.
[0027] As an optional implementation, in the first aspect of the present invention, determining the final intent parsing result based on the target core intent phrase, the business word semantic vector, the completion word information, and the business attribute information includes:
[0028] Based on the completed word information, a completed word vector is determined, and a corresponding concatenation operation is performed on the completed word vector and the business word semantic vector to obtain the vector concatenation result;
[0029] Based on the target core intent phrase, the vector concatenation result, and the business attribute information, determine the semantic similarity result and the knowledge graph matching confidence result;
[0030] Based on the semantic similarity results and the knowledge graph matching confidence results, the confidence result of the target core intent phrase is determined;
[0031] When the confidence result indicates that the confidence of the target core intent phrase is greater than or equal to a preset confidence threshold, the final intent parsing result is determined based on the target core intent phrase, its confidence result, and the completion word information.
[0032] As an optional implementation, in the first aspect of the present invention, determining the complete word information and business attribute information based on the target business term and the constructed business knowledge graph includes:
[0033] Based on the constructed business knowledge graph, the hypernym information of the target business term is determined, the hyponym information of the target business term is determined based on the business knowledge graph, and the synonym information of the target business term is determined based on the business knowledge image.
[0034] Based on the hypernym information, the hyponym information, and the synonym information, the complete word information is determined, and the business attribute information of the target business word is determined.
[0035] As an optional implementation, in the first aspect of the present invention, performing corresponding text preprocessing operations on the input text to obtain standardized text includes:
[0036] Perform corresponding word segmentation operations on the input text to obtain one or more segmented texts;
[0037] Perform corresponding part-of-speech tagging operations on each segmented text to obtain the part-of-speech tagged text result;
[0038] Perform corresponding business-related entity word recognition and extraction operations on the part-of-speech tagging text results to obtain entity word recognition results;
[0039] Perform corresponding stop word filtering operations on the part-of-speech tagging text results to obtain filtered text results;
[0040] Based on the filtered text results and the entity word recognition results, standardized text is determined.
[0041] A second aspect of this invention discloses an intent parsing device based on the fusion of semantic similarity and knowledge graph, the device comprising:
[0042] The text preprocessing module is used to acquire the input text that needs to be parsed for intent, and to perform corresponding text preprocessing operations on the input text to obtain standardized text;
[0043] The semantic understanding module is used to perform corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text to obtain semantic understanding results. The semantic understanding results include at least the target core intent phrase, the target business words, and the semantic vectors of the business words.
[0044] The completion module is used to determine the completion word information and business attribute information based on the target business word and the constructed business knowledge graph;
[0045] The final parsing and generation module is used to determine the final intent parsing result based on the target core intent phrase, the business word semantic vector, the completion word information and the business attribute information. The final intent parsing result includes final intent information, completion information and confidence result. The final intent parsing result is used in at least one of customer service dialogue scenarios, work order generation scenarios and knowledge question answering engine scenarios.
[0046] As an optional implementation, in the second aspect of the present invention, the semantic understanding module performs corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text to obtain the semantic understanding result in the following specific ways:
[0047] Perform corresponding semantic analysis operations on the standardized text to obtain the current semantic analysis result;
[0048] Based on the established current business domain vocabulary, the standardized text, and the established business term extraction method, basic business terms are determined, and based on the basic business terms, the current semantic analysis results, and the established intent term extraction method, basic core intent terms are determined.
[0049] When the number of combinations of the basic core intent words and the basic business words is less than or equal to a preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words.
[0050] When the number of combinations of the basic core intent words and the basic business words is greater than a preset combination number threshold, the target core intent phrase is determined based on all the basic core intent words, and the target business word is determined based on all the basic business words.
[0051] Perform the corresponding semantic vector generation operation on the target business term to obtain the business term semantic vector;
[0052] The semantic understanding result is determined based on the target core intent phrase, the target business term, and the semantic vector of the business term.
[0053] As an optional implementation, in the second aspect of the present invention, the semantic understanding module determines the basic business terms based on the set current business domain lexicon, the standardized text, and the set business term extraction method, specifically including:
[0054] Based on the standardized text, the corresponding entity word recognition result is determined, and the entity word recognition result includes the target entity word;
[0055] Determine the shallow matching degree between the target identification entity word and each set business word in the set current business domain word list, and determine whether the target identification entity word meets the preset shallow business related conditions based on all the shallow matching degrees.
[0056] When it is determined that the target entity word meets the shallow business-related conditions, a target set business word with a shallow matching degree greater than or equal to a preset shallow matching degree threshold is determined from the current business domain word list and used as a basic business word.
[0057] When it is determined that the target entity word does not meet the shallow business-related conditions, the deep matching degree between the target entity word and each set business word in the current business domain lexicon is determined according to the set deep semantic relationship analysis method. The deep semantic relationship analysis method includes at least one of the following: hyper-level semantic relationship analysis method, hypo-level semantic relationship analysis method, synonym semantic relationship analysis method, and attribute analysis method. Based on all the deep matching degrees, it is determined whether the target entity word meets the preset deep business-related conditions.
[0058] When it is determined that the target entity word meets the deep business-related conditions, the target set business word with a corresponding deep matching degree greater than or equal to the preset deep matching degree threshold is determined from the current business domain table and used as the basic business word.
[0059] As an optional implementation, in a second aspect of the present invention, the semantic understanding module determines the target core intent phrase based on all the basic core intent words, and determines the target business word based on all the basic business words in a specific manner including:
[0060] Determine whether all the aforementioned basic core intent words meet the preset intent conflict conditions;
[0061] When it is determined that all the basic core intent words do not meet the intent conflict condition, all the basic core intent words are identified as target core intent phrases, and all the basic business words are identified as target business words.
[0062] When all the basic core intent words are determined to meet the intent conflict conditions, the predicted intent is determined based on pre-collected historical dialogue data and / or historical input data; based on the predicted intent, the conflict creation situation of all the basic core intent words is determined; when the conflict creation situation indicates that a subjective input error leads to a conflict, a target basic core intent word matching the predicted intent is determined from all the basic core intent words as the target core intent phrase; when the conflict creation situation indicates that a clear opposite need leads to a conflict, all the basic core intent words are determined as the target core intent phrase; based on the target core intent phrase, a target business word is determined from all the basic business words.
[0063] As an optional implementation, in the second aspect of the present invention, the method by which the final parsing generation module determines the final intent parsing result based on the target core intent phrase, the business word semantic vector, the completion word information, and the business attribute information specifically includes:
[0064] Based on the completed word information, a completed word vector is determined, and a corresponding concatenation operation is performed on the completed word vector and the business word semantic vector to obtain the vector concatenation result;
[0065] Based on the target core intent phrase, the vector concatenation result, and the business attribute information, determine the semantic similarity result and the knowledge graph matching confidence result;
[0066] Based on the semantic similarity results and the knowledge graph matching confidence results, the confidence result of the target core intent phrase is determined;
[0067] When the confidence result indicates that the confidence of the target core intent phrase is greater than or equal to a preset confidence threshold, the final intent parsing result is determined based on the target core intent phrase, its confidence result, and the completion word information.
[0068] As an optional implementation, in the second aspect of the present invention, the method by which the completion module determines the completion word information and business attribute information based on the target business word and the constructed business knowledge graph specifically includes:
[0069] Based on the constructed business knowledge graph, the hypernym information of the target business term is determined, the hyponym information of the target business term is determined based on the business knowledge graph, and the synonym information of the target business term is determined based on the business knowledge image.
[0070] Based on the hypernym information, the hyponym information, and the synonym information, the complete word information is determined, and the business attribute information of the target business word is determined.
[0071] As an optional implementation, in a second aspect of the present invention, the text preprocessing module performs corresponding text preprocessing operations on the input text to obtain standardized text, specifically including:
[0072] Perform corresponding word segmentation operations on the input text to obtain one or more segmented texts;
[0073] Perform corresponding part-of-speech tagging operations on each segmented text to obtain the part-of-speech tagged text result;
[0074] Perform corresponding business-related entity word recognition and extraction operations on the part-of-speech tagging text results to obtain entity word recognition results;
[0075] Perform corresponding stop word filtering operations on the part-of-speech tagging text results to obtain filtered text results;
[0076] Based on the filtered text results and the entity word recognition results, standardized text is determined.
[0077] A third aspect of this invention discloses another intent parsing device based on the fusion of semantic similarity and knowledge graph, the device comprising:
[0078] Memory containing executable program code;
[0079] A processor coupled to the memory;
[0080] The processor calls the executable program code stored in the memory to execute the intent parsing method based on semantic similarity and knowledge graph fusion disclosed in the first aspect of the present invention.
[0081] The fourth aspect of the present invention discloses a computer storage medium storing computer instructions, which, when invoked, are used to execute the intent parsing method based on semantic similarity and knowledge graph fusion disclosed in the first aspect of the present invention.
[0082] Compared with the prior art, the embodiments of the present invention have the following beneficial effects:
[0083] In this embodiment of the invention, input text for intent parsing is obtained, and corresponding text preprocessing operations are performed on the input text to obtain standardized text; corresponding semantic vectorization and core intent words and business words extraction operations are performed on the standardized text to obtain semantic understanding results, which include at least target core intent phrases, target business words, and semantic vectors of business words; based on the target business words and the constructed business knowledge graph, complete word information and business attribute information are determined; based on the target core intent phrases, the semantic vectors of the business words, the complete word information, and the business attribute information, the final intent parsing result is determined, which includes final intent information, complete information, and confidence results, and the final intent parsing result is used in at least one of customer service dialogue scenarios, work order generation scenarios, and knowledge question answering engine scenarios. As can be seen, this invention can realize the text intent parsing function through text preprocessing, semantic vectorization and extraction of core intent words and business words, business word completion, and final intent parsing result determination. This is beneficial to improving the comprehensiveness and rationality of intent parsing methods, thereby improving the accuracy and reliability of text intent parsing, as well as improving the efficiency and convenience of text intent parsing. In turn, it is beneficial to improve the user conversion rate and business processing efficiency based on the final intent parsing result. Attached Figure Description
[0084] To more clearly illustrate the technical solutions in the embodiments of the present invention, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0085] Figure 1 This is a flowchart illustrating an intent parsing method based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention;
[0086] Figure 2 This is a flowchart illustrating another intent parsing method based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention.
[0087] Figure 3 This is a schematic diagram of the structure of an intent parsing device based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention;
[0088] Figure 4 This is a schematic diagram of another intent parsing device based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention;
[0089] Figure 5 The present invention provides a schematic diagram of the module execution of an intent parsing method based on the fusion of semantic similarity and knowledge graph. Detailed Implementation
[0090] To enable those skilled in the art to better understand the present invention, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0091] The terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this invention are used to distinguish different objects, not to describe a specific order. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or end that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or ends.
[0092] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of the invention. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a separate or alternative embodiment mutually exclusive with other embodiments. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0093] This invention discloses an intent parsing method and apparatus based on the fusion of semantic similarity and knowledge graph. It achieves text intent parsing through text preprocessing, semantic vectorization, extraction of core intent words and business terms, business term completion, and final intent parsing result determination. This improves the comprehensiveness and rationality of the intent parsing method, thereby enhancing the accuracy and reliability of text intent parsing, as well as its efficiency and convenience. Ultimately, this leads to higher user conversion rates and improved business processing efficiency based on the final intent parsing results. Detailed explanations follow.
[0094] Example 1
[0095] Please see Figure 1 , Figure 1 This is a flowchart illustrating an intent parsing method based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention. Figure 1 The described method can be applied to an intent parsing device based on the fusion of semantic similarity and knowledge graph. Among them, the device can include a server, where the server includes a local server or a cloud server, which is not limited in the embodiments of the present invention. As Figure 1 shown, the intent parsing method based on the fusion of semantic similarity and knowledge graph includes the following operations:
[0096] 101. Obtain the input text that needs to be parsed for intent, and perform corresponding text preprocessing operations on the input text to obtain a standardized text.
[0097] Optionally, receive the input text obtained from the natural language query input by the user through text or voice. Further, the input text can come from the customer service window of the telecom APP, online customer service on the web page, speech recognition and transcription results, etc., which is not limited in the embodiments of the present invention.
[0098] Optionally, for the input text, text preprocessing operations, and standardized text, for example: the input text is like: ["My home broadband is disconnected. Can you help me report the repair?"]; the text preprocessing operations include Chinese word segmentation, part-of-speech tagging, named entity recognition, stop word filtering, etc. Specifically, Chinese word segmentation can be to segment the sentence using HanLP or Jieba, and the segmented text is like: ["My home", "broadband", "disconnected", "can", "help", "report the repair", "吗"]; part-of-speech tagging can be to tag the part of speech for each segmented word, and the text result of part-of-speech tagging is like: ["broadband / noun", "disconnected / verb", "report the repair / verb"]; named entity recognition can be to identify and extract entity words related to the business, and the entity word recognition result is like: ["broadband"]; stop word filtering can be to remove stop words without actual meaning, such as removing ["了", "吗"] to obtain the filtered text result; therefore, the obtained standardized text is like: ["My home", "broadband", "disconnected", "help", "report the repair"], which is not limited in the embodiments of the present invention.
[0099] 102. Perform corresponding semantic vectorization and extraction operations of core intent words and business words on the standardized text to obtain a semantic understanding result, where the semantic understanding result at least includes a target core intent phrase, a target business word, and a business word semantic vector.
[0100] Optionally, use LLM (such as ChatGLM, Qwen, GPT-4) and combine Prompt Engineering to extract core intent phrases and business words, and generate semantic vectors, which is not limited in the embodiments of the present invention.
[0101] Optionally, for the target core intent phrase and target business word, for example: the target core intent phrase is like: ["broadband repair"]; the target business word is like ["broadband"], which is not limited in the embodiments of the present invention.
[0102] Optionally, a historical customer service dialogue corpus can be used, combined with instruction fine-tuning. The fine-tuning goal is to improve the accuracy of core intent phrase extraction and the recall rate of business word extraction. Specifically, data preparation involves collecting a historical customer service dialogue database to output a raw annotated corpus dataset. This database contains user input, manually annotated core intent phrases, and business words. Data preprocessing involves cleaning invalid data (empty text, garbled characters), removing stop words and abnormal characters, and standardizing the format of the output raw annotated corpus dataset, resulting in a clean list of structured training samples. Prompt template enhancement involves inputting the structured training sample list and constructing a Prompt template for each sample, outputting a training pair containing Prompt and Target Output. SFT fine-tuning involves inputting the Prompt-Target training pair, loading the base model using LLM, and fine-tuning the model by using Prompt as input and Target as the supervised target during training. The optimization goal is to minimize the loss function between the model's generated output and the Target Output, outputting the fine-tuned LLM. The model possesses the ability to extract core intent phrases and business terms. Model deployment and inference invocation: After inputting a fine-tuned LLM model, the processing operation involves deploying the model to the inference service framework and invoking the model in real-time based on user input. The input Prompt outputs the extracted core intent phrases and business terms, providing them for use by downstream knowledge graph completion and intent discrimination modules. Furthermore, the Prompt is designed using SFT + Prompt Template Augmentation, employing instruction-based fine-tuning to enable the model not only to classify but also to generate structured output, improving upstream and downstream integration and increasing the accuracy of understanding enterprise domain-specific vocabulary by over 20%. This invention is not limited to any specific embodiment.
[0103] Optionally, transfer learning is used to train the intent classification model. It is first pre-trained on a public dataset and then fine-tuned using enterprise business data. Specifically, the transfer process is as follows: the source task is the public dataset for intent classification, and the target task is intent classification of enterprise business data. The model structure is as follows: the base model is BERT / RoBERTa, and the classification layer is a fully connected layer + Softmax. The optimization objective is to use cross-entropy loss + Focal Loss (to handle imbalanced samples). The recognition rate of low-sample categories (long-tail intents) is improved through transfer learning, which is not limited in this embodiment of the invention.
[0104] Further, the specific training method of the intent classification model is as follows: (1) Data preparation: Input basis: historical customer service dialogue data collected in the LLM fine-tuning step, including: user original input manually annotated core intent phrases and business words; Execution goal: to build a standardized dataset for pre-training and fine-tuning of the intent classification model; (2) Pre-training (source task training): Input basis: enterprise business dataset built in the data preparation step, and public intent classification dataset (such as SMP-ECDT, ATIS); Processing method: use BERT / RoBERTa as the basic model, perform pre-training on the public intent classification dataset, and obtain domain-general intent understanding ability; Output result: complete the pre-training of the intent classification basic model, obtain transferable model parameters, and use them for the next step; (3) Model fine-tuning (target task training): Input basis: pre-trained model parameters from the pre-training step, and enterprise business intent classification dataset in the data preparation step; Processing method: adopt transfer learning strategy: use the pre-trained model as initialization, and perform fine-tuning on the enterprise business dataset; Optimization goal: cross-entropy loss as the main loss function, Focal Loss is used to handle the problem of class sample imbalance and improve the recognition rate of long-tail intent categories; Output result: Complete the enterprise customized intent classification model, which has the ability to classify with high accuracy for target business; (4) Model evaluation and verification: Input basis: Enterprise customized intent classification model generated from the model fine-tuning step, and the validation set and test set reserved in the data preparation step; Processing method: Evaluation index: classification accuracy, macro-F1 score, long-tail category recall; Verify whether the model has achieved the expected goal: improve the recognition rate of small sample categories by ≥15%, and the overall intent classification accuracy by ≥90%; Output result: Output evaluation report to confirm that the model effect meets the online requirements. If not satisfied, backtrack to the model fine-tuning step to adjust parameters; (5) Model deployment: Input basis: Enterprise customized intent classification model that has been verified in the model evaluation and verification step; Processing method: Use GPU inference optimization (TensorRT / ONNX Runtime) to reduce inference latency, encapsulate it as an API service, and provide calling interface to the outside world through FastAPI / Flask / gRPC; Output result: Launch available intent classification service interface to provide model service support for the "intent discrimination and confidence calculation module" in the overall system architecture. This embodiment of the invention does not limit the scope of the invention.
[0105] Optionally, vector retrieval optimization can be performed using FAISS / Elasticsearch Dense Vector, combined with: index reconstruction to periodically rebuild the index to maintain retrieval efficiency, and quantization (IVF+PQ) as follows: IVF (Inverted File Index): building an inverted index + vector clustering to accelerate, and PQ (Product Quantization): compressing vector storage to reduce memory usage. This embodiment of the invention is not limited.
[0106] Optionally, the specific scheme for vector retrieval optimization is as follows: (1) Training vector generation: Input basis: a set of training data semantic vectors from model training or LLM semantic understanding module output, each vector representing the semantic representation of historical customer service dialogues or standard business knowledge items; Execution goal: to build a high-quality training vector set for the vector retrieval system as the basis for subsequent index construction and quantization training; Output result: generate a complete training vector set for use in the index training step; (2) Index training: Input basis: a set of training vectors from the training vector generation step; Processing method: cluster the training vectors to build an inverted file index structure, divide the vectors into different cluster centers, and speed up the candidate vector range limitation during query; perform **product quantization** training on the vectors within the cluster, divide the high-dimensional vectors into multiple sub-vectors, and quantize and encode each sub-vector to reduce memory usage and improve retrieval efficiency; Output result: complete the training of the index structure and quantization model, and obtain a deployable index model for use in the subsequent index construction step; (3) Index construction: Input basis: from the index The index model generated by the training step and the vector set of the training vector generation step; Processing method: Use the trained index model to insert all training vectors into the constructed index to form a compressed vector index library based on IVF+PQ technology, which not only ensures the retrieval accuracy, but also significantly reduces memory usage and adapts to large-scale business scenarios; Output result: Complete the quantized index library containing all business knowledge semantic vectors for subsequent retrieval steps; (4) Index reconstruction (regular maintenance): Input basis: The index library generated by the index construction step, and the newly added training vectors or business knowledge update results; Processing method: Reconstruct the index library regularly (e.g., weekly or monthly), retrain the clustering and quantization models, ensure that the index structure remains efficient as the data distribution changes, and avoid the decline in query efficiency; Output result: The updated optimized index library maintains performance and accuracy within the business requirements range and is used for online retrieval; (5) Online retrieval service deployment Input basis: The final optimized index library generated by the index reconstruction step; Processing method: Load the index library into the vector retrieval service and combine it with GPU Accelerate deployment, support fast vector similarity calculation, provide API interfaces for intent discrimination and confidence calculation modules to call, and realize millisecond-level similarity retrieval between user input and standard business knowledge in business scenarios; Output results: the online high-performance vector retrieval service supports the real-time semantic matching requirements of the overall system, and the embodiments of this invention are not limited.
[0107] Optionally, the semantic vector of the word is generated using LLM; similarity is calculated with all word vectors in the business vocabulary; threshold determination: if the similarity score is greater than the set threshold, the word is considered to be highly relevant to the business. This embodiment of the invention does not impose any limitations.
[0108] 103. Based on the target business terms and the constructed business knowledge graph, determine the complete word information and business attribute information.
[0109] Optionally, the Neo4j / TigerGraph graph database can be used to query business term entities; the knowledge graph can be automatically grown by combining LLM and graph database to adapt to rapidly changing business needs. This embodiment of the invention is not limited to this.
[0110] Optionally, the word completion information may include, but is not limited to, hypernyms, hyponyms, and synonyms. Furthermore, regarding word completion information and business attribute information, for example: assuming the target business term is "broadband," then the hypernym information could be "network service," the hyponym information could be "fiber optic broadband" or "gigabit broadband," the synonym information could be "internet" or "network broadband," and the business attribute information could be "package type" or "bandwidth rate." This embodiment of the invention does not impose limitations.
[0111] Optionally, by combining LLM automated entity extraction and relation extraction, dynamic updates can be achieved to form a self-evolving knowledge graph, resulting in a business knowledge graph. This embodiment of the invention does not impose any limitations.
[0112] Optionally, automatic entity extraction is performed, using LLM prompt to extract business terms and entity names, and extracting all business-related entities from the text; relation extraction is performed, using LLM to extract relationships between entities, and identifying the relationships between the following entities; graph database update is performed, using Cypher to insert new entities and relationships into Neo4j, which is not limited in the embodiments of this invention.
[0113] Optionally, part-of-speech tagging and context window can be combined for rule filtering after NER output; for example, if the part of speech is a noun or proper noun and the context contains business instructions (such as "process", "report repair", "upgrade", etc.), the confidence of business relevance can be improved. This embodiment of the invention does not limit this.
[0114] 104. Based on the target core intent phrase, business word semantic vector, completion word information and business attribute information, determine the final intent parsing result. The final intent parsing result includes the final intent information, completion information and confidence result. The final intent parsing result is used in at least one of the customer service dialogue scenario, work order generation scenario and knowledge question answering engine scenario.
[0115] Optionally, the semantic vectors of business terms and completed terms are concatenated; an intent classification model (BERT + classification head or fine-tuned LLaMA) is used to perform classification prediction of multi-dimensional feature inputs; further, the confidence results are calculated: the semantic similarity (i.e., cosine similarity) between the user input and each standard intent template is determined, and the knowledge graph matching confidence (i.e., KG Matching Confidence) is calculated based on the entity completion results; further, the confidence results are comprehensively calculated.
[0116] Final_Score = α × Semantic_Similarity + β × KG_Confidence, where α and β are weight values.
[0117] Optionally, for the final intent parsing result, for example: output "Final Intent": "Broadband Repair Request", "Complete Information": ["Fiber Optic Broadband", "Gigabit Broadband"], "Confidence Score": 0.97; further, the final intent parsing result is encapsulated into a standard API return structure and sent to the upstream business system (such as customer service dialogue engine, work order generation system, knowledge question answering engine, etc.); further, the user intent parsing result JSON, complete information and confidence score are used for business decision-making, and this embodiment of the invention is not limited.
[0118] Optional, Figure 5 This is a schematic diagram of module execution for another intent parsing method based on semantic similarity and knowledge graph fusion provided in an embodiment of the present invention. The embodiments of the present invention are not limited thereto.
[0119] Optionally, this solution can be specifically: (1) Preprocessing module: perform Chinese word segmentation, part-of-speech tagging, named entity recognition and stop word filtering on user input to form standardized text input; (2) Semantic understanding module: use LLM to perform semantic vectorization on the preprocessed text and extract core intent phrases; (3) Knowledge graph completion module: perform entity matching between the business words output by LLM and the knowledge graph to obtain hypernyms, hyponyms, synonyms and attribute information to achieve word generalization and refinement; (4) Intent discrimination and confidence calculation module: combine the LLM parsing results and the knowledge graph completion results, combine semantic similarity and graph matching confidence to calculate the final intent classification result; (5) Output module: return the final intent and confidence results to the upstream business system, such as customer service dialogue system, work order automatic generation module or knowledge question answering engine. This embodiment of the invention does not limit the scope of the invention.
[0120] As can be seen, the intent parsing method based on semantic similarity and knowledge graph fusion described in this embodiment of the invention can realize the text intent parsing function through text preprocessing, semantic vectorization and extraction of core intent words and business words, business word completion, and final intent parsing result determination. This is beneficial to improving the comprehensiveness and rationality of intent parsing methods, thereby improving the accuracy and reliability of text intent parsing, as well as improving the efficiency and convenience of text intent parsing, and thus improving the user conversion rate and business processing efficiency based on the final intent parsing result.
[0121] In an optional embodiment, the above-described semantic vectorization and core intent word and business word extraction operations performed on the standardized text to obtain semantic understanding results may include:
[0122] Perform the corresponding semantic analysis operation on the standardized text to obtain the current semantic analysis result;
[0123] Based on the established current business domain vocabulary, standardized text, and established business term extraction methods, basic business terms are determined. Based on the basic business terms, current semantic analysis results, and established intent term extraction methods, basic core intent terms are determined.
[0124] When the number of combinations of basic core intent words and basic business words is less than or equal to the preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words.
[0125] When the number of combinations of basic core intent words and basic business words exceeds the preset combination number threshold, the target core intent phrase is determined based on all basic core intent words, and the target business word is determined based on all basic business words.
[0126] Perform the corresponding semantic vector generation operation on the target business term to obtain the business term semantic vector;
[0127] The semantic understanding result is determined based on the target core intent phrase, target business terms, and semantic vectors of business terms.
[0128] Optionally, core intent words can be determined by combining preset standard intent templates. Furthermore, standard intent templates can be obtained through statistical analysis of historical manually annotated datasets. Specifically, standard intent templates can be obtained by combining past customer service dialogues and business processing corpora with manually annotated standard intent tags. Further, for example, each intent category corresponds to several standard expression examples, such as: Intent: "Broadband repair request"; Template sentences: "My broadband is down," "My broadband is broken, please report it for repair," "Please help me fix my home network." Further, these template sentences are generated into vectors through LLM Embedding and stored in a vector database (such as FAISS, ES Dense Vector, etc.). This embodiment of the invention does not impose limitations.
[0129] Optionally, the similarity between the user input sentence vector and all standard intent template vectors is calculated, and the highest score and corresponding intent category are selected as candidates. This embodiment of the invention does not impose any limitations.
[0130] Optionally, for example: if there is only one basic business term and one basic core intent term, there is no need to consider intent conflict, and subsequent operations can be performed directly based on the basic business term and the basic core intent term; furthermore, if there are multiple basic business terms and / or multiple basic core intent terms, it is necessary to consider whether there is intent conflict, but this embodiment of the invention does not limit this.
[0131] Optionally, the combination of basic core intent words and basic business words can be understood as: a basic core intent word and a basic business word form a combination. For example, the basic business word "broadband" and the basic core intent word "broadband acceleration" are a combination, and the basic business word "broadband" and the basic core intent word "broadband deceleration" are a combination. This embodiment of the invention does not limit this.
[0132] Optionally, the basic business terms are determined based on the set current business domain terminology, standardized text, and set business term extraction method. For example, based on the entity word recognition results in the standardized text, business terms that are directly similar to the entity word recognition results or indirectly similar (such as hypernyms, hyponyms, synonyms, etc.) are determined from the current business domain terminology and used as basic business terms. This embodiment of the invention does not limit this.
[0133] Optionally, the above-mentioned determination of semantic understanding results based on the target core intent phrase, target business words, and business word semantic vectors may include: determining the target core intent phrase, target business words, and business word semantic vectors as semantic understanding results, which is not limited in this embodiment of the invention.
[0134] As can be seen, this optional embodiment can determine the basic core intent words and basic business words, and then match the corresponding target core intent phrases and target business words according to the number of combinations of the basic core intent words and basic business words to further determine the semantic understanding results. This is conducive to improving the comprehensiveness and rationality of the semantic understanding result determination method, and to improving the diversity, flexibility, pertinence and fit of the target core intent phrases and target business words determination method. In turn, it is conducive to improving the accuracy and reliability of the determined target core intent phrases and target business words, thereby improving the accuracy and reliability of the determined business word semantic vectors, and further improving the accuracy and reliability of the determined semantic understanding results, and thus improving the semantic understanding accuracy and efficiency of the text.
[0135] In another optional embodiment, the determination of basic business terms based on the set current business domain thesaurus, standardized text, and set business term extraction method may include:
[0136] Based on the standardized text, the corresponding entity word recognition results are determined, including the target entity words.
[0137] Determine the shallow matching degree between the target entity word and each set business word in the current business domain vocabulary, and determine whether the target entity word meets the preset shallow business-related conditions based on all shallow matching degrees.
[0138] When it is determined that the target entity word meets the shallow business-related conditions, the target set business word with a shallow matching degree greater than or equal to the preset shallow matching degree threshold is determined from the current business domain word list and used as the basic business word;
[0139] When it is determined that the target entity word does not meet the shallow business-related conditions, the deep matching degree between the target entity word and each set business word in the current business domain vocabulary is determined according to the set deep semantic relationship analysis method. The deep semantic relationship analysis method includes at least one of the following: superordinate semantic relationship analysis method, subordinate semantic relationship analysis method, synonym semantic relationship analysis method, and attribute analysis method. Based on all deep matching degrees, it is determined whether the target entity word meets the preset deep business-related conditions.
[0140] When it is determined that the target entity word meets the deep business-related conditions, the target set business word with a deep matching degree greater than or equal to the preset deep matching degree threshold is determined from the current business domain table and used as the basic business word.
[0141] Optionally, for example: the target entity word in the entity word recognition result is matched with the current business domain word list. If the target entity word has a corresponding entity node in the current business domain word list, the word can be determined to be a business word in this domain. For example: if the input is "broadband disconnected", NER extracts "broadband", and the current business domain word list has a "broadband" node (including hyponyms, synonyms, and attributes), then the word "broadband" is identified as a relevant business word in this domain, that is, a basic business word. This embodiment of the invention does not limit this.
[0142] Optionally, maintain a thesaurus related to the current business domain (such as broadband package names, brands, functional terms, service types, etc.); specifically, if the words extracted by NER exist in the business thesaurus, they are considered "business-related". Applicable scenarios: small-scale scenarios can use static dictionaries, and large-scale scenarios can be dynamically updated by combining knowledge graphs. This embodiment of the invention does not limit the scope of the invention.
[0143] Optionally, the shallow matching degree between the target entity word and the set business word can be determined by whether the target entity word and the set business word are the same word. That is, the higher the semantic similarity / semantic matching degree / word similarity, the more the shallow business-related conditions are met. Further, for example: when the target entity word and the set business word are the same word, it is determined that the shallow matching degree is greater than or equal to the preset shallow matching degree threshold, and the target entity word is further determined to meet the preset shallow business-related conditions; when the target entity word and the set business word are not the same word, it is determined that the shallow matching degree is less than the preset shallow matching degree threshold, and the target entity word does not meet the preset shallow business-related conditions. This embodiment of the invention does not limit this.
[0144] Further optionally, the above determination of whether the target entity word meets the preset shallow business-related conditions based on all shallow matching degrees may include:
[0145] Determine whether there exists a target shallow matching degree among all the shallow matching degrees that is greater than or equal to a preset shallow matching degree threshold; if the determination result is yes, determine that the target identified entity word meets the preset shallow business-related conditions; if the determination result is no, determine that the target identified entity word does not meet the preset shallow business-related conditions.
[0146] Optionally, the deep matching degree between the target entity word and the set business word can be determined by whether there is a hierarchical semantic relationship or synonymous relationship between the target entity word and the set business word. That is, the greater the hierarchical semantic relationship / synonymous relationship, the more the deep business-related conditions are met. Further, for example: when there is a hierarchical semantic relationship or synonymous relationship between the target entity word and the set business word, the deep matching degree is determined to be greater than or equal to the deep matching degree threshold, and the target entity word is further determined to meet the deep business-related conditions; when there is no hierarchical semantic relationship or synonymous relationship between the target entity word and the set business word, the deep matching degree is determined to be less than the deep matching degree threshold, and the target entity word is further determined not to meet the deep business-related conditions. This embodiment of the invention does not limit this.
[0147] Further, optionally, the deep matching degree of the set business words that have synonymous association is greater than that of the set business words that have hierarchical semantic association, but this embodiment of the invention does not impose any limitation.
[0148] Further optionally, the above determination of whether the target entity word meets the preset deep business-related conditions based on all deep matching degrees may include:
[0149] Determine whether there exists a target deep matching degree among all the deep matching degrees that is greater than or equal to a preset deep matching degree threshold; if the determination result is yes, determine that the target identified entity word meets the preset deep business related conditions; if the determination result is no, determine that the target identified entity word does not meet the preset deep business related conditions.
[0150] Alternatively, the method may further include the following operations:
[0151] When it is determined that the target entity word does not meet the conditions related to the deep business, the system outputs a prompt that the relevant business does not exist, and / or transfers the user to a human customer service representative.
[0152] As can be seen, this optional embodiment can determine basic business terms by satisfying both shallow and deep business-related conditions. This is beneficial to improving the comprehensiveness, rationality, and progressiveness of the method for determining basic business terms, as well as the diversity, flexibility, and relevance of the method. Furthermore, it is beneficial to improve the diversity and comprehensiveness of the levels of consideration for determining basic business terms (i.e., shallow matching level and deep matching level), thereby improving the accuracy and reliability of the determined basic business terms.
[0153] In another optional embodiment, the above-mentioned determination of the target core intent phrase based on all basic core intent words and the determination of the target business word based on all basic business words may include:
[0154] Determine whether all basic core intent words meet the preset intent conflict conditions;
[0155] When it is determined that all basic core intent words do not meet the intent conflict condition, all basic core intent words are identified as target core intent phrases, and all basic business words are identified as target business words.
[0156] When all basic core intent words are determined to meet the intent conflict conditions, the predicted intent is determined based on pre-collected historical dialogue data and / or historical input data. Based on the predicted intent, the conflict creation situation of all basic core intent words is determined. When the conflict creation situation indicates that a subjective input error leads to conflict, the target basic core intent word that matches the predicted intent is determined from all basic core intent words and used as the target core intent phrase. When the conflict creation situation indicates that a clear opposite need leads to conflict, all basic core intent words are determined as the target core intent phrase. Based on the target core intent phrase, the target business word is determined from all basic business words.
[0157] Optionally, the above determination of whether all basic core intent words meet the preset intent conflict conditions can be illustrated as follows: for example, if one basic core intent word is "provide broadband warranty" and another basic core intent word is "cancel broadband warranty", then the preset intent conflict conditions are met; or if one basic core intent word is "speed up network" and another basic core intent word is "slow down network", then the preset intent conflict conditions are met. Other cases can be obtained in the same way, and this embodiment of the invention does not limit the scope of the invention.
[0158] Optionally, the aforementioned subjective input error leading to conflict can be illustrated by the following example: a conflict of intent may arise simply due to a typo. For instance, if historical dialogue data and / or historical input data both indicate "perform broadband maintenance," but the core intent word in the current dialog box is "do not perform broadband maintenance," it is highly likely that the user entered the wrong text, i.e., a conflict caused by a subjective input error. This embodiment of the invention does not limit this.
[0159] Optionally, the above-mentioned conflict caused by clearly opposing needs can be illustrated by the following example: through historical dialogue data and / or historical input data, it can be clearly known that the user is consulting on solutions for different devices. In this case, it is reasonable for multiple intentions to exist, that is, the conflict caused by clearly opposing needs. This embodiment of the present invention does not limit this.
[0160] Further, optionally, the process of identifying target business terms from all basic business terms based on the target core intent phrase may include:
[0161] Identify the target basic business terms that match the target core intent phrase from all basic business terms, and use them as the target business terms.
[0162] As can be seen, this optional embodiment can match the corresponding target core intent phrase determination method and target business word determination method according to the intent conflict conditions of the basic core intent words. This is beneficial to improving the comprehensiveness and rationality of the target core intent phrase determination method, as well as its diversity, flexibility, and relevance. In turn, it is beneficial to improve the accuracy and reliability of the determined target core intent phrase. In addition, it is beneficial to improve the comprehensiveness and rationality of the target business word determination method, as well as its diversity, flexibility, and relevance. In turn, it is beneficial to improve the accuracy and reliability of the determined target business words.
[0163] In another optional embodiment, the above-mentioned determination of the complete word information and business attribute information based on the target business term and the constructed business knowledge graph may include:
[0164] Based on the constructed business knowledge graph, determine the hypernym information of the target business term, determine the hyponym information of the target business term based on the business knowledge graph, and determine the synonym information of the target business term based on the business knowledge image.
[0165] Based on the information of hypernyms, hyponyms, and synonyms, the information of the completed words is determined, and the business attribute information of the target business words is determined.
[0166] As can be seen, this optional embodiment can determine the hypernym information, hyponym information, and synonym information of the target business term, and then determine the supplementary word information and business attribute information. This is conducive to improving the comprehensiveness and rationality of the method for determining the supplementary word information and business attribute information, and further conducive to improving the diversity and flexibility of the specific information of the supplementary word information. This is conducive to improving the accuracy and reliability of the determined supplementary word information, and also conducive to improving the accuracy and reliability of the determined business attribute information.
[0167] In yet another optional embodiment, the above-described text preprocessing operations on the input text to obtain standardized text may include:
[0168] Perform corresponding word segmentation operations on the input text to obtain one or more segmented texts;
[0169] Perform the corresponding part-of-speech tagging operation on each segmented text to obtain the part-of-speech tagged text result;
[0170] Perform corresponding business-related entity word recognition and extraction operations on the part-of-speech tagged text results to obtain entity word recognition results;
[0171] Perform corresponding stop word filtering operations on the part-of-speech tagged text results to obtain the filtered text results;
[0172] Based on the filtered text results and entity word recognition results, standardized text is determined.
[0173] As can be seen, this optional embodiment can achieve text preprocessing functions through word segmentation, part-of-speech tagging, business-related entity word recognition and extraction, and stop word filtering. This is beneficial to improving the comprehensiveness, rationality, and progressiveness of text preprocessing methods, as well as the diversity and flexibility of text preprocessing methods. In turn, it is beneficial to improve the accuracy, reliability, and relevance of the determined standardized text, thereby improving the standardization of subsequent semantic intent analysis based on standardized text.
[0174] Example 2
[0175] Please see Figure 2 , Figure 2 This is a flowchart illustrating another intent parsing method based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention. Figure 2 The described method can be applied to an intent parsing device based on the fusion of semantic similarity and knowledge graph. This device may include a server, which may be a local server or a cloud server; this embodiment of the invention is not limited to any particular server. Figure 2 As shown, this intent parsing method based on the fusion of semantic similarity and knowledge graph includes the following operations:
[0176] 201. Obtain the input text that needs to be parsed for intent, and perform corresponding text preprocessing operations on the input text to obtain standardized text.
[0177] 202. Perform corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text to obtain semantic understanding results. The semantic understanding results include at least the target core intent phrase, the target business words, and the semantic vectors of the business words.
[0178] 203. Based on the target business terms and the constructed business knowledge graph, determine the complete word information and business attribute information.
[0179] 204. Determine the word vector based on the word completion information, and perform corresponding concatenation operations on the word vector and the semantic vector of the business word to obtain the vector concatenation result.
[0180] Optionally, the completed word vector and the business word semantic vector can be simply concatenated in terms of dimension to obtain the vector concatenation result. This embodiment of the invention does not impose any limitations.
[0181] 205. Based on the target core intent phrase, vector concatenation results, and business attribute information, determine the semantic similarity results and knowledge graph matching confidence results.
[0182] Optionally, semantic similarity results can be calculated using the user input vector and the standard intent template vector; knowledge graph matching confidence results can be calculated using the matching degree between the knowledge graph entity completion results and the user input, and this embodiment of the invention does not impose any limitations.
[0183] 206. Based on the semantic similarity results and the knowledge graph matching confidence results, determine the confidence results of the target core intent phrase.
[0184] Optionally, the confidence result can be output as the final intent discrimination basis by weighted fusion of the determined classification prediction confidence, semantic similarity result and knowledge graph matching confidence result. This embodiment of the invention does not limit this.
[0185] 207. When the confidence result is used to represent the confidence of the target core intent phrase, it is greater than or equal to the preset confidence threshold. Based on the target core intent phrase, its confidence result, and the word completion information, the final intent parsing result is determined. The final intent parsing result is used in at least one of the customer service dialogue scenario, work order generation scenario, and knowledge question answering engine scenario.
[0186] Optionally, the target core intent phrase, its confidence result, and the word completion information may be determined as the final intent parsing result; however, this embodiment of the invention does not impose any limitations on this.
[0187] Optionally, when the confidence result meets the preset confidence filtering conditions, the final intent parsing result can be determined based on the target core intent phrase, its confidence result, and the completion word information. This embodiment of the invention does not limit this.
[0188] Further optionally, the above confidence level screening condition can be determined when the confidence level of the target core intent phrase is the highest among all candidate core intent phrases, thus satisfying the preset confidence level screening condition. This embodiment of the invention does not limit this.
[0189] In this embodiment of the invention, for other descriptions of steps 201-207, please refer to the other detailed descriptions of steps 101-104 in Embodiment 1. These descriptions will not be repeated in this embodiment of the invention.
[0190] As can be seen, the intent parsing method based on semantic similarity and knowledge graph fusion described in this embodiment of the invention can realize the text intent parsing function through text preprocessing, semantic vectorization and extraction of core intent words and business words, business word completion, and final intent parsing result determination. This is beneficial to improving the comprehensiveness and rationality of intent parsing methods, thereby improving the accuracy and reliability of text intent parsing, as well as the efficiency and convenience of text intent parsing. This, in turn, helps to improve the user conversion rate and business processing efficiency based on the final intent parsing result. Furthermore, it can also determine the semantic similarity result and knowledge graph matching confidence result to determine the final intent parsing result, which is beneficial to improving the comprehensiveness and rationality of the final intent parsing result determination method, thereby improving the accuracy and reliability of the determined final intent parsing result. This, in turn, helps to improve the user experience and satisfaction based on the final intent parsing result, reduces interaction time, and improves interaction efficiency.
[0191] Example 3
[0192] Please see Figure 3 , Figure 3 This is a schematic diagram of the structure of an intent parsing device based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention. Figure 3 The described apparatus may include a server, wherein the server includes a local server or a cloud server, and the embodiments of the present invention are not limited thereto. Figure 3 As shown, the intent parsing device based on the fusion of semantic similarity and knowledge graph may include:
[0193] The text preprocessing module 301 is used to obtain the input text that needs to be parsed for intent and to perform corresponding text preprocessing operations on the input text to obtain standardized text.
[0194] The semantic understanding module 302 is used to perform corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text to obtain semantic understanding results. The semantic understanding results include at least the target core intent phrase, the target business words, and the semantic vectors of the business words.
[0195] The completion module 303 is used to determine the completion word information and business attribute information based on the target business term and the constructed business knowledge graph.
[0196] The final parsing and generation module 304 is used to determine the final intent parsing result based on the target core intent phrase, business word semantic vector, completion word information and business attribute information. The final intent parsing result includes final intent information, completion information and confidence result. The final intent parsing result is used in at least one of the customer service dialogue scenario, work order generation scenario and knowledge question answering engine scenario.
[0197] It is evident that implementation Figure 3 The described intent parsing device based on semantic similarity and knowledge graph fusion can realize text intent parsing through text preprocessing, semantic vectorization and extraction of core intent words and business words, business word completion, and final intent parsing result determination. This helps improve the comprehensiveness and rationality of intent parsing methods, thereby improving the accuracy and reliability of text intent parsing, as well as its efficiency and convenience. Ultimately, this helps improve user conversion rate and business processing efficiency based on the final intent parsing result.
[0198] In an optional embodiment, the semantic understanding module 302 performs corresponding semantic vectorization and core intent words and business words extraction operations on the standardized text, and the specific methods for obtaining the semantic understanding results include:
[0199] Perform the corresponding semantic analysis operation on the standardized text to obtain the current semantic analysis result;
[0200] Based on the established current business domain vocabulary, standardized text, and established business term extraction methods, basic business terms are determined. Based on the basic business terms, current semantic analysis results, and established intent term extraction methods, basic core intent terms are determined.
[0201] When the number of combinations of basic core intent words and basic business words is less than or equal to the preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words.
[0202] When the number of combinations of basic core intent words and basic business words exceeds the preset combination number threshold, the target core intent phrase is determined based on all basic core intent words, and the target business word is determined based on all basic business words.
[0203] Perform the corresponding semantic vector generation operation on the target business term to obtain the business term semantic vector;
[0204] The semantic understanding result is determined based on the target core intent phrase, target business terms, and semantic vectors of business terms.
[0205] It is evident that implementation Figure 3The described device can also identify basic core intent words and basic business words, and then match the corresponding target core intent phrases and target business words according to the number of combinations of basic core intent words and basic business words to further determine the semantic understanding results. This is beneficial to improving the comprehensiveness and rationality of the semantic understanding result determination method, and to improving the diversity, flexibility, relevance and fit of the target core intent phrases and target business words determination method. In turn, it is beneficial to improve the accuracy and reliability of the determined target core intent phrases and target business words, thereby improving the accuracy and reliability of the determined business word semantic vectors, and further improving the accuracy and reliability of the determined semantic understanding results, and ultimately improving the accuracy and efficiency of text semantic understanding.
[0206] In another optional embodiment, the semantic understanding module 302 determines the basic business terms based on the set current business domain vocabulary, standardized text, and set business term extraction methods, specifically including:
[0207] Based on the standardized text, the corresponding entity word recognition results are determined, including the target entity words.
[0208] Determine the shallow matching degree between the target entity word and each set business word in the current business domain vocabulary, and determine whether the target entity word meets the preset shallow business-related conditions based on all shallow matching degrees.
[0209] When it is determined that the target entity word meets the shallow business-related conditions, the target set business word with a shallow matching degree greater than or equal to the preset shallow matching degree threshold is determined from the current business domain word list and used as the basic business word;
[0210] When it is determined that the target entity word does not meet the shallow business-related conditions, the deep matching degree between the target entity word and each set business word in the current business domain vocabulary is determined according to the set deep semantic relationship analysis method. The deep semantic relationship analysis method includes at least one of the following: superordinate semantic relationship analysis method, subordinate semantic relationship analysis method, synonym semantic relationship analysis method, and attribute analysis method. Based on all deep matching degrees, it is determined whether the target entity word meets the preset deep business-related conditions.
[0211] When it is determined that the target entity word meets the deep business-related conditions, the target set business word with a deep matching degree greater than or equal to the preset deep matching degree threshold is determined from the current business domain table and used as the basic business word.
[0212] It is evident that implementation Figure 3The described device can also determine basic business terms based on the satisfaction of shallow and deep business-related conditions. This helps to improve the comprehensiveness, rationality, and progressiveness of the method for determining basic business terms, as well as the diversity, flexibility, and relevance of the method. In turn, it helps to improve the diversity and comprehensiveness of the determination considerations (i.e., shallow matching level and deep matching level) of the basic business terms, thereby improving the accuracy and reliability of the determined basic business terms.
[0213] In another optional embodiment, the semantic understanding module 302 determines the target core intent phrase based on all basic core intent words, and the method for determining the target business word based on all basic business words specifically includes:
[0214] Determine whether all basic core intent words meet the preset intent conflict conditions;
[0215] When it is determined that all basic core intent words do not meet the intent conflict condition, all basic core intent words are identified as target core intent phrases, and all basic business words are identified as target business words.
[0216] When all basic core intent words are determined to meet the intent conflict conditions, the predicted intent is determined based on pre-collected historical dialogue data and / or historical input data. Based on the predicted intent, the conflict creation situation of all basic core intent words is determined. When the conflict creation situation indicates that a subjective input error leads to conflict, the target basic core intent word that matches the predicted intent is determined from all basic core intent words and used as the target core intent phrase. When the conflict creation situation indicates that a clear opposite need leads to conflict, all basic core intent words are determined as the target core intent phrase. Based on the target core intent phrase, the target business word is determined from all basic business words.
[0217] It is evident that implementation Figure 3 The described device can also match corresponding target core intent phrase determination methods and target business word determination methods according to the intent conflict conditions of the basic core intent words. This helps to improve the comprehensiveness and rationality of the target core intent phrase determination method, as well as its diversity, flexibility, and relevance, thereby improving the accuracy and reliability of the determined target core intent phrases. In addition, it helps to improve the comprehensiveness and rationality of the target business word determination method, as well as its diversity, flexibility, and relevance, thereby improving the accuracy and reliability of the determined target business words.
[0218] In another optional embodiment, the final parsing generation module 304 determines the final intent parsing result based on the target core intent phrase, business word semantic vector, completion word information, and business attribute information in the following specific ways:
[0219] The completed word vector is determined based on the completed word information, and the corresponding concatenation operation is performed on the completed word vector and the semantic vector of the business word to obtain the vector concatenation result;
[0220] Based on the target core intent phrase, vector concatenation results, and business attribute information, determine the semantic similarity results and knowledge graph matching confidence results;
[0221] Based on the semantic similarity results and the knowledge graph matching confidence results, the confidence results of the target core intent phrase are determined;
[0222] When the confidence score is greater than or equal to the preset confidence score threshold, the final intent parsing result is determined based on the target core intent phrase, its confidence score, and the word completion information.
[0223] It is evident that implementation Figure 3 The described device can also determine semantic similarity results and knowledge graph matching confidence results to determine the final intent parsing result, which helps to improve the comprehensiveness and rationality of the final intent parsing result determination method, thereby improving the accuracy and reliability of the determined final intent parsing result. This, in turn, helps to improve the user experience and satisfaction based on the final intent parsing result, reduce interaction time, and improve interaction efficiency.
[0224] In another optional embodiment, the completion module 303 determines the completion word information and business attribute information based on the target business word and the constructed business knowledge graph in the following specific ways:
[0225] Based on the constructed business knowledge graph, determine the hypernym information of the target business term, determine the hyponym information of the target business term based on the business knowledge graph, and determine the synonym information of the target business term based on the business knowledge image.
[0226] Based on the information of hypernyms, hyponyms, and synonyms, the information of the completed words is determined, and the business attribute information of the target business words is determined.
[0227] It is evident that implementation Figure 3The described device can also determine the hypernym information, hyponym information, and synonym information of the target business term, and then determine the supplementary word information and business attribute information. This is conducive to improving the comprehensiveness and rationality of the method of determining the supplementary word information and business attribute information, and further conducive to improving the diversity and flexibility of the specific information of the supplementary word information. This is conducive to improving the accuracy and reliability of the determined supplementary word information, and also conducive to improving the accuracy and reliability of the determined business attribute information.
[0228] In another optional embodiment, the text preprocessing module 301 performs corresponding text preprocessing operations on the input text to obtain standardized text, specifically including:
[0229] Perform corresponding word segmentation operations on the input text to obtain one or more segmented texts;
[0230] Perform the corresponding part-of-speech tagging operation on each segmented text to obtain the part-of-speech tagged text result;
[0231] Perform corresponding business-related entity word recognition and extraction operations on the part-of-speech tagged text results to obtain entity word recognition results;
[0232] Perform corresponding stop word filtering operations on the part-of-speech tagged text results to obtain the filtered text results;
[0233] Based on the filtered text results and entity word recognition results, standardized text is determined.
[0234] It is evident that implementation Figure 3 The described device can also perform text preprocessing functions through word segmentation, part-of-speech tagging, business-related entity word recognition and extraction, and stop word filtering. This helps to improve the comprehensiveness, rationality, and progressiveness of text preprocessing methods, as well as their diversity and flexibility. Consequently, it helps to improve the accuracy, reliability, and relevance of the standardized text, thereby enhancing the standardization of subsequent semantic intent analysis based on the standardized text.
[0235] Example 4
[0236] Please see Figure 4 , Figure 4 This is a schematic diagram of another intent parsing device based on the fusion of semantic similarity and knowledge graph disclosed in an embodiment of the present invention. Figure 4 The described apparatus may include a server, wherein the server includes a local server or a cloud server, and the embodiments of the present invention are not limited thereto. Figure 4 As shown, the device may include:
[0237] Memory 401 storing executable program code;
[0238] Processor 402 coupled to memory 401;
[0239] Furthermore, it may also include an input interface 403 coupled to the processor 402 and an output interface 404;
[0240] The processor 402 calls the executable program code stored in the memory 401 to execute the steps in the intent parsing method based on semantic similarity and knowledge graph fusion described in Embodiment 1 or Embodiment 2.
[0241] Example 5
[0242] This invention discloses a computer storage medium storing a computer program for electronic data interchange, wherein the computer program causes a computer to execute the steps in the intent parsing method based on semantic similarity and knowledge graph fusion described in Embodiment 1 or Embodiment 2.
[0243] Example 6
[0244] This invention discloses a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to cause a computer to perform the steps in the intent parsing method based on semantic similarity and knowledge graph fusion described in Embodiment 1 or Embodiment 2.
[0245] The device embodiments described above are merely illustrative. The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical modules; that is, they may be located in one place or distributed across multiple network modules. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.
[0246] Through the detailed description of the above embodiments, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, including read-only memory (ROM), random access memory (RAM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-Erasable Programmable Read-Only Memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, disk storage, magnetic tape storage, or any other computer-readable medium that can be used to carry or store data.
[0247] Finally, it should be noted that the intent parsing method and apparatus based on semantic similarity and knowledge graph fusion disclosed in the embodiments of the present invention are merely preferred embodiments of the present invention and are only used to illustrate the technical solutions of the present invention, not to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. An intent parsing method based on the fusion of semantic similarity and knowledge graph, characterized in that, The method includes: Obtain the input text that needs to be parsed, and perform corresponding text preprocessing operations on the input text to obtain standardized text; Perform corresponding semantic analysis operations on the standardized text to obtain the current semantic analysis result; Based on the established current business domain vocabulary, the standardized text, and the established business term extraction method, basic business terms are determined, and based on the basic business terms, the current semantic analysis results, and the established intent term extraction method, basic core intent terms are determined. When the number of combinations of the basic core intent words and the basic business words is less than or equal to a preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words. When the number of combinations of the basic core intent words and the basic business words is greater than a preset combination number threshold, it is determined whether all the basic core intent words meet the preset intent conflict condition. When it is determined that all the basic core intent words do not meet the intent conflict conditions, all the basic core intent words are identified as target core intent phrases, and all the basic business words are identified as target business words; When all the basic core intent words are determined to meet the intent conflict conditions, the predicted intent is determined based on pre-collected historical dialogue data; based on the predicted intent, the conflict situation of all the basic core intent words is determined; when the conflict situation is caused by subjective input error, a target basic core intent word matching the predicted intent is determined from all the basic core intent words as the target core intent phrase; when the conflict situation is caused by a clear opposite need, all the basic core intent words are determined as the target core intent phrase; based on the target core intent phrase, a target business word is determined from all the basic business words. Perform the corresponding semantic vector generation operation on the target business term to obtain the business term semantic vector; Based on the target business terms and the constructed business knowledge graph, determine the complete word information and business attribute information; Based on the target core intent phrase, the semantic vector of the business term, the completion word information, and the business attribute information, the final intent parsing result is determined. The final intent parsing result includes the target core intent phrase, completion information, and confidence result. Specifically, the semantic similarity result is calculated by comparing the input text with the standard intent template vector, the knowledge graph matching confidence result is calculated by comparing the knowledge graph entity completion result with the input text, and the confidence result of the target core intent phrase is determined based on the semantic similarity result and the knowledge graph matching confidence result.
2. The intent parsing method based on semantic similarity and knowledge graph fusion according to claim 1, characterized in that, The step of determining basic business terms based on the set current business domain terminology, the standardized text, and the set business term extraction method includes: Based on the standardized text, the corresponding entity word recognition result is determined, and the entity word recognition result includes the target entity word; Determine the shallow matching degree between the target identification entity word and each set business word in the set current business domain word list, and determine whether the target identification entity word meets the preset shallow business related conditions based on all the shallow matching degrees. When it is determined that the target entity word meets the shallow business-related conditions, a target set business word with a shallow matching degree greater than or equal to a preset shallow matching degree threshold is determined from the current business domain word list and used as a basic business word. When it is determined that the target entity word does not meet the shallow business-related conditions, the deep matching degree between the target entity word and each set business word in the current business domain lexicon is determined according to the set deep semantic relationship analysis method. The deep semantic relationship analysis method includes at least one of the following: hyper-level semantic relationship analysis method, hypo-level semantic relationship analysis method, synonym semantic relationship analysis method, and attribute analysis method. Based on all the deep matching degrees, it is determined whether the target entity word meets the preset deep business-related conditions. When it is determined that the target entity word meets the deep business-related conditions, a target business word with a deep matching degree greater than or equal to a preset deep matching degree threshold is determined from the current business domain word list and used as the basic business word.
3. The intent parsing method based on semantic similarity and knowledge graph fusion according to claim 1 or 2, characterized in that, The step of determining the complete word information and business attribute information based on the target business term and the constructed business knowledge graph includes: Based on the constructed business knowledge graph, the hypernym information of the target business term is determined, the hyponym information of the target business term is determined, and the synonym information of the target business term is determined. Based on the hypernym information, the hyponym information, and the synonym information, the complete word information is determined, and the business attribute information of the target business word is determined.
4. The intent parsing method based on semantic similarity and knowledge graph fusion according to claim 1 or 2, characterized in that, The step of performing corresponding text preprocessing operations on the input text to obtain standardized text includes: Perform corresponding word segmentation operations on the input text to obtain one or more segmented texts; Perform corresponding part-of-speech tagging operations on each segmented text to obtain the part-of-speech tagged text result; Perform corresponding business-related entity word recognition and extraction operations on the part-of-speech tagging text results to obtain entity word recognition results; Perform corresponding stop word filtering operations on the part-of-speech tagging text results to obtain filtered text results; Based on the filtered text results and the entity word recognition results, standardized text is determined.
5. An intent parsing device based on the fusion of semantic similarity and knowledge graph, characterized in that, The device includes: The text preprocessing module is used to acquire the input text that needs to be parsed for intent, and to perform corresponding text preprocessing operations on the input text to obtain standardized text; The semantic understanding module performs corresponding semantic analysis operations on the standardized text to obtain the current semantic analysis result; determines basic business words based on the set current business domain lexicon, the standardized text, and the set business word extraction method; and determines basic core intent words based on the basic business words, the current semantic analysis result, and the set intent word extraction method; when the number of combinations of the basic core intent words and the basic business words is less than or equal to a preset combination number threshold, the basic core intent words are determined as target core intent phrases, and the basic business words are determined as target business words; when the number of combinations of the basic core intent words and the basic business words is greater than the preset combination number threshold, it is determined whether all the basic core intent words meet the preset intent conflict condition; when it is determined that all the basic core intent words do not meet the intent conflict condition, all the basic core intent words are... The basic core intent words are identified as target core intent phrases, and all the basic business words are identified as target business words. When it is determined that all the basic core intent words meet the intent conflict condition, the contextual predicted intent is determined based on pre-collected historical dialogue data. Based on the contextual predicted intent, the conflict situation of all the basic core intent words is determined. When the conflict situation is caused by subjective input error, the target basic core intent word that matches the contextual predicted intent is identified from all the basic core intent words and is taken as the target core intent phrase. When the conflict situation is caused by a clear opposite need, all the basic core intent words are identified as target core intent phrases. Based on the target core intent phrase, the target business word is identified from all the basic business words. The corresponding semantic vector generation operation is performed on the target business word to obtain the business word semantic vector. The completion module is used to determine the completion word information and business attribute information based on the target business word and the constructed business knowledge graph; The final parsing and generation module is used to determine the final intent parsing result based on the target core intent phrase, the business word semantic vector, the completion word information, and the business attribute information. The final intent parsing result includes the target core intent phrase, completion information, and confidence result. Specifically, the semantic similarity result is calculated by comparing the input text with the standard intent template vector, the knowledge graph matching confidence is calculated by comparing the knowledge graph entity completion result with the input text, and the confidence result of the target core intent phrase is determined based on the semantic similarity result and the knowledge graph matching confidence.
6. An intent parsing device based on the fusion of semantic similarity and knowledge graph, characterized in that, The device includes: Memory containing executable program code; A processor coupled to the memory; The processor calls the executable program code stored in the memory to execute the intent parsing method based on semantic similarity and knowledge graph fusion as described in any one of claims 1-4.
7. A computer storage medium, characterized in that, The computer storage medium stores computer instructions, which, when invoked, are used to execute the intent parsing method based on semantic similarity and knowledge graph fusion as described in any one of claims 1-4.
Citation Information
Patent Citations
Tourism information consultation method and system based on big data analysis
CN118484592A