A human-computer collaborative topic classification search mode method, device and storage medium
Through the human-computer collaborative theme classification search mode method, the feature vectors of the query text are extracted and the weight matrix of the sparse model is adjusted, which solves the problem of traditional search engines lacking adaptability when dealing with diversified and dynamically changing queries, and achieves more Efficient, personalized and accurate search results.
Patent Information
- Application Number
- CN202410693073.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-30
- Publication Date
- 2025-02-07
- Estimated Expiration
- 2044-05-30
AI Technical Summary
Traditional search engines lack adaptability when dealing with diverse and dynamically changing queries, and cannot optimize for different queries or user personalized needs, which affects the personalization and accuracy of search results.
A human-computer collaboration theme classification search mode method is proposed. By extracting feature vectors from the input query text, adjusting the weight matrix of the preset sparse model, pruning processing unimportant weights, dynamically optimizing the sparse model, and Output topic classification search results.
It improves the relevance and accuracy of search results, reduces the complexity and computing needs of the model, enhances the adaptability and continuous learning ability of the model, and ensures that the model is always consistent with the actual needs of the user.
Smart Images

Figure CN118568227B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of artificial intelligence technology, and in particular to a method, device and storage medium for human-computer collaborative topic classification search mode. Background Art
[0002] In today's era of information explosion, the efficiency and accuracy of search technology are crucial to user experience. With the rapid increase in data volume and the diversification of user needs, traditional search engines and data processing systems face many challenges, especially in processing efficiency, storage optimization, model dynamics, personalized experience and resource management. These challenges have given rise to the demand for more advanced search technology solutions to improve the performance and adaptability of search systems.
[0003] Traditional search engines usually rely on static algorithms to process queries. These algorithms are based on fixed ranking mechanisms and keyword matching, and often ignore the dynamic changes and personalized needs of user behavior. In other words, static algorithms lack the necessary adaptability when processing diverse and dynamically changing queries, which means that traditional search engines cannot be optimized for different queries or user personalized needs, thus affecting the personalization and accuracy of search results. Summary of the invention
[0004] In view of this, the present disclosure proposes a human-machine collaborative topic classification search mode method, device and storage medium.
[0005] According to one aspect of the present disclosure, a human-computer collaborative topic classification search mode method is provided, the method comprising:
[0006] Extracting a feature vector from an input query text, wherein the feature vector includes a plurality of input features;
[0007] According to the feature vector, adjusting a preset sparsification model to obtain an adjusted sparsification model, wherein the adjustment includes pruning a weight matrix of the sparsification model, wherein the weight matrix includes a plurality of weights, and the weights are used to indicate the contribution of the corresponding input features to the output result of the sparsification model;
[0008] According to the feature vector, the corresponding topic classification search results are obtained through the adjusted sparsification model output.
[0009] In a possible implementation, adjusting a preset sparsification model according to the feature vector to obtain an adjusted sparsification model includes:
[0010] Determine, according to each input feature in the feature vector, a correlation degree between each weight and the output result, wherein the correlation degree is used to indicate the degree of influence of the corresponding input feature on the output result through the weight;
[0011] According to the correlation between each of the weights and the output result, pruning the weight matrix of the sparsification model to obtain the adjusted sparsification model;
[0012] The pruning process includes removing at least one weight in the weight matrix.
[0013] In another possible implementation, the pruning of the weight matrix of the sparsification model according to the correlation between each weight and the output result includes:
[0014] According to the correlation between each weight and the output result, each weight of the weight matrix is adjusted, and each weight in the adjusted weight matrix is positively correlated with the corresponding correlation;
[0015] At least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than a preset pruning threshold.
[0016] In another possible implementation, the method further includes:
[0017] According to the sparsity of the weight matrix after pruning, a corresponding matrix storage format is determined, and the matrix storage format is a format for storing the weight matrix after pruning.
[0018] In another possible implementation, determining the corresponding matrix storage format according to the sparsity of the weight matrix after pruning includes:
[0019] Determining a sparsity ratio of the weight matrix after the pruning process, wherein the sparsity ratio is a ratio between the number of non-zero weights and the total number of weights in the weight matrix after the pruning process;
[0020] When the sparsity ratio is less than a preset sparsity threshold, determining that the corresponding matrix storage format is a first storage format;
[0021] When the sparsity ratio is greater than or equal to the preset sparsity threshold, it is determined that the corresponding matrix storage format is a second storage format, and the second storage format is different from the first storage format.
[0022] In another possible implementation, the method further includes:
[0023] Obtaining satisfaction data corresponding to the topic classification search results;
[0024] The adjusted sparsification model is updated according to the satisfaction data.
[0025] In another possible implementation, the method further includes:
[0026] Based on the historical load data, a preset analysis model is used to output a load forecast result, where the load forecast result is used to indicate the predicted system load condition within a preset time period in the future;
[0027] According to the load prediction result, the allocation of target resources is adjusted, and the target resources are resources used when processing the system load.
[0028] According to another aspect of the present disclosure, a human-machine collaborative topic classification search mode device is provided, the device comprising:
[0029] An extraction module, used to extract a feature vector from an input query text, wherein the feature vector includes a plurality of input features;
[0030] An adjustment module, configured to adjust a preset sparsification model according to the feature vector to obtain an adjusted sparsification model, wherein the adjustment includes pruning a weight matrix of the sparsification model, wherein the weight matrix includes a plurality of weights, and the weights are used to indicate a contribution of a corresponding input feature to an output result of the sparsification model;
[0031] The output module is used to obtain the corresponding topic classification search results according to the feature vector through the adjusted sparsification model output.
[0032] In a possible implementation, the adjustment module is further configured to:
[0033] According to the correlation between each of the weights and the output result, pruning the weight matrix of the sparsification model to obtain the adjusted sparsification model;
[0034] The pruning process includes removing at least one weight in the weight matrix.
[0035] In another possible implementation, the adjustment module is further configured to:
[0036] According to the correlation between each weight and the output result, each weight of the weight matrix is adjusted, and each weight in the adjusted weight matrix is positively correlated with the corresponding correlation;
[0037] At least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than a preset pruning threshold.
[0038] In another possible implementation, the apparatus further includes: a determining module, configured to:
[0039] According to the sparsity of the weight matrix after pruning, a corresponding matrix storage format is determined, and the matrix storage format is a format for storing the weight matrix after pruning.
[0040] In another possible implementation, the determining module is further configured to:
[0041] Determining a sparsity ratio of the weight matrix after the pruning process, wherein the sparsity ratio is a ratio between the number of non-zero weights and the total number of weights in the weight matrix after the pruning process;
[0042] When the sparsity ratio is less than a preset sparsity threshold, determining that the corresponding matrix storage format is a first storage format;
[0043] When the sparsity ratio is greater than or equal to the preset sparsity threshold, it is determined that the corresponding matrix storage format is a second storage format, and the second storage format is different from the first storage format.
[0044] In another possible implementation, the device further includes: an updating module, configured to:
[0045] Obtaining satisfaction data corresponding to the topic classification search results;
[0046] The adjusted sparsification model is updated according to the satisfaction data.
[0047] In another possible implementation, the device further includes: a prediction module, configured to:
[0048] Based on the historical load data, a preset analysis model is used to output a load forecast result, where the load forecast result is used to indicate the predicted system load condition within a preset time period in the future;
[0049] According to the load prediction result, the allocation of target resources is adjusted, and the target resources are resources used when processing the system load.
[0050] According to another aspect of the present disclosure, a human-machine collaborative topic classification search mode device is provided, the device comprising:
[0051] processor;
[0052] a memory for storing processor-executable instructions;
[0053] Wherein, the processor is configured to implement the above method when executing the instructions stored in the memory.
[0054] According to another aspect of the present disclosure, a non-volatile computer-readable storage medium is provided, on which computer program instructions are stored, and when the computer program instructions are executed by a processor, the method described in the claim is implemented.
[0055] According to another aspect of the present disclosure, a computer program product is provided, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of a computing device, the processor in the computing device executes the above method.
[0056] The disclosed embodiment provides a human-computer collaborative topic classification search mode method, which extracts feature vectors from the input query text, adjusts the preset sparsification model according to the feature vectors, and the adjustment includes pruning the weight matrix of the preset sparsification model to remove some unimportant weights in the weight matrix. The sparsification model can be dynamically adjusted and optimized, so that the feature vectors are processed using the adjusted sparsification model, and the corresponding topic classification search results are output to ensure the relevance and accuracy of the search results. In addition, weight pruning reduces the complexity of the model, thereby reducing the computing requirements, which not only improves the efficiency of the model operation, but also helps to reduce the required computing resources, so that the model responds to user queries more quickly. In addition, weight pruning also provides the model with the ability to continuously learn and adapt. As user needs and query patterns change, this mechanism ensures that the model is continuously optimized and always consistent with the actual needs of users.
[0057] Further features and aspects of the present disclosure will become apparent from the following detailed description of exemplary embodiments with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate exemplary embodiments, features, and aspects of the disclosure and, together with the description, serve to explain the principles of the disclosure.
[0059] Figure 1 A schematic diagram of the structure of a computing device provided by an exemplary embodiment of the present disclosure is shown.
[0060] Figure 2 A flowchart of a human-computer collaborative topic classification search mode method provided by an exemplary embodiment of the present disclosure is shown.
[0061] Figure 3 A flowchart of a human-computer collaborative topic classification search mode method provided by another exemplary embodiment of the present disclosure is shown.
[0062] Figures 4 to 6 A schematic diagram showing a keyword list of different topics provided by an exemplary embodiment of the present disclosure is shown.
[0063] Figure 7 A schematic diagram of the structure of a human-machine collaborative topic classification search mode device provided by an exemplary embodiment of the present disclosure is shown.
[0064] Figure 8 It is a block diagram of a device for executing a human-machine collaborative topic classification search mode method according to an exemplary embodiment. DETAILED DESCRIPTION
[0065] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.
[0066] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.
[0067] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.
[0068] First, the application scenarios involved in this disclosure are introduced. Figure 1 , which shows a schematic diagram of the structure of a computing device provided by an exemplary embodiment of the present disclosure.
[0069] A computing device can be a server or a terminal. A terminal includes a mobile terminal or a fixed terminal, such as a mobile phone, a tablet computer, a laptop computer, a desktop computer, etc. A server can be a single server, a server cluster consisting of several servers, or a cloud computing service center. A computing device can refer to the entire search system or service platform, including all servers and related infrastructure that process queries, store data, perform background tasks, etc. This is not limited to a single query server, but includes the computing resources of the entire system, such as database servers, application servers, network resources, etc.
[0070] The computing device includes a processor 10, a memory 20, and a communication interface 30. Those skilled in the art will appreciate that Figure 1The structure shown in the figure does not constitute a limitation on the computing device, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0071] The processor 10 is the control center of the computing device, and uses various interfaces and lines to connect various parts of the entire computing device. It executes various functions of the computing device and processes data by running or executing software programs and / or modules stored in the memory 20, and calling data stored in the memory 20, thereby controlling the computing device as a whole. The processor 10 can be implemented by a CPU or a GPU.
[0072] The memory 20 can be used to store software programs and modules. The processor 10 executes various functional applications and data processing by running the software programs and modules stored in the memory 20. The memory 20 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system 21, an extraction module 22, an adjustment module 23, an output module 24, and an application 25 required for at least one function, etc.; the data storage area may store data created according to the use of the computing device, etc. The memory 20 may be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as a static random access memory (SRAM), an electrically erasable programmable read-only memory (EEPROM), an erasable programmable read-only memory (EPROM), a programmable read-only memory (PROM), a read-only memory (ROM), a magnetic memory, a flash memory, a magnetic disk or an optical disk. Accordingly, the memory 20 may further include a memory controller to provide the processor 10 with access to the memory 20 .
[0073] Among them, the processor 10 performs the following functions by running the extraction module 22: extracting a feature vector from the input query text, the feature vector includes multiple input features; the processor 10 performs the following functions by running the adjustment module 23: adjusting the preset sparsification model according to the feature vector to obtain an adjusted sparsification model, the adjustment includes pruning the weight matrix of the sparsification model, the weight matrix includes multiple weights, and the weights are used to indicate the contribution of the corresponding input features to the output results of the sparsification model; the processor 10 performs the following functions by running the output module 24: according to the feature vector, the corresponding topic classification search results are obtained through the output of the adjusted sparsification model.
[0074] It should be noted that the human-computer collaborative topic classification search mode method provided by the embodiment of the present disclosure can be applied to multiple application scenarios, including but not limited to the following: 1. Information retrieval: quickly find information related to the query in a large number of documents or web pages. Through topic classification, the search results can be organized into different topic categories to improve search efficiency and accuracy. 2. Document management: For a large amount of document data of an enterprise or an individual, the documents can be automatically classified and managed through topic classification, so that users can quickly locate the required documents. 3. Recommendation system: In applications such as news aggregation and content recommendation, content on related topics is recommended to users to improve user experience. 4. Sentiment analysis: By subject-classifying text data such as social media and comments, the public's emotional tendencies towards different topics can be analyzed. 5. Natural language processing: In fields such as machine translation and question-answering systems, topic classification can help the system better understand the context and improve processing accuracy. The embodiment of the present disclosure does not limit this.
[0075] Below, several exemplary embodiments are used to introduce a human-computer collaborative topic classification search mode method provided by the embodiment of the present disclosure.
[0076] Please refer to Figure 2 , which shows a flowchart of a human-computer collaborative topic classification search mode method provided by an exemplary embodiment of the present disclosure. This embodiment uses this method for Figure 1 The method is illustrated by using the computing device shown in FIG.
[0077] Step 201 : extracting a feature vector from an input query text, where the feature vector includes a plurality of input features.
[0078] The computing device obtains the input query text and analyzes the input query text using text analysis techniques. This process involves natural language processing techniques and aims to extract structured feature vectors from the query text, laying a foundation for subsequent topic classification and information retrieval. The query text is the search content or information request input by the user, and the feature vector is defined as a mathematical vector whose elements contain multiple key features in the query text, that is, multiple input features, used to characterize the data structure of the query text.
[0079] In a possible implementation, the computing device extracts feature vectors from the input query text, including but not limited to the following steps:
[0080] 1. Preprocessing: First, preprocess the input query text, including removing stop words (such as "of", "is", etc.), punctuation marks, numbers and other irrelevant words, and performing stemming or lemmatization to convert the words into their basic forms. 2. Word segmentation: Split the preprocessed text into individual words or phrases for further processing. Rule-based methods (such as regular expressions) or statistic-based methods (such as Hidden Markov Models) can be used for word segmentation. 3. Feature extraction: Based on word segmentation, use a feature extraction method to represent the text. Common feature extraction methods include the Bag-of-Words model (English: Bag-of-Words) and Term Frequency-Inverse Document Frequency (TF-IDF). Among them, the Bag-of-Words model is used to indicate that each document is represented as a vector composed of the occurrence times of words in the vocabulary. Each dimension corresponds to a word. If the word appears in the document, the value at the corresponding position is 1, otherwise it is 0. Term Frequency-Inverse Document Frequency is used to indicate the importance of a word by calculating the occurrence frequency of the word in the document and the inverse document frequency in the entire corpus. The higher the importance of the word, the larger the value of the corresponding feature vector. 4. Dimensionality reduction: Since the original feature vector may be very large, dimensionality reduction operations are required to reduce the number of features. Common methods include principal component analysis, linear discriminant analysis, and singular value decomposition, etc. 5. Vectorization: Map the dimensionality-reduced feature vector to a vector space with a fixed length for subsequent processing. This can be achieved through some machine learning algorithms (such as support vector machines, random forests, etc.) or deep learning models (such as convolutional neural networks, recurrent neural networks, etc.). The above are the steps provided by a possible implementation of extracting feature vectors from the input query text, and the specific extraction method can be adjusted and optimized according to actual needs and the characteristics of the dataset.
[0081] Step 202, according to the feature vector, adjust the preset sparsification model to obtain an adjusted sparsification model, the adjustment includes pruning the weight matrix of the sparsification model, the weight matrix includes multiple weights, and the weights are used to indicate the contribution of the corresponding input features to the output result of the sparsification model.
[0082] The computing device can dynamically adjust the preset sparsification model according to the feature vector, which involves pruning the weight matrix. This process can optimize the model and improve its efficiency and performance. The sparsification model is a machine learning model that implements feature selection by constraining model parameters so that most parameters are close to zero, thereby simplifying the model and improving its generalization ability. The sparsification model can effectively solve the overfitting problem in high-dimensional data set modeling by removing a large number of redundant variables and retaining only the explanatory variables most relevant to the response variable, thereby simplifying the model structure while retaining key information. The sparsification model can be referred to as the model below.
[0083] In a sparse model, weights are parameters that connect neurons and are adjusted during the training process to minimize the loss function. Weights determine how much the corresponding input feature contributes to the output of the sparse model. Pruning is an optimization technique that involves reducing the number of weights in a sparse model. By removing weights that have little impact on the model's performance, the model's complexity and computational requirements can be reduced. A feature vector consists of multiple input features. For example, in text processing, an input feature may be the presence or absence of a word or a statistical measure. Weights are multiplied by the corresponding input features and synthetically affect the model's decision process. By adjusting the weights, the influence of a particular input feature on the model's prediction can be changed. Therefore, the importance of weights and the importance of input features are closely related. In the process of pruning, we actually evaluate and reduce the weights that contribute the least to the model's output instead of directly manipulating the features themselves. This process not only makes the model more focused on the important input features, but also optimizes the overall performance of the model. Pruning weights helps the model operate more efficiently, especially when processing large datasets, which can significantly improve processing speed and responsiveness while maintaining or even improving the accuracy of the model. In addition, this technique can reduce the risk of overfitting the model. In large-scale deep learning models, a large number of low-importance weights may capture noise in the training data rather than generalizable features. Through pruning, sparse models can be more robust and improve performance on new, unseen data.
[0084] In one possible implementation, the weight matrix corresponding to the preset sparsification model is pruned according to the feature vector, which may include but is not limited to the following steps: 1. Obtaining the weight matrix: Obtaining the weight matrix of the preset sparsification model, the matrix contains multiple weights, each weight corresponds to an input feature, and each weight is used to indicate the contribution of the corresponding input feature to the output result of the sparsification model. 2. Pruning: During the pruning process, those weights that are considered unimportant will be set to zero, thereby reducing the complexity of the model. This importance is judged by the correlation between the weight and the output result, where the weights with a smaller correlation with the output result are often pruned first.
[0085] In addition to pruning the weight matrix, adjusting the sparse model can also include but is not limited to the following aspects: 1. Adding regularization terms: Adding regularization terms, such as L1 or L2 regularization, to the loss function of the sparse model to encourage the sparse model to produce a sparse weight matrix. 2. Applying activation functions: Using activation functions such as ReLU, which can produce zero values during training, thereby increasing the sparsity of the sparse model. 3. Optimization algorithm selection: Using optimization algorithms suitable for sparse learning, such as sparse gradient descent, these methods will take into account the requirements of sparsity when updating weights. 4. Network structure adjustment: Increase the sparsity of the sparse model by reducing the number of connections or neurons in the network. These methods can be used alone or in combination to achieve better sparsification effects. In actual operation, it is usually necessary to select the appropriate method based on the requirements of the specific task and the limitations of computing resources. The adjusted sparse model will be more efficient because it reduces the amount of calculation and alleviates the risk of overfitting. In addition, the sparse model is easier to interpret because non-zero weights represent the most important input features. When performing adjustments such as pruning, you need to pay attention to balancing the complexity and performance of the model to ensure that excessive pruning does not lead to underfitting of the model.
[0086] Step 203: According to the feature vector, the corresponding topic classification search results are obtained through the adjusted sparsification model output.
[0087] The computing device can input the feature vector of the query text into the adjusted sparsification model, and output the subject classification search results corresponding to the query text. That is, the computing device can use the adjusted sparsification model to perform subject classification on the feature vector of the query text, and classify the query text into one or more predefined subject categories. The purpose of subject classification is to simplify the retrieval and organization of information so that users can quickly find the content they are interested in. This process may involve calculating the similarity or probability between the feature vector and each subject category, and selecting the search results under one or more subject categories that best match as the subject classification search results, that is, the subject classification search results include search results under one or more subject categories that match the feature vector of the query text.
[0088] When the computing device is a terminal, the terminal outputs the corresponding topic classification search results and displays the topic classification search results. When the computing device is a server, the server obtains the corresponding topic classification search results and sends the topic classification search results to the terminal, so that the terminal displays the topic classification search results.
[0089] The display methods of the subject classification search results may include a list view, a summary view, and a visual analysis. For example, taking the list view as an example, the subject classification search results can be listed according to relevance or other sorting criteria (such as date, number of citations, etc.). In this list view, the user can see key information such as the title, author, published journal or conference information, and abstract of each document. This embodiment of the disclosure is not limited to this.
[0090] In summary, current search systems often use static models, which limits the flexibility and accuracy of the system in responding to real-time changing user queries and needs. The disclosed embodiment provides a human-computer collaborative topic classification search mode method, which extracts feature vectors from the input query text, adjusts the preset sparsification model according to the feature vectors, including pruning the weight matrix of the preset sparsification model, and removes some unimportant weights in the weight matrix. The sparsification model can be dynamically adjusted and optimized, so that the feature vectors are processed using the adjusted sparsification model, and the corresponding topic classification search results are output to ensure the relevance and accuracy of the search results. In addition, weight pruning reduces the complexity of the model, thereby reducing the computational requirements, which not only improves the efficiency of the model operation, but also helps to reduce the required computing resources, so that the model responds to user queries faster. In addition, weight pruning also provides the model with the ability to continuously learn and adapt. As user needs and query patterns change, this mechanism ensures that the model is continuously optimized and always keeps consistent with the actual needs of users.
[0091] It should be noted that the method provided by the embodiments of the present disclosure can not only solve the above technical problems, but also solve the following key technical problems, which are mainly focused on improving the efficiency and accuracy of the search system and its adaptability to dynamic loads and changing user needs. The key technical problems that can be solved are as follows:
[0092] 1. Processing efficiency and storage optimization: Most search systems use conventional database management techniques for data storage and processing, and fail to effectively utilize the sparsity of data to optimize storage and computing resources. This results in longer system response times and lower processing efficiency when the amount of data increases dramatically. A method is needed to reduce unnecessary computing burdens and storage requirements, thereby improving the processing speed and storage efficiency of the search system.
[0093] 2. User experience and personalization: Users expect fast and highly relevant search results. Traditional search systems often fail to fully utilize user feedback to optimize search results. A mechanism is needed to adjust the search algorithm based on real-time user feedback to provide a more personalized search experience.
[0094] 3. Resource management and load balancing: During peak user access periods, traditional systems may experience response delays or service degradation due to improper resource allocation. Therefore, an intelligent resource management strategy is needed that can dynamically adjust resource allocation based on predicted load and real-time demand to ensure the stability and efficiency of system performance.
[0095] In order to solve the above-mentioned technical problems, the embodiment of the present disclosure provides a topic classification search mode method based on human-computer collaboration, which aims to improve the efficiency and user experience of the search system by introducing dynamic optimization technology. The method combines deep learning and intelligent resource management technology to adapt to the ever-changing user needs and system load conditions. The method may include but is not limited to the following steps: First, the query text input by the user is analyzed by natural language processing technology, feature vectors are extracted, and the feature vectors indicate keywords and / or topics, and a sparse model is initialized. This step is intended to reduce unnecessary computing load and storage requirements and improve data processing speed. Then, by real-time monitoring of the weight changes of the sparse model and dynamically pruning unimportant weights, the model performance is further optimized to ensure that the model focuses on processing the information most relevant to the query text input by the user. In order to further improve storage and computing efficiency, the method provided in the embodiment of the present disclosure can also automatically select the most suitable matrix storage format, such as Compressed Sparse Row (CSR) or ELLpack format (ELL) format, according to the sparsity ratio of the weight matrix after pruning. In addition, the method provided in the embodiment of the present disclosure also dynamically adjusts the model parameters of the sparsification model according to the user's satisfaction with the topic classification search results through an interactive performance feedback optimization mechanism to provide more accurate and relevant search results. Finally, the method provided in the embodiment of the present disclosure also realizes resource-aware dynamic load balancing. Through intelligent resource management, it predicts the upcoming system load and adjusts resource allocation accordingly to ensure that the computing device can still maintain efficient response during the peak of user requests. The method provided in the embodiment of the present disclosure not only improves the search efficiency and accuracy, but also ensures the high adaptability and user satisfaction of the system through dynamic resource management and user feedback optimization, greatly improves the user's search experience, further improves the search performance, and enables the computing device to better adapt to the rapidly changing data processing needs and user behavior. It is suitable for modern search engines and recommendation systems that need to process large amounts of information and provide fast and accurate feedback. The method provided in the embodiment of the present disclosure is further introduced below.
[0096] Please refer to Figure 3 , which shows a flowchart of a human-computer collaborative topic classification search mode method provided by another exemplary embodiment of the present disclosure. This embodiment uses this method for Figure 1 The method is illustrated by using the computing device shown in FIG.
[0097] Step 301: extract feature vectors from the input query text and obtain a preset sparsification model.
[0098] The computing device analyzes the query text input by the user through natural language processing technology, extracts keywords and / or topics to construct a high-dimensional feature vector. Then, a preset sparse model is obtained, which is used to process the feature vector. The model optimizes the storage and computing efficiency of the model by introducing sparsity constraints, reduces unnecessary computing burden, and thus improves processing speed and data responsiveness.
[0099] Step 302: Perform dynamic semantic analysis and weight matrix pruning on the preset sparsification model according to the feature vector to obtain an adjusted sparsification model.
[0100] The computing device can monitor the weight changes of the sparse model in real time and prune the unimportant target weights according to the preset relevance threshold to further reduce the complexity of the model. This process not only reduces the computational requirements of the model, but also enhances the model's focus on the more relevant parts of the current query, thereby improving the accuracy and relevance of the topic classification search results.
[0101] Step 303, determining the corresponding matrix storage format according to the sparsity of the weight matrix after pruning.
[0102] The computing device can automatically select the most appropriate matrix storage format (such as CSR format or ELL format) according to the sparsity of the weight matrix. The matrix storage format is the format for storing the weight matrix after pruning, thereby optimizing storage space and improving query efficiency. This allows the computing device to maximize the use of available storage resources without sacrificing performance, which is particularly suitable for processing large-scale data sets.
[0103] Step 304: According to the feature vector, the corresponding topic classification search results are obtained through the adjusted sparsification model output.
[0104] The computing device can input the feature vector of the query text into the adjusted sparsification model, and output the topic classification search results corresponding to the query text.
[0105] Step 305 , performing interactive performance feedback optimization on the adjusted sparsification model according to the satisfaction data corresponding to the topic classification search results.
[0106] The computing device can further optimize the model performance by collecting user satisfaction data on the topic classification search results and performing interactive performance feedback optimization on the adjusted sparsification model. This feedback-based optimization mechanism can better adapt to the user's query needs, adjust the model in real time to provide more accurate topic classification search results, and enhance the user experience.
[0107] Step 306: predict the upcoming system load and adjust resource allocation according to the load prediction result.
[0108] Computing devices can achieve intelligent resource management by predicting the upcoming system load and adjusting resource allocation based on the current resource availability. This strategy ensures that the system can maintain efficient response during peak user request periods, optimizes the performance and resource utilization of the entire system, and is suitable for environments that require high reliability and high response speed.
[0109] It should be noted that steps 302 and 303 are real-time adjustments during the model application process. These optimizations are intended to enhance the model's ability to handle current queries. Step 305 involves both the application of real-time feedback and the continuous learning of the model. It can be seen as a transitional step. Adjustments in real-time applications also optimize the model for future queries. Step 306 is to adjust resource allocation based on model training and prediction of upcoming system loads after the entire model application is completed. This is mainly to ensure the long-term stability and efficiency of the system and to adapt to different load requirements.
[0110] In summary, the subject classification search mode method based on human-computer collaboration provided by the embodiment of the present disclosure not only improves the search efficiency and accuracy, but also ensures the high adaptability and user satisfaction of the system through dynamic resource management and user feedback optimization. The implementation of this method has important practical application value for modern search engines and recommendation systems that need to process a large amount of information and provide fast and accurate feedback.
[0111] In the subject classification search mode method based on human-computer collaboration provided by the embodiment of the present disclosure, the relationship between the above steps constitutes a systematic and interdependent framework, and each step provides the necessary foundation and optimization support for the next step. The following is a further explanation of the relationship between these steps.
[0112] 1. From feature extraction to dynamic semantic analysis:
[0113] The feature extraction step provides the foundation for the entire search process. By identifying the keywords and / or topics of the user's query and initializing a sparse model, this step ensures that the computing device can process data efficiently and reduces unnecessary computing and storage requirements. This lays the foundation for the dynamic semantic analysis and weight pruning steps, which further optimize the sparse model by pruning unimportant weights, so that the sparse model is more focused on the information most relevant to the user's query. In this way, the computing device not only runs faster, but also provides more accurate topic classification search results.
[0114] 2. From dynamic semantic analysis to adaptive storage format selection:
[0115] Once the sparsified model is optimized through dynamic semantic analysis, the next step is to select the most appropriate matrix storage format. Dynamic weight pruning reduces the number of weights and increases sparsity, which provides direct input for the adaptive matrix storage format selection step. According to the sparsity of the weight matrix after pruning, the most suitable matrix storage format (such as CSR format or ELL format) can be selected to further improve storage and processing efficiency.
[0116] 3. From adaptive storage format selection to outputting search results and performing interactive performance feedback optimization:
[0117] The optimized matrix storage format improves data processing speed, which enables computing devices to respond to user input and process user feedback more quickly. The interactive performance feedback optimization step uses this accelerated data processing capability to dynamically adjust the sparsification model again based on user satisfaction data on the output topic classification search results. This feedback mechanism ensures that the sparsification model can self-optimize based on real-time user feedback to provide search results that better meet user expectations.
[0118] 4. From interactive performance feedback optimization to resource-aware dynamic load balancing:
[0119] As the sparsification model is adjusted again based on user feedback, it may require different levels of computing resources to handle different system loads. This is where the resource-aware dynamic load balancing step comes into play, ensuring that the computing device is efficient when handling various system loads through intelligent resource management. Adjusting resource allocation based on system load predictions and current resource availability ensures that the computing device remains responsive and accurate regardless of the system load it faces.
[0120] Overall, these steps interact with each other to form a closed-loop optimization system. Each step not only optimizes its direct output, but also provides a more optimized input for the next step. This design enables computing devices to not only effectively process and respond to user queries, but also continuously adapt to changes in user needs and system load conditions, providing a continuously optimized search experience.
[0121] The following is a summary of the above Figure 3 Further explanation of each step of the subject classification search pattern method based on human-computer collaboration is provided.
[0122] The description of step 301 of "extracting a feature vector from the input query text and obtaining a preset sparsification model" also includes:
[0123] The sparsification model is used to process feature vectors to identify the topic classification search results of user queries. The optimization process of the sparsification model can be expressed by the following formula:
[0124] W*=arg min_W(L(Y,f(X,W))+lambda*sum(sign(abs(W))))
[0125] Where W represents the weight matrix corresponding to the sparsified model, which is the main goal of optimization. W* represents the optimized weight matrix, and L(Y,f(X,W)) is the loss function of the sparsified model, where Y is the true output parameter and f(X,W) is the predicted output parameter calculated by the sparsified model based on the input parameter X and the weight matrix W. This loss function measures the error between the predicted output parameter and the true output parameter, and is the part that needs to be minimized in the optimization process. arg min_W means finding the value of the weight matrix W that minimizes the value of the loss function L(Y,f(X,W)). In other words, this is looking for the optimal weight configuration so that the predicted output of the model is as close to the true output parameter Y as possible. Y usually refers to the true label or target output used for supervised learning during the model training phase. Each input sample X has a corresponding target output Y, and the model learns to minimize the difference between Y and the model's predicted output f(X,W).
[0126] If a dynamic optimization process is mentioned, then Y still refers to the real feedback or labels used to adjust and optimize the model. Even in a real-time or dynamic environment after the model is deployed, actual outputs from user feedback or other real-time data sources may be used to further fine-tune and optimize model performance. This may include user satisfaction feedback, click-through rate, or other metrics related to user interaction as real-time labels. In the case of real-time or dynamic optimization, although these Y values are not obtained in the traditional training data set, these real-time collected data play a role similar to training labels, helping the model adjust and optimize its performance to better adapt to current user needs and environmental conditions. In the case of real-time or dynamic optimization, although these Y values are not obtained in the traditional training data set, these real-time collected data play a role similar to training labels, helping the model adjust and optimize its performance to better adapt to current user needs and environmental conditions. Therefore, arg min_W is a process of finding the optimal weights, and Y, as the real output parameters, is a key element used to guide the direction of model optimization, both in the training phase and in the dynamic optimization process. In a dynamic system, these labels may come from real-time user feedback or other dynamically measured performance indicators, allowing the model to continuously self-adjust and optimize in a real-world operating environment.
[0127] lambda*sum(sign(abs(W))) is the key parameter of the sparse model. lambda is a regularization coefficient used to control the impact of sparsity on the total loss. The function sign(abs(W)) is used to indicate that the absolute value of each weight in the weight matrix W is first calculated, and then the corresponding sign (1 or 0) is given according to the size of the absolute value. For example, if abs(W) is greater than 0, the value of sign(abs(W)) is 1; if abs(W) is equal to 0, the value of sign(abs(W)) is 0. sum(sign(abs(W))) refers to the total number of non-zero weights in the weight matrix. In this way, the sparse model is encouraged to learn representations that only depend on a few key weights, thereby achieving the sparsification of the model.
[0128] The optimization process of the sparsification model refers to the optimization activities performed after the feature vectors are extracted and applied to the initialized sparsification model, i.e., the preset sparsification model. That is, the feature vector is substituted as X into the above formula to obtain the optimized weight matrix W*. This process includes using these feature vectors to adjust the weight matrix corresponding to the sparsification model so that the sparsification model can more effectively identify and process information related to user queries. The optimization process not only focuses on improving the prediction accuracy of the sparsification model, but also covers reducing the computational burden of the model and improving the operating efficiency through various techniques (such as weight pruning and sparsity adjustment). This is a dynamic process, which means that the sparsification model can continuously adjust the model parameters inside the sparsification model to adapt to the characteristics of the input data based on the input data.
[0129] The weight matrix is pre-set when the sparse model is initialized, and is dynamically adjusted as data is input during the model training process. Each weight in the weight matrix reflects the importance or influence of the corresponding input feature on the output of the model. During the optimization process, the feature vectors extracted by natural language processing are used to evaluate and adjust these weights. The adjustment of weights can be based on reducing the error between the output parameters predicted by the sparse model and the actual output parameters, so that the sparse model can more accurately reflect the actual situation of the input data. The adjustment of weights also involves evaluating the contribution of each input feature in the feature vector to the output of the sparse model, ensuring that the model can highlight the features that have the greatest impact on the output, while reducing or pruning the influence of those weights that contribute less to the output.
[0130] In practical applications, this sparsification technique greatly improves the operation efficiency and storage efficiency of sparse models. For example, in e-commerce search engines, this sparsification technique can be used to quickly filter out the product categories that are most relevant to user queries. Because the model has been sparsely processed, it can maintain a high query response speed and accuracy even when processing extremely large data sets. In addition, the application of sparse models on mobile devices and edge computing devices also shows great potential. On these devices, computing power and storage space are relatively limited. Applying sparse models can not only reduce the resource requirements for model deployment, but also achieve fast data processing and analysis without sacrificing too much accuracy.
[0131] The description of step 302 of "performing dynamic semantic analysis and weight matrix pruning processing on a preset sparsification model according to the feature vector to obtain an adjusted sparsification model" also includes:
[0132] In the step of dynamic semantic analysis and weight pruning, an efficient method can be used to optimize the deep learning model to improve its performance and efficiency in actual search tasks. The main purpose of this step is to reduce insignificant weights in the sparse model, thereby reducing the computational complexity and improving the response speed of the sparse model.
[0133] The computing device can determine the correlation between each weight and the output result according to each input feature in the feature vector, and the correlation is used to indicate the degree of influence of the corresponding input feature on the output result of the sparse model through the weight; according to the correlation between each weight and the output result, the weight matrix of the preset sparse model is pruned, and the pruning process includes removing at least one weight in the weight matrix. Optionally, according to the correlation between each weight and the output result, each weight in the weight matrix after adjustment is positively correlated with the corresponding correlation; at least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than the preset pruning threshold. This method based on correlation and dynamic pruning makes the model more efficient and reduces the computational burden while maintaining sensitivity to key features. This is particularly important for real-time applications because it can significantly reduce the response time and resource consumption of the model while improving the model's ability to handle peak loads.
[0134] The calculation of the correlation usually relies on the statistical relationship between the weights and the output results. In deep learning models, one possible implementation is to determine the importance of each weight by determining the degree of influence it has on the model output. Alternatively, the correlation between each weight and the output result can be evaluated by partial gradients or the cumulative contribution of gradients. The size of the gradient can usually reflect the degree of influence of the input feature on the output result of the sparse model through the corresponding weight.
[0135] Schematically, during the training process, the gradient (dL / dw) calculated by the back propagation algorithm (where L is the loss function and w is the weight) can be used to measure the correlation between each weight and the output result. The larger the absolute value of the gradient of the weight, the greater the impact of adjusting the weight on the output of the model, that is, the higher the correlation between the weight and the output result.
[0136] Regarding the setting of the preset pruning threshold, one possible implementation method is to determine it based on the statistical distribution of weight gradients. For example, it can be set to a certain percentile of the absolute value of the gradient, such as the 25th percentile. All weights whose absolute values of the gradient are lower than this threshold are considered to contribute less to the model output and can therefore be pruned (i.e. set to zero). Another possible implementation method is to adjust the threshold through experiments and performance tests on the validation set to find the best balance, that is, to maximize weight pruning while maintaining or improving model performance.
[0137] The key technology used in this step is the dynamic pruning of the weight matrix. The weight pruning process is achieved through a simple but very effective conditional judgment and element operation. The schematic formula is as follows:
[0138] W_t+1=W_t*(abs(W_t)>T)
[0139] In this formula, the symbols have the following meanings:
[0140] W_t: is the weight matrix of the current time step t. W_t can be considered as the result of adjusting the weight matrix using the correlation obtained based on the current eigenvector.
[0141] W_t+1: is the weight matrix for the next time step.
[0142] T: is the preset pruning threshold used to determine the importance of the weight. When the absolute value of a weight is less than the preset pruning threshold T, the weight is determined to be an unimportant target weight, so at least one target weight is set to zero during the update process.
[0143] abs(W_t)>T: is a conditional expression that applies the absolute value function to each weight in the weight matrix W_t and then compares it with the preset pruning threshold T. If the absolute value of the weight is greater than the preset pruning threshold T, the result is true (1), otherwise it is false (0).
[0144] Whether the preset pruning threshold T is the same for each weight usually depends on the specific requirements of the model design and optimization strategy. In many practical applications, this threshold can be unified (i.e., the same) or different thresholds can be set for different weights or weight groups. There can be two main cases here: one case is that the preset pruning threshold corresponding to each weight is the same. In some models, especially when the contribution and importance of weights are relatively uniform, it is common to use a single global threshold, i.e., a unified preset pruning threshold. This method simplifies the pruning process, is easy to implement, and in many cases has been able to effectively reduce the complexity of the model and improve efficiency. The choice of a unified threshold may be based on experience, prior knowledge, or tuning through a validation data set. One case is that the preset pruning thresholds corresponding to at least two weights are different. For more complex or heterogeneous models, different weights may have different effects on the output of the model, and different thresholds may need to be set for different weights or weight groups. For example, in a deep neural network, weights in different layers may have different preset pruning thresholds because the information abstraction level and complexity processed by different layers in the network are different. Setting different preset pruning thresholds can more finely tune the model, better retaining weights that are critical to performance while pruning those that are less important.
[0145] Element multiplication*: It is an element-by-element multiplication operation that multiplies each weight in the weight matrix W_t by the corresponding Boolean value (1 or 0). If the absolute value of a weight is less than the preset pruning threshold T, it will be multiplied by 0, so that the weight is set to zero in the weight matrix W_t+1 of the next time step.
[0146] The purpose of dynamic weight pruning is to reduce the computational load of the sparse model at runtime and improve processing speed. By dynamically pruning weights that contribute less to the current task, the focus and efficiency of the sparse model on specific queries can be significantly improved. For example, in a large-scale text classification or search system, many features (weights) may not be important under certain specific queries. By pruning these unimportant weights, the sparse model can focus more quickly on features that are indeed important for the current task.
[0147] In actual search systems, dynamic semantic analysis and weight pruning can be used to instantly adjust the behavior of search engines to adapt to the user's query intent. For example, in an e-commerce platform, if a user enters the query text "best outdoor sports equipment", the computing device can dynamically adjust its weights and remove those weights that are not highly related to the query text "outdoor sports equipment", ensuring the relevance and accuracy of subsequent topic classification search results.
[0148] The description of step 303 "determining the corresponding matrix storage format according to the sparsity of the weight matrix after pruning" also includes:
[0149] In the step of selecting the adaptive matrix storage format, we focus on optimizing the matrix storage structure of the model to improve its efficiency in different hardware and application scenarios. This step uses an adaptive algorithm to select the most appropriate storage format based on the sparsity of the weight matrix after pruning, thereby minimizing memory usage and increasing calculation speed while maintaining data integrity. The weight matrix in the embodiment of the present disclosure may also be referred to as a sparse matrix, and the matrix storage structure may also be referred to as a sparse matrix storage format.
[0150] The sparsity of the pruned weight matrix is measured by calculating the ratio of the number of non-zero elements in the matrix to the total number of elements. In other words, the ratio is the ratio between the number of non-zero weights in the pruned weight matrix and the total number of weights. The sparsity ratio S can be expressed as the following formula:
[0151] S=(Number of non-zero elements in W) / (Total elements in W)
[0152] Among them, "Number of non-zero elements in W" represents the number of non-zero weights in the weight matrix W after pruning. "Total elements in W" is the total number of weights in the weight matrix W after pruning. S is the calculated sparsity ratio, a value between 0 and 1.
[0153] After determining the sparsity ratio of the weight matrix after pruning, the most suitable matrix storage structure is selected according to the calculated sparsity ratio. When the sparsity ratio is less than a preset sparsity threshold, the corresponding matrix storage format is determined to be a first storage format; when the sparsity ratio is greater than or equal to the preset sparsity threshold, the corresponding matrix storage format is determined to be a second storage format, which is different from the first storage format.
[0154] Illustratively, the first storage format is the CSR format, the second storage format is the ELL format, the preset sparsity threshold is 0.1, and when the sparsity ratio is less than 0.1, the CSR format is selected; when the sparsity ratio is greater than or equal to 0.1, the ELL format is selected.
[0155] The CSR format and the ELL format are two commonly used sparse matrix storage formats, each of which is suitable for data sets with different sparsity.
[0156] CSR format: When the sparsity of the matrix is very high (that is, most of the elements are zero), the CSR format achieves data compression by storing the values of non-zero elements and their positions in the row. This format is very suitable for matrices with uneven distribution of non-zero elements because it does not require uniform distribution of non-zero elements by column.
[0157] ELL format: ELL format is suitable for matrices with relatively uniform distribution of non-zero elements. In this format, the number of non-zero elements in each row is fixed, and if the non-zero elements of a row are not enough to fill it, zero padding is used. This makes ELL more efficient when processing data with regular sparse patterns.
[0158] It should be noted that the selection of the most appropriate matrix storage format is usually dynamically adjusted based on the sparsity of the current weight matrix. This means that the choice of matrix storage format is not determined once and for all during the model training phase before application, but can be adjusted according to the state and needs of the model during real-time application.
[0159] The process of dynamically adjusting the matrix storage format may include but is not limited to the following steps: 1. Real-time sparsity evaluation: During the model operation, the system will continuously monitor and calculate the sparsity of the weight matrix. This involves evaluating the ratio between the number of non-zero weights and the total number of weights, namely the sparsity ratio, to determine the sparsity level of the current weight matrix. 2. Select the matrix storage format: According to the sparsity ratio calculated in real time, the most appropriate matrix storage format is automatically selected. As in the above example, if the sparsity ratio is less than 0.1, the CSR format may be selected; when the sparsity ratio is greater than or equal to 0.1, the ELL format may be selected. This choice depends on the current state of the weight matrix and can change at different training stages or application times of the model.
[0160] This dynamic selection mechanism allows the model to optimize its storage and computing resources according to the characteristics of the actual data in different application scenarios and at different time points. For example, after a model has been trained for a period of time, some weights may become unimportant (close to zero), thereby increasing the sparsity of the matrix. By dynamically adjusting the storage format, memory can be managed more efficiently and the computing process can be accelerated. In addition, this dynamic adjustment mechanism provides extremely high flexibility, allowing search systems or recommendation systems to optimize performance and response speed by adjusting data storage methods when resources are limited or computing demand peaks.
[0161] Therefore, the selection of the adaptive sparse storage format is based on the sparsity of the current weight matrix, rather than being fixed only in the early stages of model training. This design allows the model to more finely adapt to the changing data characteristics and processing requirements at runtime, thereby improving overall system efficiency and performance. This is also a common optimization strategy in modern deep learning systems, aimed at achieving efficient resource management and optimal operating performance.
[0162] Choosing the right matrix storage format can significantly improve the speed of data processing and memory usage efficiency. For example, in the forward and backward propagation of a neural network, using the best matrix storage format can reduce the number of memory accesses and increase the cache hit rate, thereby speeding up the calculation process. In addition, when performing sparse matrix operations on GPUs or other specialized hardware, the appropriate matrix storage format selection is particularly important because these hardware are often very sensitive to memory access patterns.
[0163] In practical applications, such as in real-time decision-making systems for autonomous vehicles, using an appropriate matrix storage format can ensure that large amounts of sensor data can be quickly processed with limited hardware resources. By calculating the sparsity ratio in real time and selecting the best matrix storage format, decisions can be made quickly, improving the vehicle's reaction speed and safety.
[0164] In big data analysis and cloud computing services, the adaptive selection of matrix storage formats has also greatly improved the performance and economic benefits of services. Data centers can dynamically adjust storage strategies based on real-time or predicted data access patterns, optimize resource allocation, and reduce operation and maintenance costs.
[0165] In summary, by intelligently selecting the most appropriate matrix storage format, not only is the computation and storage efficiency improved, but it also provides important support for applications that process complex and large-scale data sets. The implementation of this technology is particularly important for information processing systems that require high efficiency and low latency, especially in application scenarios that require fast response.
[0166] The description of step 304 of "obtaining corresponding topic classification search results according to the feature vector through the adjusted sparsification model output" also includes:
[0167] The subject classification search results include information related to the query text entered by the user, and can include text, images, videos, or other media forms of data. The specific details depend on the search design and the user's query text. For example, in a shopping website's search engine, the output subject classification search results may include product lists, descriptions, price information, etc.; in an academic search engine, the output subject classification search results may include related papers, author information, publication sources, etc.
[0168] The description of step 305 of "performing interactive performance feedback optimization on the adjusted sparsification model according to the satisfaction data corresponding to the topic classification search results" also includes:
[0169] In the interactive performance feedback optimization step, a mechanism can be introduced to enable the adjusted sparsified model to dynamically adjust its model parameters again based on user feedback. This step aims to directly integrate the user's actual experience and satisfaction into the model optimization process, and update the weight matrix of the adjusted sparsified model so that the sparsified model can more accurately predict or classify the input data, thereby improving the actual application performance of the model and user satisfaction.
[0170] Optionally, during the weight update process, each weight is adjusted based on a calculation of its effect on the loss function. This means that the update amount for each weight is calculated independently, based on the product of its gradient and the adjustment factor. In a training cycle (e.g. after a batch is processed), all weights in the model are usually updated. This ensures that the model as a whole is optimized in the direction of reducing loss.
[0171] In this step, the update method of each weight in the weight matrix can be shown as follows:
[0172] W_new=W_old+alpha*dL / dW*R
[0173] In this formula, the symbols have the following meanings:
[0174] 1. W_old: is the weight before the sparsification model is updated.
[0175] 2. W_new: is the updated weight of the sparse model.
[0176] 3. Alpha: It is the preset learning rate, which is a hyperparameter used to control the step size of weight update, that is, the speed or amplitude of weight adjustment.
[0177] 4. dL / dW: is the gradient of the loss function L with respect to the weight W, which indicates how the weights are adjusted to minimize the model loss. The calculation of the gradient reflects the importance of each weight in reducing the total loss.
[0178] 5. R: It is an adjustment factor calculated based on the satisfaction data of user feedback, which is used to adjust the magnitude of weight update to reflect user satisfaction. If the user feedback is high in satisfaction, R is close to 1, indicating that the current model performs well and does not need major adjustments; if the user feedback is low in satisfaction, R will decrease, which means that a larger weight adjustment is needed to improve the model performance.
[0179] The calculation of the adjustment factor R usually involves the following steps:
[0180] Optionally, user satisfaction with the topic classification search results can be collected in various ways, such as direct rating, click-through rate, usage time, conversion rate or other interactive indicators. These data are used as satisfaction data to indicate the user's satisfaction with the current topic classification search results.
[0181] Optionally, the collected user feedback data needs to be quantified into an actual value, which can be done by setting a threshold, calculating an average, or applying a more complex statistical model. For example, if the satisfaction data includes a satisfaction index, if a rating system is used, the average rating may be converted into a satisfaction index between 0 and 1.
[0182] Optionally, the corresponding adjustment factor can be calculated based on the satisfaction data and the preset functional relationship. Common methods include linear mapping, logarithmic or exponential function adjustment to ensure that the adjustment factor is within a reasonable range (such as 0.1 to 1). For example, if the user's satisfaction index is 80%, the adjustment factor can be set to 0.8, which means that the magnitude of the weight adjustment will remain at a high level to maintain the current performance of the model.
[0183] Here, amplitude refers to the size of the weight update step, which is the result of alpha*dL / dW*R in the above formula. This result directly affects the amount of adjustment of each weight, thereby affecting the learning process and final performance of the model. The adjustment amplitude is mainly achieved by modifying the adjustment factor in the weight update formula. In the above weight update formula, the learning rate determines the step size of the weight update, and the role of the adjustment factor is to adjust this step size according to the user's satisfaction data. When the adjustment factor is large (indicating high user satisfaction), the step size of the weight update is close to or equal to the maximum step size alpha*dL / dW; when the adjustment factor is small (indicating low user satisfaction), the step size of the weight update is reduced, which forces the model to make larger adjustments to improve performance.
[0184] The core of this interactive performance feedback optimization step is to directly transform user feedback into a dynamic factor for model adjustment. Traditional model training processes often rely on predefined data sets and static loss functions, which may cause the performance of the model in actual applications to deviate from user expectations. By introducing user satisfaction data as a feedback mechanism, the model can be made more in line with the actual needs and usage environment of users. For example, in a recommendation system, user satisfaction with recommended content can be collected through click-through rate, dwell time, or direct ratings. This data is fed back into the model training process, allowing the model to learn which content is more popular and which does not meet user expectations. Over time, the model will gradually adjust its recommendation strategy to maximize user satisfaction. In practical applications, this approach is particularly suitable for service scenarios that require high personalization, such as personalized news push, online advertising, e-commerce product recommendations, etc. In these scenarios, user feedback is dynamic and diverse. By integrating this feedback in real time, the model can not only provide more accurate services, but also continuously optimize itself to adapt to changes in user behavior.
[0185] In search engine applications, interactive performance feedback optimization technology is particularly suitable for enhancing the personalization and accuracy of search results. By collecting user satisfaction with search results, such as click-through rate, reading time, or user reviews, this data can be used as performance feedback to directly influence the adjustment of the model. This enables the search engine to dynamically adjust its algorithm to prioritize the display of results that are more in line with the user's search intent and preferences. Over time, the search engine will continue to learn and adapt to each user's query habits and preferences, so that it can provide more accurate and relevant content, enhance user satisfaction and improve the overall search experience. This approach can not only increase user engagement and satisfaction, but also reduce information overload and improve search efficiency by optimizing the relevance of search results.
[0186] In addition, interactive performance feedback optimization can also be applied to intelligent customer service systems, where customer service robots adjust themselves based on the user's satisfaction with problem resolution. If user feedback shows that the problem is not effectively solved, the system can adjust its response strategy and improve the problem identification and answering process to improve service quality and efficiency.
[0187] In short, by incorporating user feedback directly into the model training and optimization process, not only the adaptability and flexibility of the model is improved, but also the user experience is significantly enhanced. The implementation of this technology is of great significance for building highly dynamic and user-centric intelligent systems, which ensures that the system's performance is continuously optimized while closely following the changes in user needs and satisfaction.
[0188] The description of step 306 "predicting the upcoming system load and adjusting resource allocation according to the load prediction result" also includes:
[0189] This step is a resource-aware dynamic load balancing step that provides a highly intelligent resource management strategy that aims to optimize the allocation of computing resources to adapt to real-time system load requirements. The core of this strategy is to predict the upcoming system load and adjust resource allocation accordingly, thereby ensuring that the computing device can maintain optimal performance when facing different system loads.
[0190] System load generally refers to the amount of work that needs to be processed at any given point in time. This includes, but is not limited to, the number of user queries, the complexity of database operations, the number of data processing tasks, etc. For example, system load may include the amount of tasks that use a sparsified model to query based on the query text. System load can be quantified by a variety of parameters, such as: 1. Query frequency: the rate at which users submit queries to the system. 2. Data throughput: the amount of data processed by the system per unit time, such as the number of requests processed per second. 3. Number of concurrent users: the number of users using the system at the same time. 4. CPU and memory utilization: the use of resources when the system is processing load.
[0191] Computing equipment can use preset analysis models to output load forecast results based on historical load data. The load forecast results are used to indicate the system load conditions within a preset time period in the future. This load forecast can help system administrators and automation tools make decisions in advance, such as expanding or reducing resources, to optimize performance and cost-effectiveness.
[0192] Historical load data is used to indicate the system load in history before the current moment. The historical load data includes parameters such as CPU usage, memory usage, and network bandwidth usage. The analysis model is a preset mathematical or statistical model used to analyze and predict the system load in a preset time period in the future. The analysis model can be a time series analysis model, a machine learning model, etc. The load prediction result can be a system load index. The system load index is positively correlated with the predicted system load level, that is, the higher the predicted system load level, the larger the system load index, and the lower the predicted system load level, the smaller the system load index. For example, the system load index is a value between 0 and 1. The system load situation refers to the workload of the computing device within a specific time. This usually involves CPU usage, memory usage, storage I / O operations, etc. Understanding the system load situation is crucial to maintaining good performance and responsiveness, especially in multi-user or high-demand environments.
[0193] The computing device can dynamically adjust the allocation of target resources based on the load prediction results. The target resources are the resources used to process the system load. The target resources include but are not limited to hardware resources, software resources, data resources, etc. For example, if a high load period is predicted, computing resources can be increased to automatically increase processing power, such as starting more server instances or increasing network bandwidth. Conversely, if a low load period is predicted, resources can be reduced to save costs without affecting user experience.
[0194] In this process, the resource allocation adjustment method can be described by the following formula:
[0195] Resource_Allocation=Load_Prediction*Resource_Availability
[0196] In this formula, the symbols have the following meanings:
[0197] 1. Resource_Allocation: It determines the amount of resources allocated to the task to be processed.
[0198] 2. Load_Prediction: It is an index of future system load predicted based on historical load data. This usually represents an estimated value that reflects the expected workload or stress level of the system. Although described as an "index" here, in fact, in the context of mathematics and technology, this does not specifically refer to the concept of "index" in mathematics, but refers to a predicted value or coefficient, usually between 0 and 1. This value is used to quantify the expected system load intensity.
[0199] 3. Resource_Availability: The total amount of resources currently available, including but not limited to CPU, memory, storage, and network bandwidth.
[0200] In the above formula, Load_Prediction is used as a coefficient to dynamically adjust resource allocation according to the load demand predicted by the system. Further, if the predicted load is very high, close to 1, it means that the system will experience a high load period and more resources will be needed to handle the expected tasks and services. In this way, the value of Load_Prediction will directly affect the final Resource_Allocation calculation result and determine the amount of resources actually allocated to the task. For example, if the system predicts that there will be a large amount of data processing demand in the future (such as a large promotion or a major news event), the Load_Prediction value will increase, thereby increasing the amount of resource allocation to meet the demand. On the contrary, if a lower load is predicted, fewer resources are allocated to optimize cost-effectiveness. This dynamic adjustment mechanism can effectively cope with changing workloads, ensuring that the system can maintain high efficiency and responsiveness under different pressures while avoiding waste of resources.
[0201] In large-scale computing environments, such as cloud computing platforms or large data centers, effective management of resources is critical to maintaining high efficiency and responsiveness of computing devices. When computing devices encounter sudden load increases, such as during promotions on e-commerce platforms or popular events in online media services, without an effective resource management strategy, computing devices may experience increased response time or reduced service quality due to insufficient resources. By implementing dynamic load balancing, it is possible to predict these system load peaks and prepare in advance, and to respond to these peaks by intelligently adjusting resource allocation. For example, if it is predicted that user access will increase dramatically within the next hour, it can be automatically adjusted to increase the allocation of computing resources to key services, such as database query and transaction processing modules, while potentially reducing resource allocation for non-critical tasks.
[0202] In practical applications, this strategy is particularly suitable for online services that need to handle a large number of concurrent requests, such as cloud services, online games, streaming services, and online trading systems. For example, on a cloud service platform, resource-aware dynamic load balancing can ensure a fairer allocation of resources among tenants while optimizing the operating efficiency of the entire platform. In addition, this approach can also be applied to smart city and Internet of Things (IoT) scenarios, where a large number of devices and services need to run efficiently with limited computing resources.
[0203] In short, by implementing resource-aware dynamic load balancing, we can not only improve the utilization efficiency of computing resources, but also ensure stable and efficient responses even under extreme load conditions. This is especially important in today's digital age where large amounts of data and requests need to be processed quickly, and helps build a more resilient and reliable computing environment.
[0204] In summary, compared with related technologies, the method provided by the embodiments of the present disclosure significantly improves the efficiency, accuracy and user satisfaction of the search system, while also optimizing resource utilization and system responsiveness:
[0205] On the one hand, the steps of dynamic semantic analysis and weight pruning bring the following beneficial effects: 1. Improve the relevance and accuracy of search results: This step directly affects the relevance and accuracy of search results by monitoring the changes in model weights in real time and pruning unimportant weights. By removing weights that have little impact on the current query, the model can focus more on information that is highly relevant to the user query, which directly improves the user experience. 2. Optimize model performance: The pruning process reduces the complexity of the model, thereby reducing the computational requirements. This not only improves the efficiency of model operation, but also helps reduce the required computing resources, allowing the model to respond to user queries faster. 3. Dynamic adaptability: Compared with other steps, dynamic semantic analysis and weight pruning provide the model with the ability to continuously learn and adapt. As user needs and query patterns change, this mechanism ensures that the model is continuously optimized and always consistent with the actual needs of users. 4. Improve the relevance of search results by 10%-15%, which directly improves user satisfaction and interaction effects, and increases user click-through rate and user retention rate. 5. Increase system efficiency and reduce resource waste: By adjusting weights in real time and cutting out unnecessary information, computing and storage resources can be used more efficiently, reducing the extra burden caused by processing irrelevant information.
[0206] On the other hand, the following beneficial effects are brought about by the adaptive storage format selection step: related technologies often require a large amount of computing resources and storage space when processing large-scale data, especially when the data is highly sparse, and the traditional storage format may lead to a large amount of resource waste. The disclosed embodiment also introduces adaptive sparse storage format selection, which can prune the sparsity of the weight matrix after processing, select the most suitable matrix storage format (such as CSR format or ELL format), optimize the storage structure, and reduce space occupancy. Experiments show that this method can save storage space by more than 30%, while increasing data processing speed by about 20%.
[0207] On the other hand, the interactive performance feedback optimization step brings the following beneficial effects: the related technology lacks a mechanism to effectively utilize user feedback to optimize search results. The disclosed embodiment also dynamically adjusts the sparsification model again based on the user's satisfaction data on the output topic classification search results by adopting interactive performance feedback optimization technology. This strategy not only improves the user experience, but also enables the search system to learn and adapt to the specific needs of users. For example, by adjusting the adjustment factor in the weight update step (based on user satisfaction), user-preferred content can be displayed preferentially in future searches, thereby improving user satisfaction and the personalization capabilities of the system.
[0208] On the other hand, the resource-aware dynamic load balancing step brings the following beneficial effects: Compared with the static or manual resource management in the related art, the embodiment of the present disclosure also realizes resource-aware dynamic load balancing. Through the intelligent resource management strategy, the upcoming load can be predicted and the resource allocation can be automatically adjusted according to the availability of current resources. This not only improves the efficiency of resource utilization, but also ensures the response speed and service quality of the system during peak hours. In practical applications, this method has been proven to reduce the response time during peak hours by about 25%, while increasing the processing capacity of the overall system by about 20%.
[0209] In summary, the embodiments of the present disclosure provide a comprehensive solution that significantly improves the performance and user experience of the search system by combining advanced data processing technology and intelligent resource management, while effectively reducing operating costs and resource waste. These improvements not only solve many defects of related technologies, but also provide new directions and possibilities for the development of future search technologies. The topic classification search results include one or more topic categories that match the feature vector of the query text.
[0210] In an illustrative example, the input query text is "health", and the output topic classification search results corresponding to the query text "health" may include three topics, namely Topic 21, Topic 1 and Topic 28. The weights corresponding to the three topics may be 0.016, 0.027, and 0.023, respectively. These topics are categories or category groups extracted from the input query text through analysis and processing, representing the most relevant information categories for the query. Regarding the weights corresponding to these topics, they represent the quantitative values of the relevance of each topic to the query text. The size of the weight reflects the degree of relevance of each topic to the input query text; the higher the weight, the stronger the relevance of the topic to the query text. This weight mechanism helps the search system determine which topics should be presented to the user, that is, which topics are most critical and useful to the user's query. Among them, the keyword list of Topic 21 is as follows: Figure 4 As shown in the figure, it contains keywords such as "sanitation" and "health". The keyword list of subject category 1 is as follows Figure 5As shown in Figure 2, it contains keywords such as "society" and "health". The keyword list of topic 28 is as follows: Figure 6 As shown, it contains keywords such as "family" and "health". Figures 4 to 6 The value below each keyword in the table represents the value or index of the keyword when calculating the topic relevance or weight. These values are used to quantify the contribution of each keyword in the process of forming the topic. In short, these values help define the importance of the keyword to the topic, thereby affecting the weight calculation of the entire topic and the final search result performance.
[0211] It should be noted that sparsification techniques reduce the complexity and computational requirements of models by reducing the number of non-zero elements in the model. For example, some advanced neural network sparsification techniques reduce unimportant connections and weights through pruning (weight clipping) and regularization techniques. However, these methods usually fix the sparse structure during the model training phase and lack the ability to dynamically adjust the model to adapt to real-time query needs. In addition, in cloud computing and big data platforms, dynamic resource allocation strategies have begun to be adopted to improve resource utilization and processing performance. These strategies usually adjust the allocation of computing resources based on prediction algorithms to cope with changing loads. Although these methods improve the flexibility of resource management, they are often not tightly integrated with the internal operations of search engines, but are implemented as external scheduling systems, which limits their effectiveness in optimizing search-specific tasks. In addition, some search systems have introduced interactive feedback mechanisms to improve the relevance of search results. Such systems adjust search algorithms based on users' clicks and browsing behaviors. However, most existing implementations focus on utilizing historical behavior data rather than real-time feedback, which leads to a lag in the system's ability to adapt to users' immediate feedback. The disclosed embodiment provides a comprehensive search solution that integrates the above technologies, which not only implements dynamic model optimization based on sparsity, but also introduces a resource-aware dynamic load balancing mechanism that is tightly integrated with the search engine kernel, as well as a model adjustment strategy driven by real-time user feedback. In these ways, the method provided by the disclosed embodiment significantly improves the processing efficiency, response speed, and personalization capabilities of the search system, while optimizing resource allocation and user experience.
[0212] The following is an apparatus embodiment of the present disclosure. For parts not described in detail in the apparatus embodiment, reference may be made to the technical details disclosed in the above method embodiment.
[0213] Please refer to Figure 7 , which shows a schematic diagram of the structure of a human-machine collaborative topic classification search mode device provided by an exemplary embodiment of the present disclosure. The device can be implemented in whole or in part by software, hardware, or a combination of the two, which is called a computing device. The device includes: an extraction module 22, an adjustment module 23, and an output module 24.
[0214] An extraction module 22, used to extract a feature vector from an input query text, where the feature vector includes a plurality of input features;
[0215] An adjustment module 23 is used to adjust the preset sparsification model according to the feature vector to obtain an adjusted sparsification model, wherein the adjustment includes pruning a weight matrix of the sparsification model, wherein the weight matrix includes a plurality of weights, and the weights are used to indicate the contribution of the corresponding input features to the output result of the sparsification model;
[0216] The output module 24 is used to obtain the corresponding topic classification search results according to the feature vector through the adjusted sparsification model output.
[0217] In a possible implementation, the adjustment module 23 is further configured to:
[0218] According to the correlation between each weight and the output result, the weight matrix of the preset sparsification model is pruned to obtain an adjusted sparsification model;
[0219] The pruning process includes removing at least one weight in the weight matrix.
[0220] In another possible implementation, the adjustment module 23 is further configured to:
[0221] According to the correlation between each weight and the output result, each weight of the weight matrix is adjusted, and each weight in the adjusted weight matrix is positively correlated with the corresponding correlation;
[0222] At least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than a preset pruning threshold.
[0223] In another possible implementation, the device further includes: a determining module, configured to:
[0224] According to the sparsity of the weight matrix after the pruning process, the corresponding matrix storage format is determined, and the matrix storage format is a format for storing the weight matrix after the pruning process.
[0225] In another possible implementation, the determining module is further configured to:
[0226] Determine the sparsity ratio of the pruned weight matrix, where the sparsity ratio is the ratio between the number of non-zero weights and the total number of weights in the pruned weight matrix;
[0227] When the sparsity ratio is less than a preset sparsity threshold, determining that the corresponding matrix storage format is a first storage format;
[0228] When the sparsity ratio is greater than or equal to a preset sparsity threshold, it is determined that the corresponding matrix storage format is a second storage format, and the second storage format is different from the first storage format.
[0229] In another possible implementation, the device further includes: an updating module, configured to:
[0230] Obtain satisfaction data corresponding to the search results of the subject classification;
[0231] The adjusted sparsification model is updated based on the satisfaction data.
[0232] In another possible implementation, the device further includes: a prediction module, configured to:
[0233] Based on the historical load data, a preset analysis model is used to output a load forecast result, which is used to indicate the system load condition within a preset time period in the future;
[0234] According to the load prediction results, the allocation of target resources is adjusted. The target resources are the resources used to process the system load.
[0235] It should be noted that the device provided in the above embodiment only uses the division of the above-mentioned functional modules as an example to implement its functions. In practical applications, the above-mentioned functions can be assigned to different functional modules according to actual needs, that is, the content structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0236] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.
[0237] An embodiment of the present disclosure also provides a human-computer collaborative topic classification search mode device, which includes: a processor; a memory for storing processor executable instructions; wherein the processor is configured to implement the above method when executing the instructions stored in the memory.
[0238] The embodiment of the present disclosure further provides a non-volatile computer-readable storage medium having computer program instructions stored thereon, wherein the computer program instructions implement the method as claimed above when executed by a processor.
[0239] The embodiment of the present disclosure also provides a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of a computing device, the processor in the computing device executes the above method.
[0240] Figure 8 1 is a block diagram of a device 1900 for executing a human-machine collaborative topic classification search mode method according to an exemplary embodiment. For example, the device 1900 can be provided as a server or a terminal device. Figure 8 , the apparatus 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions, such as an application, that can be executed by the processing component 1922. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.
[0241] The device 1900 may also include a power supply component 1926 configured to perform power management of the device 1900, a wired or wireless network interface 1950 configured to connect the device 1900 to a network, and an input / output interface 1958 (I / O interface). The device 1900 may operate based on an operating system stored in the memory 1932, such as Windows Server 2000. TM , MacOS X TM , Unix TM ,Linux TM , FreeBSD TM or similar.
[0242] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions, which can be executed by the processing component 1922 of the device 1900 to perform the above method.
[0243] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0244] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0245] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0246] The computer program instructions for performing the operation of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed completely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or completely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be customized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present disclosure.
[0247] Various aspects of the present disclosure are described herein with reference to the flowcharts and / or block diagrams of the methods, devices (systems) and computer program products according to the embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0248] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0249] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0250] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.
[0251] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A human-computer collaborative topic classification search mode method, characterized in that: The method comprises: Extracting a feature vector from an input query text, wherein the feature vector includes a plurality of input features; According to the feature vector, adjusting a preset sparsification model to obtain an adjusted sparsification model, wherein the adjustment includes pruning a weight matrix of the sparsification model, wherein the weight matrix includes a plurality of weights, and the weights are used to indicate the contribution of the corresponding input features to the output result of the sparsification model; According to the feature vector, a corresponding topic classification search result is obtained through the adjusted sparsification model output; The step of adjusting the preset sparsification model according to the feature vector to obtain an adjusted sparsification model includes: Determine, according to each input feature in the feature vector, a correlation degree between each weight and the output result, wherein the correlation degree is used to indicate the degree of influence of the corresponding input feature on the output result through the weight; According to the correlation between each of the weights and the output result, pruning the weight matrix of the sparsification model to obtain the adjusted sparsification model; Wherein, the pruning process includes removing at least one weight in the weight matrix; The pruning process of the weight matrix of the sparsification model according to the correlation between each weight and the output result includes: According to the correlation between each weight and the output result, each weight of the weight matrix is adjusted, and each weight in the adjusted weight matrix is positively correlated with the corresponding correlation; At least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than a preset pruning threshold.
2. The method according to claim 1, characterized in that The method further comprises: According to the sparsity of the weight matrix after pruning, a corresponding matrix storage format is determined, and the matrix storage format is a format for storing the weight matrix after pruning.
3. The method according to claim 2, characterized in that Determining the corresponding matrix storage format according to the sparsity of the weight matrix after pruning includes: Determining a sparsity ratio of the weight matrix after the pruning process, wherein the sparsity ratio is a ratio between the number of non-zero weights and the total number of weights in the weight matrix after the pruning process; When the sparsity ratio is less than a preset sparsity threshold, determining that the corresponding matrix storage format is a first storage format; When the sparsity ratio is greater than or equal to the preset sparsity threshold, it is determined that the corresponding matrix storage format is a second storage format, and the second storage format is different from the first storage format.
4. The method according to any one of claims 1 to 3, characterized in that The method further comprises: Obtaining satisfaction data corresponding to the topic classification search results; The adjusted sparsification model is updated according to the satisfaction data.
5. The method according to any one of claims 1 to 3, characterized in that: The method further comprises: Based on the historical load data, a preset analysis model is used to output a load forecast result, where the load forecast result is used to indicate the predicted system load condition within a preset time period in the future; According to the load prediction result, the allocation of target resources is adjusted, and the target resources are resources used when processing the system load.
6. A human-machine collaborative topic classification search mode device, characterized in that: The device comprises: An extraction module, used to extract a feature vector from an input query text, wherein the feature vector includes a plurality of input features; An adjustment module, configured to adjust a preset sparsification model according to the feature vector to obtain an adjusted sparsification model, wherein the adjustment includes pruning a weight matrix of the sparsification model, wherein the weight matrix includes a plurality of weights, and the weights are used to indicate a contribution of a corresponding input feature to an output result of the sparsification model; An output module, configured to obtain corresponding topic classification search results according to the feature vector through the adjusted sparsification model output; The adjustment module is further used for: According to the correlation between each of the weights and the output result, pruning the weight matrix of the sparsification model to obtain the adjusted sparsification model; Wherein, the pruning process includes removing at least one weight in the weight matrix; The adjustment module is further used for: According to the correlation between each weight and the output result, each weight of the weight matrix is adjusted, and each weight in the adjusted weight matrix is positively correlated with the corresponding correlation; At least one target weight in the adjusted weight matrix is set to zero, and the absolute value of the target weight is less than a preset pruning threshold.
7. A human-machine collaborative topic classification search mode device, characterized in that: The device comprises: processor; a memory for storing processor-executable instructions; The processor is configured to implement the method described in any one of claims 1 to 5 when executing the instructions stored in the memory.
8. A non-volatile computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 5 is implemented.
Citation Information
Patent Citations
Personalized information retrieval method and device
CN107133290A
Neural network model compression method based on structure search and channel pruning
CN114330644A