Tool capability classification method and device, storage medium and computer program product
Through the multi-scale capsule network and sparse coding module combined with neural network model, the problem of low accuracy of tool classification in the existing technology is solved, and more efficient tool capability classification is achieved.
Patent Information
- Application Number
- CN202410129426.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-01-30
- Publication Date
- 2025-08-01
AI Technical Summary
The existing classification methods or classification models have low classification accuracy for tools, especially when using convolutional neural networks, which lacks deep feature extraction capabilities, resulting in high data volatility and inability to effectively analyze nonlinear data.
Multi-scale capsule network module is used to extract multi-scale features, combined with sparse coding module and neural network model, and introduced into the capsule network through sparse coding rules to classify tool capabilities.
It improves the accuracy of tool capability classification, reduces training iteration time, and enhances the ability to extract local and global feature of text data.
Smart Images

Figure CN120409556A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of artificial intelligence technology, and in particular, to a method, device, storage medium, and computer program product for classifying tool capabilities. Background Art
[0002] With the rapid development of artificial intelligence technology, classification processing can be performed through the use of classification methods or classification models in many application scenarios. For example, when classifying tools such as AI (Artificial Intelligence) tools, classification methods or classification models are used to determine the classification information of the tools. The classification methods can be methods such as the feature condition independent hypothesis method and the decision tree clustering method, which usually adopt certain rules for data clustering. The disadvantage is that the data volatility is large and non-linear data analysis cannot be considered. Classification models usually use neural network models and have the ability to extract feature information from a large amount of data; the neural network models are usually convolutional neural network (Convolutional Neural Network, CNN) models, and the convolutional neural network models lack the ability to deeply extract feature data. Therefore, the existing classification methods or classification models have relatively low accuracy for classification. Summary of the Invention
[0003] In view of this, a technical problem to be solved by the present invention is to provide a method, device, storage medium, and computer program product for classifying tool capabilities.
[0004] According to a first aspect of the present disclosure, there is provided a method for classifying tool capabilities, including: performing multi-scale feature extraction processing on the ability description text information of a tool by using a multi-scale capsule network module to obtain a first feature vector; obtaining the second feature vector by using a sparse coding module and based on the first feature vector; and obtaining the ability classification result information of the tool by using a neural network model and based on the second feature vector.
[0005] Optionally, the performing multi-scale feature extraction processing on the ability description text information of a tool by using a multi-scale capsule network module to obtain a first feature vector includes: performing multi-scale feature extraction processing on the ability description text information by using the multi-scale capsule network module and the convolution kernels of multiple convolution templates to obtain multiple feature information; and encoding the multiple feature information by using the capsule network module to obtain the first feature vector.
[0006] Optionally, the multi-scale capsule network module includes: a plurality of low-level capsules and high-level capsules; the encoding of the plurality of feature information by using the capsule network module to obtain the first feature vector includes: processing the plurality of feature information by using the plurality of low-level capsules to obtain a plurality of low-level capsule feature information; obtaining a plurality of prediction vectors based on the plurality of low-level capsule feature information and corresponding affine matrices; performing weighted summation processing on the plurality of prediction vectors according to the coupling coefficient to obtain an input vector; using an activation function to perform compression processing on the input vector, and inputting the compression processing result into the high-level capsule, so that the high-level capsule outputs the first feature vector based on the compression processing result; wherein, the coupling coefficient is updated based on the first feature vector by using a dynamic routing algorithm.
[0007] Optionally, the obtaining of the second feature vector by using the sparse coding module and based on the first feature vector includes: performing low-dimensional space feature extraction processing on the first feature vector by using the sparse coding model of the sparse coding module and based on a sparse coding matrix to obtain the second feature vector.
[0008] Optionally, the neural network model includes: a convolutional layer, a pooling layer, and a softmax classifier; the processing of the second feature vector by using the neural network model to obtain a classification result for the ability data includes: using the convolutional layer and the pooling layer to perform feature extraction and fusion processing on the second feature vector, and inputting the processing result into the softmax classifier; obtaining the ability classification result information according to the result output by the softmax classifier.
[0009] Optionally, evaluation index information is determined based on the ability classification result information; the classification result is evaluated according to the evaluation index information; wherein, the evaluation index includes at least one of the following: an accuracy index, a precision index, a recall index, and a comprehensive index of precision and recall.
[0010] Optionally, the tool includes: an artificial intelligence (AI) tool; the ability description text information of the tool includes: the ability description text information of the AI tool.
[0011] According to a second aspect of the present disclosure, there is provided a tool ability classification device, including: a first feature mining module, configured to perform multi-scale feature extraction processing on the ability description text information of the tool by using a multi-scale capsule network module to obtain a first feature vector; a second feature mining module, configured to obtain the second feature vector by using a sparse coding module and based on the first feature vector; and a classification result obtaining module, configured to obtain ability classification result information for the tool by using a neural network model and based on the second feature vector.
[0012] Optionally, the first feature mining module includes: a feature extraction unit configured to perform multi-scale feature extraction processing on the ability description text information by using the multi-scale capsule network module and convolutional kernels of multiple convolutional templates, to obtain multiple pieces of feature information; and a feature encoding unit configured to encode the multiple pieces of feature information by using the capsule network module to obtain the first feature vector.
[0013] Optionally, the multi-scale capsule network module includes: a plurality of low-level capsules and high-level capsules; the feature encoding unit is configured to process the multiple pieces of feature information by using the plurality of low-level capsules to obtain multiple pieces of low-level capsule feature information; obtain multiple prediction vectors based on the multiple pieces of low-level capsule feature information and corresponding affine matrices; perform weighted summation processing on the multiple prediction vectors according to a coupling coefficient to obtain an input vector; perform compression processing on the input vector by using an activation function and input the compression processing result into the high-level capsule, so that the high-level capsule outputs the first feature vector based on the compression processing result; wherein the coupling coefficient is updated by using a dynamic routing algorithm based on the first feature vector.
[0014] Optionally, the second feature mining module is configured to perform low-dimensional space feature extraction processing on the first feature vector by using the sparse coding model of the sparse coding module and based on a sparse coding matrix to obtain the second feature vector.
[0015] Optionally, the neural network model includes: a convolutional layer, a pooling layer, and a softmax classifier; the classification result obtaining module is configured to perform feature extraction and fusion processing on the second feature vector by using the convolutional layer and the pooling layer, and input the processing result into the softmax classifier; and obtain the ability classification result information according to the result output by the softmax classifier.
[0016] Optionally, the classification evaluation module is configured to determine evaluation index information based on the ability classification result information; evaluate the classification result according to the evaluation index information; wherein the evaluation index includes at least one of the following: an accuracy rate index, a precision index, a recall rate index, and a comprehensive index of precision and recall rate.
[0017] According to a third aspect of the present disclosure, there is provided a tool ability classification device, including: a memory; and a processor coupled to the memory, the processor being configured to execute the method as described above based on instructions stored in the memory.
[0018] According to a fourth aspect of the present disclosure, there is provided a computer-readable storage medium storing computer instructions, and the instructions are executed by a processor to perform the method as described above.
[0019] According to a fifth aspect of the present disclosure, there is provided a computer program product including a computer program, characterized in that when the computer program is executed by a processor, it implements the steps of the method described above.
[0020] The tool ability classification method, device, storage medium and computer program product of the present disclosure perform multi-scale feature extraction processing using a multi-scale capsule network module, and obtain feature vectors using a sparse coding module. The ability classification result information of the tool is obtained through a neural network model based on the feature vectors. By introducing sparse coding rules into the capsule network to classify tool abilities, the training iteration time can be reduced, the extraction ability of local and global features of text data can be improved, and the classification accuracy can be improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] By describing the embodiments of the present disclosure in more detail in conjunction with the accompanying drawings, the above and other objects, features and advantages of the present disclosure will become more obvious. The accompanying drawings are used to provide a further understanding of the embodiments of the present disclosure, and constitute a part of the specification. They are used to explain the present disclosure together with the embodiments of the present disclosure, and do not constitute a limitation to the present disclosure. The above and other objects and advantages of the present disclosure will be further described below in conjunction with specific embodiments and with reference to the accompanying drawings. In the drawings, the same or corresponding technical features or components will be represented by the same or corresponding reference numerals.
[0022] Figure 1 It is a schematic flowchart of an embodiment of the tool ability classification method according to the present disclosure;
[0023] Figure 2 It is a schematic flowchart of obtaining a first feature vector in an embodiment of the tool ability classification method according to the present disclosure;
[0024] Figure 3 It is an application schematic diagram of an embodiment of the tool ability classification method according to the present disclosure;
[0025] Figure 4 It is a schematic diagram of the multi-scale capsule network module;
[0026] Figure 5 It is a schematic diagram of the modules of an embodiment of the tool ability classification device according to the present disclosure;
[0027] Figure 6 It is a schematic diagram of the modules of another embodiment of the tool ability classification device according to the present disclosure;
[0028] Figure 7 It is a schematic diagram of the modules of the first feature mining module in an embodiment of the tool ability classification device according to the present disclosure;
[0029] Figure 8 It is a schematic diagram of modules for another embodiment of the tool capability classification device according to the present disclosure. Detailed implementation manners
[0030] In the following, exemplary embodiments of the present disclosure will be described in conjunction with the accompanying drawings. For clarity and conciseness, not all features of the embodiments are described in the specification. However, it should be understood that many implementation-specific settings must be made during the implementation of the embodiments to achieve the specific goals of the developer, for example, to comply with those restrictions related to the device and the business, and these restrictions may vary with different implementations. In addition, it should also be understood that although the development work may be very complex and time-consuming, for those skilled in the art who benefit from the present disclosure, such development work is merely a routine task.
[0031] It should be noted that: Unless otherwise specifically stated, the relative arrangements, numerical expressions, and numerical values of the components and steps set forth in these embodiments do not limit the scope of the present disclosure.
[0032] Those skilled in the art can understand that the terms "first", "second", etc. in the embodiments of the present disclosure are only used to distinguish different steps, devices, or modules, etc., and neither represent any specific technical meaning nor indicate an inevitable logical order between them.
[0033] It should also be understood that in the embodiments of the present disclosure, "a plurality of" may refer to two or more, and "at least one" may refer to one, two, or more.
[0034] It should also be understood that for any component, data, or structure mentioned in the embodiments of the present disclosure, without clear limitation or contrary indication in the context, it can generally be understood as one or more.
[0035] In addition, the term "and / or" in the present disclosure is merely a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in the present disclosure generally represents an "or" relationship between the associated objects before and after.
[0036] It should also be understood that the present disclosure emphasizes the differences between the various embodiments, and their similarities or similarities can be referred to each other. For the sake of brevity, they will not be described one by one.
[0037] At the same time, it should be understood that for the sake of description, the sizes of the various parts shown in the drawings are not drawn according to the actual proportional relationship.
[0038] The following description of at least one exemplary embodiment is merely illustrative and is in no way a limitation on the present disclosure, its application, or its use.
[0039] Technologies, methods, and devices known to those of ordinary skill in the relevant art may not be discussed in detail, but where appropriate, such technologies, methods, and devices should be considered as part of the specification.
[0040] It should be noted that like reference numerals and letters denote like items in the following figures, and thus, once an item is defined in one figure, further discussion thereof is not required in subsequent figures.
[0041] In addition, to avoid obscuring the present disclosure with unnecessary details, only the processing steps and / or device structures closely related to the solution according to the present disclosure are shown in the figures, while other details less related to the present disclosure are omitted. It should also be noted that like reference numerals and letters in the figures indicate like items, and thus once an item is defined in one figure, further discussion thereof is not required for subsequent figures.
[0042] Figure 1 FIG. is a schematic flowchart of an embodiment of a method for classifying tool capabilities according to the present disclosure, as Figure 1 shown:
[0043] Step 101, perform multi-scale feature extraction processing on the text information of the tool's capability description using a multi-scale capsule network module to obtain a first feature vector.
[0044] In some embodiments, the tool can be various tools, such as AI tools, etc.; AI tools are software tools using artificial intelligence technology, etc., and AI tools can be used for intelligent processing such as demand assessment, resource allocation, electricity bill management, etc.
[0045] The capsule network (Capsule Network, CapsNet) can better model the hierarchical relationship of internal knowledge representation in the neural network. The capsule network can use the probability of the existence of the information encoded by the vector to predict the probability of the existence of data features. Through the multi-scale capsule network module, information in different time domains and spatial domains can be extracted. The multi-scale capsule network module can adopt the method of multi-scale feature extraction to perform multi-scale feature extraction processing on the text information of the tool's capability description; by using the multi-scale feature extraction method to mine the multi-dimensional feature relationship of the data, the number of parameters can be reduced, and the feature expression ability can be increased.
[0046] Step 102, use the sparse coding module and based on the first feature vector, obtain a second feature vector.
[0047] In some embodiments, the sparse coding algorithm is an unsupervised learning method. The sparse coding module may apply an existing sparse coding algorithm to process the first feature vector and output a second feature vector, where the second feature vector is a sparse vector.
[0048] Step 103: Obtain capability classification result information of the tool through the neural network model based on the second eigenvector.
[0049] In some embodiments, multiple neural network models can be used to process the second eigenvector to obtain tool capability classification information. The classification information of the AI tool can be used to indicate the category to which the AI tool belongs. The categories can include demand assessment, resource allocation, electricity cost management, and other categories in multiple scenarios. The multiple scenarios can include cloud network planning, service provisioning, network and service quality optimization, and other scenarios.
[0050] Based on the capability classification results of AI tools, an intelligent asset warehouse can be established to provide a unified AI capability view, which can quickly match the needs of AI tool capabilities, solve the fragmentation problem of AI tool capabilities, improve the reuse rate of AI tool capabilities, and reduce development costs.
[0051] Existing convolutional neural networks lack the ability to deeply extract and enhance feature data, and features cannot be reused at multiple levels. Using a sparse coding module can use "super-complete" basis vectors to represent the original data, increasing the ability to capture features and making the encoded data present a super-Gaussian distribution. The multi-scale capsule network module can reduce the number of parameters and increase the expressiveness of features. The tool capability classification method disclosed in the present invention can use a multi-scale capsule network module to perform multi-scale feature extraction processing on the tool capability description text information and use a sparse coding module to obtain feature vectors. By introducing sparse coding rules into the capsule network to classify tool capabilities, the training iteration time can be reduced, the ability to extract local and global features of text data is improved, and the accuracy of classification is improved.
[0052] Figure 2 FIG. 1 is a flow chart of obtaining a first feature vector in an embodiment of a tool capability classification method according to the present disclosure, as shown in FIG. Figure 2 As shown:
[0053] In step 201 , a multi-scale capsule network module is used and convolution kernels of multiple convolution templates are used to perform multi-scale feature extraction processing on the capability description text information to obtain multiple feature information.
[0054] In some embodiments, as Figure 3As shown, the multi-scale capsule network module and the sparse coding module constitute the feature fine classification part; the neural network model is the feature rough classification part, and the neural network model further captures local text semantic information and global text semantic information.
[0055] A single-scale convolutional kernel can only extract feature information of one score. Input the ability description text information into the multi-scale capsule network module. The multi-scale capsule network module includes a convolutional layer (not shown in the figure). The convolutional layer presets multiple convolutional templates, and the multiple convolutional templates have different convolutional scales; through the convolutional layer and using the convolutional kernels of multiple convolutional templates, multi-scale feature extraction processing can be performed on the ability description text information to obtain multiple feature information, that is, multiple feature vectors.
[0056] Step 202, use the capsule network module to encode multiple feature information to obtain a first feature vector.
[0057] In some embodiments, as Figure 4 shown, the multi-scale capsule network module includes multiple low-level capsules 41 and high-level capsules 42; use the multiple low-level capsules 41 to process multiple feature information to obtain multiple low-level capsule feature information. Based on the multiple low-level capsule feature information and the corresponding affine matrix, multiple prediction vectors are obtained.
[0058] Perform weighted summation processing on multiple prediction vectors according to the coupling coefficient to obtain an input vector; use an activation function to compress the input vector, and input the compression processing result into the high-level capsule 42. The high-level capsule 42 outputs the first feature vector, that is, the high-level capsule 42 processes the compression processing result to obtain the first feature vector. The coupling coefficient can be updated based on the first feature vector and using the dynamic routing algorithm.
[0059] For example, summarize the ability information of AI tools in each province of a certain company to generate the ability description text information of A1 tool. The ability description text information includes: AI tool ability description, metrics and other information.
[0060] Input the ability description text information into the multi-scale capsule network module. Through the convolutional layer of the multi-scale capsule network module and using the convolutional kernels of multiple convolutional templates, perform multi-scale feature extraction processing on the ability description text information to obtain multiple feature information. Multiple low-level capsules 41 process multiple feature information to obtain multiple low-level capsule feature information u i . The multiple low-level capsule feature information are multiple low-level capsule feature vectors.
[0061] The multi-scale capsule network module converts all neurons into vector outputs with directions. The length of the vector represents the probability of the presence of the target, and the direction of the vector represents the characteristics of the target. Finally, the information is encapsulated and output in the form of capsules. During the process of converting low-level capsules into high-level capsules, scalar non-linear processing can be performed to establish the corresponding relationship between different capsules. During this process, the weight is updated through the dynamic routing algorithm.
[0062] Multiply the feature information of multiple low-level capsules and the corresponding affine matrix to obtain multiple prediction vectors. The calculation formula is as follows:
[0063] u j|i =W ij u i (1);
[0064] Among them, u i represents the low-level capsule feature information output by the low-level capsule, i = 1, 2,..., n, where n is the number of low-level capsules; W ij represents the affine matrix representing the positional relationship; u j|i represents the output prediction vector.
[0065] Perform weighted summation processing on multiple prediction vectors according to the coupling coefficient to obtain the input vector s j , and the calculation formula is as follows:
[0066] s j =∑ i c ij u j|i (2);
[0067] Among them, c ij is the coupling coefficient, satisfying ∑ i c ij =1; c ij is obtained through the update factor b ij , and the update formula of c ij is as follows:
[0068]
[0069] Use the activation function to compress the input vector, dynamically compress the input vector into the interval (0, 1), and the activation function can be a non-linear activation function such as the squash function, etc.; input the compression result into the high-level capsule, and output the first feature vector through the high-level capsule. The calculation formula is as follows:
[0070]
[0071] Among them, v j is the first feature vector, and j is the number of the first feature vector and the high-level capsule.
[0072] Update the coupling coefficient based on the first eigenvector and using a dynamic routing algorithm. For example, use the dynamic routing algorithm to update b ij and c ij , the formula is as follows:
[0073] b ij = b ij + v j u j|i (5);
[0074] Among them, b ij represents the logarithmic prior probability, and the initial value is set to 0.
[0075] In some embodiments, a sparse coding model is provided in the sparse coding module. Using the sparse coding model of the sparse coding module and based on the sparse coding matrix, perform low-dimensional space feature extraction processing on the first eigenvector to obtain a second eigenvector. The sparse coding matrix contains fewer non-zero terms, has higher computational efficiency, and better classification effect. The sparse coding algorithm applied by the sparse coding model is:
[0076]
[0077] Among them, X is the input first eigenvector; A i is the convolution feature corresponding to the i-th filter; λ is the regularization parameter; D is a circulant matrix, that is, the sparse coding matrix.
[0078] Using the sparse coding module can express the information in the low-dimensional space in an encoded form, and use the sparsity of the features to represent the potential low-dimensional space of the target text, and more representative text features can be extracted.
[0079] In some embodiments, as Figure 3 shown, the neural network model includes a convolutional layer, a pooling layer, and a softmax classifier, etc. Use the convolutional layer and the pooling layer to perform feature extraction and fusion processing on the second eigenvector, and input the processing result into the softmax classifier; according to the result output by the softmax classifier, obtain the ability classification result information. Through the ability classification result information, the content in the ability description text information of AI tools, etc. can be mapped to multiple ability classifications.
[0080] In some embodiments, multiple methods can be adopted to train the multi-scale capsule network module, the sparse coding module, and the neural network model. For example, obtain the training text information of the ability description of the tool, annotate the training text information of the ability description, construct a training set, and construct a loss function. Conduct iterative training. For the training text information of the ability description in the training set, use the multi-scale capsule network module to perform multi-scale feature extraction processing to obtain a first feature vector; input the first feature vector into the sparse coding module to obtain a second feature vector, and process the second feature vector through the neural network model to obtain the ability classification result information.
[0081] Based on the ability classification result information and the annotation information of the training text information of the ability description in the training set, determine the value of the loss function, and adjust the parameters of the multi-scale capsule network module, the sparse coding module, and the neural network model based on the value of the loss function; when the value of the loss function is less than the preset loss threshold, it is determined that the training is over, and the parameters of the multi-scale capsule network module, the sparse coding module, and the neural network model are determined.
[0082] In some embodiments, based on the ability classification result information, determine the evaluation index information, and evaluate the classification result according to the evaluation index information. The evaluation index includes at least one of the following: accuracy index, precision index, recall index, comprehensive index of precision and recall, etc.
[0083] For example, the evaluation index includes: accuracy (Accuracy, A), precision (Precision, P), recall (Recall, R), and F1 value index, where the F1 value represents the comprehensive index of precision and recall. The formulas for calculating the values of the accuracy index, precision index, recall index, comprehensive index of precision and recall, etc. are as follows:
[0084]
[0085]
[0086]
[0087]
[0088] Among them, TP represents the number of samples where the prediction and the actual are both positive classes, TN represents the number of samples where the prediction and the actual are both negative classes; FN represents the number of samples where the actual is positive and the prediction is negative, and FP represents the number of samples where the actual is negative and the prediction is positive.
[0089] The data set for evaluation is shown in Table 1 below:
[0090]
[0091]
[0092] Table 1 - Dataset for evaluation
[0093] In some embodiments, the tool capability classification method of the present disclosure can be compared with several other algorithms to verify the classification accuracy of the tool capability classification method of the present disclosure for the text information of the tool's capability description. The several other algorithms include: Bert (Bidirectional Encoder Representations from Transformers, a bidirectional encoding representation algorithm based on the Transformer algorithm), TextCNN (Text Convolutional Neural Networks), LSTM (Long Short-Term Memory), etc.; among them, the Bert algorithm has huge parameters and is pre-trained in large-scale semantic texts, and its learning ability is insufficient; the TextCNN algorithm has the problems of weak model interpretability, and the convolutional operation can only capture a single convolutional kernel size, and its classification effect is not good; the parallel processing data effect of the LSTM algorithm is not good, and the processing of longer sequence data is limited.
[0094] Based on the dataset in Table 1 above, the Bert algorithm, TextCNN algorithm, LSTM algorithm, and the tool capability classification method of the present disclosure are respectively used for testing, and the experimental results are shown in Table 2 below.
[0095] Classification method A P R <![CDATA[F1]]> Bert algorithm 85.5% 80.2% 80.6% 0.79 TextCNN algorithm 88.2% 79.2% 78.8% 0.73 LSTM algorithm 88.9% 86.9% 83.2% 0.88 The classification method of the present invention 90.5% 88.4% 87.3% 0.91
[0096] Table 2 - Comparison table of verification results of various classification methods
[0097] As can be seen from Table 2 above, the tool capability classification method of the present disclosure has the highest accuracy. Compared with algorithms such as Bert, TextCNN, and LSTM, the classification accuracy is increased by 5.8%, 2.6%, and 1.8% respectively. Thus, it can be seen that the tool capability classification method of the present disclosure has higher classification accuracy for the text information of the tool's capability description.
[0098] In one embodiment, as Figure 5As shown in the figure, the present disclosure provides a tool capability classification device 50, including a first feature mining module 51, a second feature mining module 52, and a classification result obtaining module 53. The first feature mining module 51 performs multi-scale feature extraction processing on the capability description text information of the tool by using a multi-scale capsule network module to obtain a first feature vector. The second feature mining module 52 uses a sparse coding module and based on the first feature vector to obtain a second feature vector. The classification result obtaining module 53 obtains the capability classification result information of the tool through a neural network model and based on the second feature vector.
[0099] In some embodiments, the second feature mining module 52 uses the sparse coding model of the sparse coding module and based on the sparse coding matrix to perform low-dimensional space feature extraction processing on the first feature vector to obtain a second feature vector.
[0100] The neural network model includes a convolutional layer, a pooling layer, and a softmax classifier, etc.; the classification result obtaining module 53 uses the convolutional layer and the pooling layer to perform feature extraction and fusion processing on the second feature vector, and inputs the processing result into the softmax classifier; the classification result obtaining module 53 obtains the capability classification result information according to the result output by the softmax classifier.
[0101] As Figure 6 shown in the figure, the tool capability classification device 50 includes a classification evaluation module 54. The classification evaluation module 54 determines evaluation index information based on the capability classification result information and evaluates the classification result according to the evaluation index information.
[0102] As Figure 7 shown in the figure, the first feature mining module 51 includes: a feature extraction unit 511 and a feature encoding unit 512. The feature extraction unit 511 uses a multi-scale capsule network module and the convolutional kernels of multiple convolutional templates to perform multi-scale feature extraction processing on the capability description text information to obtain multiple feature information. The feature encoding unit 512 uses the capsule network module to encode the multiple feature information to obtain a first feature vector.
[0103] The multi-scale capsule network module includes multiple low-level capsules and high-level capsules; the feature encoding unit 512 uses the multiple low-level capsules to process the multiple feature information to obtain multiple low-level capsule feature information; the feature encoding unit 512 obtains multiple prediction vectors based on the multiple low-level capsule feature information and the corresponding affine matrix.
[0104] The feature encoding unit 512 performs a weighted summation process on a plurality of prediction vectors according to the coupling coefficient to obtain an input vector; the feature encoding unit 512 compresses the input vector using an activation function and inputs the result of the compression process into the high-level capsule, so that the high-level capsule outputs a first feature vector based on the result of the compression process, wherein the feature encoding unit 512 updates the coupling coefficient based on the first feature vector and using a dynamic routing algorithm.
[0105] In some embodiments, as Figure 8 shown, the present disclosure provides a tool capability classification device, which may include a memory 62, a processor 61, a communication interface 63, and a bus 64. The memory 62 is used to store instructions, the processor 61 is coupled to the memory 62, and the processor 61 is configured to execute the tool capability classification method described above based on the instructions stored in the memory 62.
[0106] The memory 62 may be a high-speed RAM memory, a non-volatile memory, etc., and the memory 62 may also be a memory array. The memory 62 may also be partitioned, and the blocks may be combined into virtual volumes according to certain rules. The processor 61 may be a central processing unit CPU, or an application specific integrated circuit ASIC (Application Specific Integrated Circuit), or one or more integrated circuits configured to implement the tool capability classification method of the present disclosure.
[0107] In some embodiments, the present disclosure provides a computer-readable storage medium storing computer instructions, which when executed by a processor implement the method in any one of the above embodiments.
[0108] The computer-readable storage medium may adopt any combination of one or more readable media. The readable media may be a readable signal medium or a readable storage medium. The readable storage medium may, for example, include but is not limited to an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. More specific examples (non-exhaustive listing) of the readable storage medium may include: an electrical connection having one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0109] Embodiments of the present disclosure may also be computer program products, which include computer program instructions that, when run by a processor, cause the processor to execute the steps in the methods according to various embodiments of the present disclosure described in the "Exemplary Methods" section of this specification.
[0110] The tool ability classification method, device, storage medium, and computer program product in the above embodiments perform multi-scale feature extraction processing using a multi-scale capsule network module, obtain feature vectors using a sparse coding module, and obtain the ability classification result information for the tool through a neural network model based on the feature vectors. By introducing the sparse coding rule into the capsule network to classify the tool ability, the training iteration time can be reduced, the extraction ability of local features and global features of text data can be improved, the classification accuracy can be improved, and the user experience can be enhanced.
[0111] The basic principles of the present disclosure have been described above in conjunction with specific embodiments. However, it should be noted that the advantages, benefits, effects, etc. mentioned in the present disclosure are only examples and not limitations, and it cannot be considered that these advantages, benefits, effects, etc. are essential for each embodiment of the present disclosure. In addition, the specific details disclosed above are only for illustrative and facilitating understanding purposes, rather than limitations, and the above details do not limit the present disclosure to necessarily adopt the above specific details for implementation.
[0112] Each embodiment in this specification is described in a progressive manner, and the key point of each embodiment is to illustrate the differences from other embodiments. The same or similar parts among the embodiments can be referred to each other. For system embodiments, since they basically correspond to method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiments.
[0113] The block diagrams of the devices, apparatuses, equipment, and systems involved in the present disclosure are only illustrative examples and do not intend to require or imply that they must be connected, arranged, and configured in the manner shown in the block diagrams. As those skilled in the art will recognize, these devices, apparatuses, equipment, and systems can be connected, arranged, and configured in any manner. Words such as "including", "comprising", "having", etc. are open-ended terms, meaning "including but not limited to", and can be used interchangeably with each other. The word "or" and "and" used herein refer to the word "and / or" and can be used interchangeably with each other, unless the context clearly indicates otherwise. The word "such as" used herein refers to the phrase "such as but not limited to" and can be used interchangeably with each other.
[0114] It should also be noted that in the devices, equipment, and methods of the present disclosure, each component or each step can be decomposed and / or recombined. These decompositions and / or recombinations should be regarded as equivalent solutions of the present disclosure.
[0115] The foregoing description of the disclosed aspects is provided to enable any person skilled in the art to make or use the present disclosure. Various modifications to these aspects will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to other aspects without departing from the scope of the present disclosure. Thus, the present disclosure is not intended to be limited to the aspects shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
[0116] The foregoing description has been presented for purposes of illustration and description. In addition, this description is not intended to limit the embodiments of the present disclosure to the forms disclosed herein. Although several example aspects and embodiments have been discussed above, those skilled in the art will appreciate that the foregoing embodiments are illustrative only and do not limit the scope of the present disclosure. Those skilled in the art should understand that the foregoing embodiments may be combined, modified, or substituted without departing from the scope and spirit of the present disclosure.
Claims
1. A method for classifying tool capabilities, comprising: Performing multi-scale feature extraction processing on the text information of the tool's capability description using a multi-scale capsule network module to obtain a first feature vector; Using a sparse coding module and based on the first feature vector, obtaining the second feature vector; Obtaining the capability classification result information for the tool through a neural network model and based on the second feature vector.
2. The method according to claim 1, wherein The performing multi-scale feature extraction processing on the text information of the tool's capability description using a multi-scale capsule network module to obtain a first feature vector includes: Using the multi-scale capsule network module and the convolutional kernels of multiple convolutional templates to perform multi-scale feature extraction processing on the text information of the capability description to obtain multiple feature information; Using the capsule network module to encode the multiple feature information to obtain the first feature vector.
3. The method according to claim 2, wherein, The multi-scale capsule network module includes: multiple low-level capsules and high-level capsules; the using the capsule network module to encode the multiple feature information to obtain the first feature vector includes: Using the multiple low-level capsules to process the multiple feature information to obtain multiple low-level capsule feature information; Based on the multiple low-level capsule feature information and the corresponding affine matrix, obtaining multiple prediction vectors; Performing weighted summation processing on the multiple prediction vectors according to the coupling coefficient to obtain an input vector; Using an activation function to perform compression processing on the input vector and inputting the compression processing result into the high-level capsule, so that the high-level capsule outputs the first feature vector based on the compression processing result; Wherein, the coupling coefficient is updated based on the first feature vector and using a dynamic routing algorithm.
4. The method according to claim 1, wherein, The using a sparse coding module and based on the first feature vector, obtaining the second feature vector includes: Using the sparse coding model of the sparse coding module and based on a sparse coding matrix, performing low-dimensional space feature extraction processing on the first feature vector to obtain the second feature vector.
5. The method according to claim 1, wherein, The neural network model includes: a convolutional layer, a pooling layer, and a softmax classifier; the obtaining the classification result for the capability data by processing the second feature vector through the neural network model includes: Using the convolutional layer and the pooling layer to perform feature extraction and fusion processing on the second feature vector, and inputting the processing result into the softmax classifier; Obtaining the capability classification result information according to the result output by the softmax classifier.
6. The method according to claim 1, further comprising: Determining evaluation index information based on the capability classification result information; Evaluating the classification result according to the evaluation index information; Wherein, the evaluation index includes at least one of the following: accuracy index, precision index, recall rate index, and comprehensive index of precision and recall rate.
7. The method according to any one of claims 1 to 6, wherein The tool includes: an artificial intelligence AI tool; The text information of the tool's capability description includes: the text information of the AI tool's capability description.
8. A tool capability classification device, comprising: The first feature mining module is used to perform multi-scale feature extraction processing on the ability description text information of the tool by using a multi-scale capsule network module to obtain a first feature vector; The second feature mining module is used to obtain the second feature vector by using a sparse coding module and based on the first feature vector; The classification result obtaining module is used to obtain the ability classification result information of the tool through a neural network model and based on the second feature vector.
9. The device according to claim 8, wherein, The first feature mining module includes: The feature extraction unit is used to perform multi-scale feature extraction processing on the ability description text information by using the multi-scale capsule network module and using the convolution kernels of multiple convolution templates to obtain multiple feature information; The feature encoding unit is used to encode the multiple feature information by using the capsule network module to obtain the first feature vector.
10. The device according to claim 9, wherein, The multi-scale capsule network module includes: a plurality of low-level capsules and high-level capsules; The feature encoding unit is used to process the multiple feature information by using the plurality of low-level capsules to obtain a plurality of low-level capsule feature information; based on the plurality of low-level capsule feature information and the corresponding affine matrix, obtain a plurality of prediction vectors; perform weighted summation processing on the plurality of prediction vectors according to the coupling coefficient to obtain an input vector; use an activation function to perform compression processing on the input vector and input the compression processing result into the high-level capsule, so that the high-level capsule outputs the first feature vector based on the compression processing result; wherein, the coupling coefficient is updated based on the first feature vector and by using a dynamic routing algorithm.
11. The device according to claim 8, wherein, The second feature mining module is used to perform low-dimensional space feature extraction processing on the first feature vector by using the sparse coding model of the sparse coding module and based on a sparse coding matrix to obtain the second feature vector.
12. The device according to claim 8, wherein The neural network model includes: a convolutional layer, a pooling layer, and a softmax classifier; The classification result obtaining module is used to perform feature extraction and fusion processing on the second feature vector by using the convolutional layer and the pooling layer, input the processing result into the softmax classifier; and obtain the ability classification result information according to the result output by the softmax classifier.
13. The device according to any one of claims 8 to 12 further includes: The classification evaluation module is used to determine evaluation index information based on the ability classification result information; evaluate the classification result according to the evaluation index information; wherein, the evaluation index includes at least one of the following: accuracy index, precision index, recall rate index, and comprehensive index of precision and recall rate.
14. A tool ability classification device includes: A memory; And a processor coupled to the memory, the processor being configured to execute the method according to any one of claims 1 to 7 based on instructions stored in the memory.
15. A computer-readable storage medium storing computer instructions that, when executed by a processor, perform the method according to any one of claims 1 to 7.
16. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.