Intention recognition method and device based on large model
Through the big model-based intent recognition method, the feature extraction and decision tree model of user account information and multimedia data is used to solve the limitations of traditional intent recognition methods when dealing with natural language diversity and complexity, and improve the accuracy of intent recognition Sex and efficiency.
Patent Information
- Application Number
- CN202411443196.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-16
- Publication Date
- 2025-01-10
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional intent recognition methods have limitations in dealing with the diversity and complexity of natural language, resulting in low recognition accuracy and inability to effectively process multimodal data.
A large model-based intent recognition method is adopted to obtain user account information and multimedia information (text, voice, image), feature extraction, semantic correlation weight calculation and sorting, and user intent recognition is performed by obtaining user account information and multimedia information (text, speech, image), and a preset decision tree model is used to identify user intent.
It significantly improves the accuracy and processing efficiency of intention recognition, overcomes the limitations of language diversity and complexity processing, reduces the dependence on artificial feature engineering, and improves the accuracy of user intention recognition in complex scenarios.
Smart Images

Figure CN119293274A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of intention recognition, and in particular to a large model-based intention recognition method and device. Background Art
[0002] Intent Recognition, also known as intent detection, is an important task in natural language processing (NLP). Its goal is to identify the user's intention from their natural language input, and is usually used in applications such as dialogue systems, voice assistants, and chatbots. By understanding the user's intention, the system can make appropriate responses or perform corresponding operations.
[0003] Traditional intent recognition methods are mainly based on text analysis, which uses technologies such as word segmentation, part-of-speech tagging, and syntactic analysis to extract text features, and combines classification algorithms for analysis and prediction. However, this method has some limitations, such as the inability to handle the diversity and complexity of natural language, and has certain limitations for the diversity of language expressions, and cannot accurately recognize. In summary, traditional intent recognition methods rely on text feature extraction and classification algorithms, but they are limited in handling the diversity and complexity of natural language, and the recognition accuracy is low when facing complex scenarios. Summary of the invention
[0004] The present invention provides a method and device for intent recognition based on a large model, which can effectively extract key information from multimodal data and improve the accuracy of data processing, thereby effectively improving the accuracy of intent recognition.
[0005] In a first aspect, in order to solve the above technical problems, the present invention provides an intention recognition method based on a large model, comprising: Acquire user account information and multimedia information input by the user; wherein the multimedia information input type includes text, voice and image; wherein the user account information includes user name, membership level and registration date; Extracting features from the multimedia information to obtain a feature vector; Calculating the semantic relevance weights of the feature vectors and sorting them to obtain labeled feature data; According to the user account information, a corresponding preset decision tree model is selected, and the preset decision tree model is used to process the annotated feature data to obtain a user intention recognition result.
[0006] Preferably, extracting features from the multimedia information to obtain a feature vector includes: Based on a preset semantic dictionary, performing a word segmentation operation on the multimedia information to obtain word segmentation materials; According to the segmented data, construct a feature matrix and a semantic matrix; A vector conversion operation is performed according to the feature matrix and the semantic matrix to obtain a feature vector.
[0007] Preferably, the feature matrix is specifically an m*n matrix; Wherein, m is the number of the segmented data, and n is the number of the multimedia information input types; Wherein, each element of the feature matrix is Aij, wherein i represents the segmentation material, and j represents the multimedia information input type; The value condition of Aij is: judging whether the word segment material i appears in the multimedia information input type j, if so, the corresponding element Aij takes a value of 1; if not, the corresponding element Aij takes a value of 0.
[0008] Preferably, the semantic matrix is specifically an m*m matrix; Wherein, m is the number of the segmented data; Wherein, each element Sxy of the semantic matrix represents the semantic similarity between the segmented text x and the segmented text y; The calculation formula of the semantic similarity is: In the formula, Indicates the semantic similarity between segmented data and segmented data; Indicates the semantic similarity between segmented data x and segmented data j; It represents the semantic similarity between the segmented data y and the segmented data x.
[0009] Preferably, performing a vector conversion operation according to the feature matrix and the semantic matrix to obtain a feature vector includes: Multiplying the feature matrix and the semantic matrix to obtain a semantic relevance matrix; The row vector of the semantic relevance matrix is used as the feature vector.
[0010] Preferably, the calculating the semantic relevance weights of the feature vectors and sorting them to obtain the labeled feature data includes: According to the feature vector and the preset standard semantic vector, the semantic relevance weight is calculated; wherein the relevance weight calculation formula is: In the formula, A semantic relevance weight representing the feature vector and the preset standard semantic vector; Respectively represent the feature vector and the preset standard semantic vector; represents the vector magnitude; The semantic relevance weights are sorted by size, and the corresponding feature vectors are labeled to obtain labeled feature data after the semantic relevance weights are sorted by size.
[0011] Preferably, selecting a corresponding preset decision tree model according to the user account information, and using the preset decision tree model to process the annotated feature data to obtain a user intention recognition result includes: Based on the user identity information, the user identity category is identified; wherein the user identity category is an administrator user, a general user, and a new user; Based on the identified user category, a corresponding preset decision tree model is selected, and the labeled feature data is processed using the preset decision tree model to obtain a user intent recognition result; wherein the preset decision tree model has been pre-trained based on user data of different user categories.
[0012] Preferably, the user identity category identification based on the user identity information includes: According to the user account information, the account information combination weight is calculated based on the preset account information weight; wherein the calculation formula of the account information combination weight is: In the formula, Indicates the weight of user account information; Represents the i-th user account information; The user category is identified according to the account information combined weight to obtain the user category.
[0013] Preferably, the user identity category identification based on the user identity information further includes: According to the user account information, the membership degree of the user account information is calculated based on the membership function; wherein the membership function calculation formula is: In the formula, and Respectively represent the membership of administrator users, general users, and new users; Indicates the weight of user account information; Represents the i-th user account information; is a similarity function that represents the similarity between the user account information and the administrator user information value; Indicates the similarity between user account information and general user information values Represents the similarity between the user account information and the new user information value; Indicates the number of user account information; The user category is identified according to the membership degree to obtain the user category.
[0014] In a second aspect, the present invention provides an intention recognition device based on a large model, comprising: An information acquisition module is used to acquire user account information and multimedia information input by the user; A feature extraction module, used to extract features from the multimedia information to obtain a feature vector; A weight calculation module calculates the semantic relevance weights of the feature vectors and sorts them to obtain labeled feature data; The intention recognition module is used to select a corresponding preset decision tree model according to the user account information, and use the preset decision tree model to process the marked feature data to obtain a user intention recognition result.
[0015] In a third aspect, the present invention also provides an electronic device comprising a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, wherein when the processor executes the computer program, the large model-based intention recognition method described above is implemented.
[0016] In a fourth aspect, the present invention also provides a computer-readable storage medium, which includes a stored computer program, wherein when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute any one of the above-mentioned large model-based intention recognition methods.
[0017] Compared with the prior art, the present invention has the following beneficial effects: the embodiment of the present invention provides a method and device for intention recognition based on a large model. The method includes: obtaining user account information and multimedia information input by the user; wherein the multimedia information input type includes text, voice and image; wherein the user account information includes user name, membership level and registration date; extracting features from the multimedia information to obtain feature vectors; calculating the semantic relevance weights of the feature vectors and sorting them to obtain annotated feature data; selecting a corresponding preset decision tree model according to the user account information, and using the preset decision tree model to process the annotated feature data to obtain a user intention recognition result.
[0018] In the present invention, the method can significantly improve the accuracy and processing efficiency of intent recognition by effectively extracting key information from multimodal data and combining it with a decision tree model of user account information. By calculating and sorting semantic relevance weights, the method effectively overcomes the limitations of traditional intent recognition methods in processing language diversity and complexity, reduces reliance on artificial feature engineering, and improves the recognition accuracy of user intent in complex scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0019] Figure 1 is a flowchart of a large model-based intention recognition method provided by the first embodiment of the present invention; Figure 2 It is a schematic diagram of the structure of the large model-based intention recognition device provided in the second embodiment of the present invention. DETAILED DESCRIPTION
[0020] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0021] Reference Figure 1 The first embodiment of the present invention provides an intention recognition method based on a large model, comprising the following steps: S11, obtaining user account information and multimedia information input by the user.
[0022] S12, extracting features from the multimedia information to obtain a feature vector.
[0023] S13, calculating the semantic relevance weights of the feature vectors and sorting them to obtain labeled feature data.
[0024] S14, selecting a corresponding preset decision tree model according to the user account information, and using the preset decision tree model to process the annotated feature data to obtain a user intention recognition result.
[0025] It is worth mentioning that intent recognition, also known as intent detection, is an important task in natural language processing (NLP). Its goal is to identify the user's intent from their natural language input, and is usually used in applications such as dialogue systems, voice assistants, and chatbots. By understanding the user's intent, the system can make appropriate responses or perform corresponding operations.
[0026] In order to facilitate the understanding of the present invention, some preferred embodiments of the present invention are further described below.
[0027] In step S11, the user account information and the multimedia information input by the user are obtained. Preferably, the multimedia information input type includes text, voice and image. Preferably, the user account information includes user name, membership level and registration date.
[0028] It is worth noting that the user name is obtained from the unique identifier (such as username, email address or phone number) provided by the user when registering or logging in. This information is usually stored in the database of the user management system and can be automatically retrieved by the system when the user logs in. The membership level is based on the user's activities and contributions on the platform. The system will divide users into different membership levels (such as ordinary users, VIP members, etc.). This level information can be dynamically updated and stored through the system's membership management module. The registration date is the timestamp when the user first registered in the system. This data is usually automatically recorded in the database and can be used to determine the user's activity or provide weight basis for decision-making models.
[0029] Specifically, the method for obtaining user account information can be: when the user logs in, the system confirms the user's identity through an identity authentication module (such as user name and password, fingerprint, facial recognition, etc.); next, the system calls the user management database, extracts relevant account information, and passes this information to the intent recognition module as auxiliary input.
[0030] It is worth noting that multimedia information input by users plays a key role in the process of intent recognition. Specific multimedia information includes three main types: text, voice and image. Specifically, the source of text input can be text input provided by users through keyboards, mobile phones, chat boxes, etc., which are usually used to interact with dialogue systems or platforms. The source of voice input can be users interacting with the system through voice assistants and voice input devices (such as microphones). The system uses speech recognition (ASR, Automatic Speech Recognition) technology to convert voice into text. The input voice is generally converted into text. Users provide voice information through devices. The system transmits the voice signal to the voice processing module and uses a pre-trained voice recognition model (such as Google ASR or a custom model) to convert the voice signal into text. The converted text data, like the directly input text data, enters the semantic processing module to generate a text feature vector. The source of image input can be user-provided image data by uploading pictures, shooting with a camera, etc. This type of input is usually used in scenarios that require visual perception, such as product recognition and face recognition. The system uses image recognition technology (such as convolutional neural network CNN) to extract features from images. After preprocessing (such as scaling and normalization), the image is converted into image feature vectors, which represent the key information in the image.
[0031] In step S12, feature extraction is performed on the multimedia information to obtain a feature vector. Preferably, the feature extraction of the multimedia information to obtain a feature vector includes: performing a word segmentation operation on the multimedia information based on a preset semantic dictionary to obtain a word segmentation material; constructing a feature matrix and a semantic matrix according to the word segmentation material; performing a vector conversion operation according to the feature matrix and the semantic matrix to obtain a feature vector. Preferably, the feature matrix is specifically an m*n matrix; wherein m is the number of the word segmentation materials, and n is the number of the multimedia information input types; wherein each element of the feature matrix is Aij, wherein i represents the word segmentation material, and j represents the multimedia information input type; wherein the value condition of Aij is: judging whether the word segmentation material i appears in the multimedia information input type j, if so, the corresponding element Aij takes a value of 1; if not, the corresponding element Aij takes a value of 0. The semantic matrix is specifically an m*m matrix, wherein m is the number of the segmented data; wherein each element Sxy of the semantic matrix represents the semantic similarity between the segmented data x and the segmented data y; wherein the calculation formula of the semantic similarity is: , where Indicates the semantic similarity between segmented data and segmented data; Indicates the semantic similarity between segmented data x and segmented data j; Represents the semantic similarity of the segmented text y to the segmented text x. Preferably, performing a vector conversion operation according to the feature matrix and the semantic matrix to obtain a feature vector includes: multiplying the feature matrix and the semantic matrix to obtain a semantic relevance matrix; and using the row vector of the semantic relevance matrix as the feature vector.
[0032] Specifically, the system needs to extract useful features from the multimedia information (including text, voice, and images) input by the user. These features represent the key content of the multimedia information, and the system ultimately recognizes the user's intention by calculating and analyzing these features.
[0033] First, word segmentation is performed. The system uses a preset semantic dictionary to decompose the entire text into several words. The words after word segmentation are called "word segmentation materials", which are the basis for subsequent feature extraction. The word segmentation materials are a set of words that have been processed by word segmentation, and are the basic units of the system when further constructing the feature matrix. It is worth noting that the semantic dictionary is a tool for storing and managing vocabulary and its related semantic information in the field of natural language processing (NLP). It provides the system with semantic relationships between words, such as synonyms, antonyms, parts of speech, semantic similarity, etc., and plays an important role in intent recognition and other NLP tasks. In the intent recognition method based on a large model, the semantic dictionary is used to help the system better understand the multimedia information input by the user (text, voice, text transcription in the image), and generate feature vectors for subsequent processing through word segmentation and semantic analysis. In the present invention, the system performs word segmentation on the input multimedia information through the semantic dictionary. Word segmentation is to split a continuous text stream into independent words or phrases. Based on the semantic dictionary, the system can recognize common words and their deformations, and better understand the sentence structure. For example, if the text input by the user is "I want to book a ticket to Paris", the semantic dictionary can help the system break down this sentence into separate words, such as "I want", "book", "one", "go", "Paris", "ticket", etc.
[0034] Secondly, based on the word segmentation material, a feature matrix and a semantic matrix are constructed. Specifically, it can be known from the definition of the feature matrix of the present invention that the feature matrix helps the system to represent this information in a unified structure by integrating data from different input types. Since the input may include multiple types such as text, voice and image, the feature matrix allows the system to process and analyze these different modal data at the same time, and makes them the basis for further processing. In the subsequent processing of the system, the feature matrix is combined with the semantic matrix to calculate the semantic relevance between words. The word distribution information in the feature matrix provides basic data for semantic analysis. The system can further calculate the similarity between words through the semantic matrix based on the distribution pattern in the feature matrix to generate a feature vector for intention recognition. Specifically, the semantic matrix is a two-dimensional matrix for representing the semantic similarity between word segmentation materials. Each element of the matrix represents the semantic relevance between two words, that is, their degree of similarity. The rows and columns of the semantic matrix represent the words after word segmentation, so it is a square matrix (symmetric matrix) with a dimension of m*m, where m is the number of word segmentation materials. It can be obtained from the definition of semantic similarity that this calculation method is to average the similarity in different directions to obtain a more balanced semantic similarity evaluation. The specific value of semantic similarity can be calculated in a variety of ways. Common methods include word vector calculation based on word embedding (such as Word2Vec, GloVe, BERT). It is worth noting that the semantic similarity of word segmentation data x to word segmentation data j can be calculated in the following way: First, the system performs word segmentation on the input text or voice data to obtain a series of word segmentation data. These word segmentation data will serve as the index of the rows and columns of the semantic matrix. The system uses pre-trained word embedding models (such as Word2Vec, BERT, etc.) to convert each word into a vector in a high-dimensional semantic space. These vectors can capture the semantic meaning of words. By calculating the cosine similarity or other distance metrics between word vectors, the system can obtain the semantic similarity between each pair of words.
[0035] Finally, the vector conversion operation is performed. Once the feature matrix and semantic matrix are constructed, the next step is to convert these matrices into feature vectors for use by subsequent models. The semantic relevance matrix is obtained by multiplying the feature matrix and the semantic matrix to obtain a new matrix, called the semantic relevance matrix. This matrix combines the distribution information of each segmented material in different input types and the semantic relationship between them. In general, the semantic relevance matrix is a matrix generated by combining the feature matrix with the semantic matrix, which is used to characterize the semantic and distribution characteristics of words in the input data. It integrates the features of the segmented materials and the semantic similarity between them to generate feature vectors that can be further used for intent recognition. The semantic relevance matrix can help the system understand the semantic meaning of multimodal input more accurately and provide a basis for subsequent intent classification or prediction tasks. The biggest advantage of the semantic relevance matrix is that it organically combines the frequency of occurrence and semantic similarity of words. The feature matrix only reflects whether a word appears or not, while the semantic matrix captures the deep semantic relationship between words. By combining the two, the semantic relevance matrix can generate a more comprehensive word representation, which helps the system better understand the actual semantics of user input. Each row vector of the semantic relevance matrix represents the semantic relevance of a specific segmented material in different input types, and these row vectors will eventually be input into the intent recognition model as feature vectors. Compared with directly using the feature matrix, the feature vector generated by the semantic relevance matrix contains richer semantic information, thereby improving the accuracy of the intent recognition model.
[0036] It is worth mentioning that the reason for taking the row vector of the semantic relevance matrix as the feature vector is that the row vector contains the comprehensive semantic information of each word segment (word) in different input types. It not only reflects the occurrence of words in each input type, but also integrates the semantic similarity between it and other words. Specifically, the row vector of the semantic relevance matrix contains key information about many aspects of a word in the input data: the frequency or position of the word. Through the feature matrix, the row vector records whether the word appears in different input types, such as text, voice, image, etc.; the semantic relationship between the word and other words. Through the semantic matrix, the row vector reflects the semantic similarity between the word and other words. This similarity can help the system understand the potential intentions expressed by synonyms or semantically similar words. Taking the row vector as a feature vector can capture these two types of information in a unified vector representation, so that the model can fully understand the meaning of words during the intent recognition process.
[0037] In step S13, the semantic relevance weights of the feature vectors are calculated and sorted to obtain the labeled feature data. Preferably, the semantic relevance weights of the feature vectors are calculated and sorted to obtain the labeled feature data, including: calculating the semantic relevance weights according to the feature vectors and the preset standard semantic vectors; wherein the relevance weight calculation formula is: , where A semantic relevance weight representing the feature vector and the preset standard semantic vector; Respectively represent the feature vector and the preset standard semantic vector; Represents the vector modulus; sorts the semantic relevance weights by size, and labels the corresponding feature vectors to obtain labeled feature data after the semantic relevance weights are sorted by size.
[0038] Specifically, the semantic relevance weights of the feature vectors are calculated and sorted to obtain annotated feature data that can be used for subsequent intent recognition. The "semantic relevance weight" here refers to the degree of similarity between the feature vector and a preset standard semantic vector. The higher the weight, the more similar the semantics of the feature vector and the standard vector are, so that the user's intent can be inferred more accurately.
[0039] Specifically, the feature vector is a row vector of the semantic relevance matrix generated from step S12, which represents the semantic distribution information of the segmented material in different input types. The preset standard semantic vector is a set of standard vectors pre-set by the system, representing certain specific semantic targets or intent categories. For example, for different intents, the system can generate corresponding standard vectors for each category. It is worth noting that the preset standard semantic vector is a set of vectors used to represent specific semantic categories in the intent recognition system. The main function of the standard vector is to provide a reference for the feature vector input by the user, and to judge the user's intention by calculating the semantic relevance between the feature vector and the standard vector. It can be generated by: generating based on a large-scale corpus training model, generating standard vectors based on a large amount of corpus (such as conversation data, text data, etc.) through machine learning or deep learning models; manually setting or defining based on domain knowledge. In some specific fields, standard vectors can also be manually defined by domain experts. This method is suitable for tasks with fewer semantic categories and high structure.
[0040] According to the calculation formula of the relevance weight, it is obvious that this formula actually calculates the cosine similarity between two vectors. Cosine similarity is widely used in natural language processing because it can measure the similarity of the directions of two vectors without being affected by the length of the vectors. The semantic relevance weight reflects the semantic similarity between the feature vector and the standard semantic vector. In the intent recognition task, this similarity can help the system determine whether the content input by the user is related to a specific standard semantic. The larger the weight, the more the input content conforms to the standard semantic category. After calculating the semantic relevance weights of each feature vector and each preset standard semantic vector, the system will sort these weights. The purpose of sorting is to find the standard semantic vector that best matches the input feature, so as to infer the user's intention. After the sorting is completed, the system will annotate the feature vector to obtain the annotated feature data. The meaning of annotation is to associate the feature vector with the most similar standard semantic category, so that the system can classify the user's input more quickly and accurately in the subsequent intent recognition. Specifically, the role of labeling in this step is to sort each feature vector according to its similarity with the preset standard semantic vector, and associate the sorted results with the feature vector for further processing and recognition by the system. The annotated feature data can help the system quickly determine which feature vectors are closest to a standard semantic category in the subsequent intent recognition or classification process. Based on this sorting result, the system will give priority to the feature vectors with the highest similarity, thereby improving the accuracy of intent recognition.
[0041] In step S14, according to the user account information, a corresponding preset decision tree model is selected, and the preset decision tree model is used to process the annotated feature data to obtain a user intent recognition result. Preferably, according to the user account information, a corresponding preset decision tree model is selected, and the annotated feature data is processed using the preset decision tree model to obtain a user intent recognition result, including: based on the user identity information, user identity category identification is performed; wherein the user identity category is an administrator user, a general user, and a new user; based on the identified user category, a corresponding preset decision tree model is selected, and the annotated feature data is processed using the preset decision tree model to obtain a user intent recognition result; wherein the preset decision tree model has been pre-trained based on user data of different user categories.
[0042] Preferably, the user identity category identification based on the user identity information includes: calculating the account information combination weight based on the user account information and the preset account information weight; wherein the calculation formula of the account information combination weight is: , where Indicates the weight of user account information; Represents the i-th user account information; the user category is identified based on the account information combined weight to obtain the user category. The user identity category identification based on the user identity information also includes: calculating the membership of the user account information based on the membership function according to the user account information; wherein the membership function calculation formula is: In the formula, and Respectively represent the membership of administrator users, general users, and new users; Indicates the weight of user account information; Represents the i-th user account information; is a similarity function that represents the similarity between the user account information and the administrator user information value; Indicates the similarity between user account information and general user information values Represents the similarity between the user account information and the new user information value; Indicates the number of user account information; and performs user category identification according to the membership degree to obtain the user category.
[0043] Specifically, in step S14, the present invention adopts a method of selecting and using a preset decision tree model based on user account information to process the labeled feature data and ultimately identify the user's intention. This process includes two main parts: user category identification based on user account information, and selecting a preset decision tree model according to the user category to process the feature data input by the user and identify the intention. User account information is used as a basis for selecting different decision tree models in the present invention. Different categories of users (such as administrator users, general users, new users) may have different behavior patterns or intentions, so designing different decision tree models for each category of users can improve the accuracy of intention identification.
[0044] In a preferred embodiment, the system first calculates the account information combination weight based on the user's account information, which is the basis for user category identification. The calculation formula for the account information combination weight is: In the formula, Indicates the weight of user account information; Represents the account information of the ith user. By calculating this combined weight, the system can obtain a comprehensive value for measuring the user's identity information. This combined weight can help the system understand the overall characteristics of the user, but it cannot directly output the user category by itself, and still needs to be compared with the preset standard or further processed. Preferably, a simple method for determining the user category is to compare the combined weight with the preset threshold of each user category. It is worth noting that the method for determining the preset threshold can be: based on historical data analysis, by analyzing the account information of existing users and the categories to which they belong, the system can set a reasonable threshold range for each user category. For example, if the weight of administrator users is concentrated above 80, while the weight of general users is concentrated between 50 and 80, and the weight of new users is concentrated below 50, then the system can set: administrator user threshold ≥ 80, general user threshold 50≤wc<80, new user threshold wc<50; based on user behavior patterns, user behavior patterns can also provide references for setting thresholds. Users of different categories usually have different behavioral characteristics and account information, such as registration time, activity, membership level, etc.
[0045] In another preferred embodiment, the user category is determined according to the membership degree. By calculating the membership degree of the user and each category (such as administrator user, general user, new user), the system can determine the user category according to the size of the membership degree. The judgment standard is to select the category with the highest membership degree as the final category of the user. It is worth noting that the membership degree is a measure that indicates the degree to which a user belongs to a certain category. It is determined by calculating the similarity between the user's account information and the preset standard category (such as administrator user, general user, new user). Each category has a corresponding membership degree, and the value is usually between 0 and 1: the higher the membership degree, the closer the user is to the category; the lower the membership degree, the lower the similarity between the user and the category. In general, in the present invention, in the process of user category identification, the calculation of the membership degree is to measure the similarity between the user and different categories. The final user category judgment is based on the size of the membership degree, and the system selects the category with the highest membership degree as the final category of the user. This method can effectively handle complex and fuzzy classification scenarios, so that the system can make more reasonable category judgments based on the real attributes of the user.
[0046] Finally, in the process of user intent recognition, the system will first select the most appropriate decision tree model based on the user's account information. Different types of users (such as administrators, general users, and new users) often have different behavior patterns and intentions when using the system. Therefore, presetting corresponding decision tree models for different categories of users can improve the accuracy of intent recognition. The preset decision tree model is a machine learning model trained by the system based on historical user behavior and data. Each model is optimized for the behavior pattern of a specific user category. Different decision tree models are customized based on user categories. For example: the administrator user decision tree model focuses more on the user's intention in backend management, statistics viewing, and permission operations. The general user decision tree model focuses on identifying the general user's intention in purchasing, browsing products, and querying information. The new user decision tree model is more used to identify the learning and exploration behavior of new users, and provide corresponding guidance and recommendations. Once the system selects the most appropriate decision tree model, it will use the model to process the previously generated annotated feature data. The annotated feature data is generated by the system extracting feature vectors based on the user's input data (such as text, voice, and image) in the previous step, and comparing and sorting with the standard semantic vector. The decision tree model inputs the labeled feature data into its nodes, gradually classifies the data, and finally derives the user's intention. After processing the labeled feature data, the decision tree model outputs an intent recognition result. This result represents the system's view of the user's current operation intention. Intent recognition results can include: query intent, purchase intent, management intent, and exploration intent. It is worth noting that before the system goes online, the decision tree model needs to be trained with a large amount of historical data. During training, the system uses existing user behavior data and combines user account information to build behavior patterns for different categories of users. These data are repeatedly trained to enable the model to accurately judge the intentions of specific categories of users. During the training process, the system will: select appropriate features for splitting; optimize the depth of the tree and the node splitting criteria to avoid overfitting or underfitting; and finally output a decision tree model suitable for different user categories.
[0047] The following describes the working process of the present invention by taking a relatively common scenario as an example. The working process is as follows: In the working process of the present invention, assuming that when a user operates on an e-commerce platform, the system first identifies the user's category, such as "ordinary user", based on the user's account information (such as registration time, membership level, etc.). The system selects a preset decision tree model that matches the category. Then, the user inputs text, voice or image multimedia information, and the system extracts features from the multimedia information to generate feature vectors. Next, the decision tree model processes the annotated feature data and determines the user's intention by analyzing the features of the multimedia information.
[0048] In summary, the present invention provides an intention recognition method based on a large model, including: obtaining user account information and multimedia information input by the user; wherein the multimedia information input types include text, voice and image; wherein the user account information includes user name, membership level and registration date; performing feature extraction on the multimedia information to obtain a feature vector; calculating the semantic relevance weight of the feature vector and sorting it to obtain labeled feature data; according to the user account information, selecting a corresponding preset decision tree model, and using the preset decision tree model to process the labeled feature data to obtain a user intention recognition result.
[0049] In the present invention, the method can significantly improve the accuracy and processing efficiency of intent recognition by effectively extracting key information from multimodal data and combining it with a decision tree model of user account information. By calculating and sorting semantic relevance weights, the method effectively overcomes the limitations of traditional intent recognition methods in processing language diversity and complexity, reduces reliance on artificial feature engineering, and improves the recognition accuracy of user intent in complex scenarios.
[0050] Reference Figure 2 The second embodiment of the present invention provides an intention recognition device based on a large model, comprising: An information acquisition module is used to acquire user account information and multimedia information input by the user; A feature extraction module, used to extract features from the multimedia information to obtain a feature vector; A weight calculation module calculates the semantic relevance weights of the feature vectors and sorts them to obtain labeled feature data; The intention recognition module is used to select a corresponding preset decision tree model according to the user account information, and use the preset decision tree model to process the marked feature data to obtain a user intention recognition result.
[0051] In an optional implementation, the feature extraction module is specifically used to: Based on a preset semantic dictionary, performing a word segmentation operation on the multimedia information to obtain word segmentation materials; According to the segmented data, construct a feature matrix and a semantic matrix; A vector conversion operation is performed according to the feature matrix and the semantic matrix to obtain a feature vector.
[0052] In an optional implementation, the feature extraction module is specifically used to: Multiplying the feature matrix and the semantic matrix to obtain a semantic relevance matrix; The row vector of the semantic relevance matrix is used as the feature vector.
[0053] In an optional implementation, the weight calculation module is specifically used to: According to the feature vector and the preset standard semantic vector, the semantic relevance weight is calculated; wherein the relevance weight calculation formula is: In the formula, A semantic relevance weight representing the feature vector and the preset standard semantic vector; Respectively represent the feature vector and the preset standard semantic vector; represents the vector magnitude; The semantic relevance weights are sorted by size, and the corresponding feature vectors are labeled to obtain labeled feature data after the semantic relevance weights are sorted by size.
[0054] In an optional implementation, the intention recognition module is specifically used to: Based on the user identity information, the user identity category is identified; wherein the user identity category is an administrator user, a general user, and a new user; Based on the identified user category, a corresponding preset decision tree model is selected, and the labeled feature data is processed using the preset decision tree model to obtain a user intent recognition result; wherein the preset decision tree model has been pre-trained based on user data of different user categories.
[0055] In an optional implementation, the intention recognition module is specifically used to: According to the user account information, the account information combination weight is calculated based on the preset account information weight; wherein the calculation formula of the account information combination weight is: In the formula, Indicates the weight of user account information; Represents the i-th user account information; The user category is identified according to the account information combined weight to obtain the user category.
[0056] In an optional implementation, the intention recognition module is specifically used to: According to the user account information, the membership degree of the user account information is calculated based on the membership function; wherein the membership function calculation formula is: In the formula, and Respectively represent the membership of administrator users, general users, and new users; Indicates the weight of user account information; Represents the i-th user account information; is a similarity function that represents the similarity between the user account information and the administrator user information value; Indicates the similarity between user account information and general user information values Represents the similarity between the user account information and the new user information value; Indicates the number of user account information; The user category is identified according to the membership degree to obtain the user category.
[0057] It should be noted that the large model-based intention recognition device provided in an embodiment of the present invention is used to execute all the process steps of the large model-based intention recognition method in the above-mentioned embodiment. The working principles and beneficial effects of the two correspond one to one, and thus will not be elaborated upon.
[0058] The embodiment of the present invention further provides an electronic device. The electronic device includes: a processor, a memory, and a computer program stored in the memory and executable on the processor, such as a program for a method for identifying intentions based on a large model. When the processor executes the computer program, the steps in the above-mentioned embodiments of the method for identifying intentions based on a large model are implemented, such as Figure 1 Alternatively, when the processor executes the computer program, the functions of the modules / units in the above-mentioned device embodiments are implemented, such as the intention recognition module.
[0059] Exemplarily, the computer program may be divided into one or more modules / units, which are stored in the memory and executed by the processor to implement the present invention. The one or more modules / units may be a series of computer program instruction segments capable of implementing specific functions, which are used to describe the execution process of the computer program in the electronic device.
[0060] The electronic device may be a computing device such as a desktop computer, a notebook, a PDA, and a smart tablet. The electronic device may include, but is not limited to, a processor and a memory. Those skilled in the art will appreciate that the above components are merely examples of electronic devices and do not constitute a limitation on the electronic device. The electronic device may include more or fewer components than the above components, or may combine certain components, or different components. For example, the electronic device may also include input and output devices, network access devices, buses, etc.
[0061] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the electronic device, and uses various interfaces and lines to connect various parts of the entire electronic device.
[0062] The memory can be used to store the computer program and / or module, and the processor realizes various functions of the electronic device by running or executing the computer program and / or module stored in the memory, and calling the data stored in the memory. The memory can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area can store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory can include a high-speed random access memory, and can also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.
[0063] Wherein, if the module / unit integrated in the electronic device is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on such an understanding, the present invention implements all or part of the processes in the above-mentioned embodiment method, and can also be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Wherein, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, disk, optical disk, computer memory, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media do not include electric carrier signals and telecommunication signals.
[0064] It should be noted that the device embodiments described above are merely schematic, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. In addition, in the accompanying drawings of the device embodiments provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, which may be specifically implemented as one or more communication buses or signal lines. A person of ordinary skill in the art may understand and implement it without paying any creative effort.
[0065] The specific embodiments described above further illustrate the purpose, technical solutions and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. It is particularly pointed out that for those skilled in the art, any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention should be included in the scope of protection of the present invention.
Claims
1. A method for intention recognition based on a large model, characterized in that: include: Acquire user account information and multimedia information input by the user; wherein the multimedia information input type includes text, voice and image; wherein the user account information includes user name, membership level and registration date; Extracting features from the multimedia information to obtain a feature vector; Calculating the semantic relevance weights of the feature vectors and sorting them to obtain labeled feature data; According to the user account information, a corresponding preset decision tree model is selected, and the preset decision tree model is used to process the annotated feature data to obtain a user intention recognition result.
2. The large model-based intention recognition method according to claim 1, characterized in that: The step of extracting features from the multimedia information to obtain a feature vector includes: Based on a preset semantic dictionary, performing a word segmentation operation on the multimedia information to obtain word segmentation materials; According to the segmented data, construct a feature matrix and a semantic matrix; A vector conversion operation is performed according to the feature matrix and the semantic matrix to obtain a feature vector.
3. The method for identifying intentions based on a large model according to claim 2, characterized in that: The characteristic matrix is specifically an m*n matrix; Wherein, m is the number of the segmented data, and n is the number of the multimedia information input types; Wherein, each element of the feature matrix is Aij, wherein i represents the segmentation material, and j represents the multimedia information input type; The value condition of Aij is: judging whether the word segment material i appears in the multimedia information input type j, if so, the corresponding element Aij takes a value of 1; if not, the corresponding element Aij takes a value of 0.
4. The method for identifying intentions based on a large model according to claim 2, characterized in that: The semantic matrix is specifically an m*m matrix; Wherein, m is the number of the segmented data; Wherein, each element Sxy of the semantic matrix represents the semantic similarity between the segmented text x and the segmented text y; The calculation formula of the semantic similarity is: In the formula, Indicates the semantic similarity between segmented data and segmented data; Indicates the semantic similarity between segmented data x and segmented data j; It represents the semantic similarity between the segmented data y and the segmented data x.
5. The intention recognition method based on a large model according to claim 2 is characterized in that: The step of performing a vector conversion operation according to the feature matrix and the semantic matrix to obtain a feature vector includes: Multiplying the feature matrix and the semantic matrix to obtain a semantic relevance matrix; The row vector of the semantic relevance matrix is used as the feature vector.
6. The method for intention recognition based on a large model according to claim 1, characterized in that: The calculating the semantic relevance weights of the feature vectors and sorting them to obtain the labeled feature data includes: According to the feature vector and the preset standard semantic vector, the semantic relevance weight is calculated; wherein the relevance weight calculation formula is: In the formula, A semantic relevance weight representing the feature vector and the preset standard semantic vector; Respectively represent the feature vector and the preset standard semantic vector; represents the vector magnitude; The semantic relevance weights are sorted by size, and the corresponding feature vectors are labeled to obtain labeled feature data after the semantic relevance weights are sorted by size.
7. The method for intention recognition based on a large model according to claim 1, characterized in that: The selecting a corresponding preset decision tree model according to the user account information, and using the preset decision tree model to process the annotated feature data to obtain a user intention recognition result includes: Based on the user identity information, the user identity category is identified; wherein the user identity category is an administrator user, a general user, and a new user; Based on the identified user category, a corresponding preset decision tree model is selected, and the labeled feature data is processed using the preset decision tree model to obtain a user intent recognition result; wherein the preset decision tree model has been pre-trained based on user data of different user categories.
8. The method for intention recognition based on a large model according to claim 7, characterized in that: The user identity category identification based on the user identity information includes: According to the user account information, the account information combination weight is calculated based on the preset account information weight; wherein the calculation formula of the account information combination weight is: In the formula, Represents the combined weight of account information, Indicates the weight of user account information; Represents the i-th user account information; The user category is identified according to the account information combined weight to obtain the user category.
9. The method for intention recognition based on a large model according to claim 7, characterized in that: The identifying the user identity category based on the user identity information further includes: According to the user account information, the membership degree of the user account information is calculated based on the membership function; wherein the membership function calculation formula is: In the formula, and Respectively represent the membership of administrator users, general users, and new users; Indicates the weight of user account information; Represents the i-th user account information; Is a similarity function that represents the similarity between the user account information and the administrator user information value Indicates the similarity between user account information and general user information values Represents the similarity between the user account information and the new user information value; Indicates the number of user account information; The user category is identified according to the membership degree to obtain the user category.
10. An intention recognition device based on a large model, characterized in that: include: An information acquisition module is used to acquire user account information and multimedia information input by the user; A feature extraction module, used to extract features from the multimedia information to obtain a feature vector; A weight calculation module calculates the semantic relevance weights of the feature vectors and sorts them to obtain labeled feature data; The intention recognition module is used to select a corresponding preset decision tree model according to the user account information, and use the preset decision tree model to process the marked feature data to obtain a user intention recognition result.
Citation Information
Patent Citations
Method and system for classifying and predicting user behaviors
CN107818344A
Intention recognition method and device
CN113722492A
Intention recognition method and device, computer equipment and computer readable storage medium
CN114678014A
Customized website predictions for machine-learning systems
US20180114139A1
Cited By
Automatic driving control method and system based on artificial intelligence
CN119472467A