A method and device for recommending a term, and a device for recommending a term
Through the multi -road recall strategy and radiant processing technology, the recommendation of the entry recommendation in the existing technologies cannot cover the problem of low user input requirements and accuracy, and achieve a more efficient recommendation effect.
Patent Information
- Application Number
- CN202011360947.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-27
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2040-11-27
AI Technical Summary
In the prior art, the entries recommended to users cannot accurately cover the user's input needs and are of low accuracy.
Back multiple vocabulary through multiple recall strategies, return the original scores of the vocabulary, get the target score, and determine the weight of the entry. Essence
It improved the accuracy and coverage of the recommendation of the entry, and the input demand of the user was better met.
Smart Images

Figure CN114564556B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of computer technology, and specifically to a method and device for recommending entries, and a device for recommending entries. Background Art
[0002] Input method clients are usually configured with a system word library, which contains high-frequency words for all users, as well as some authoritative words, hot words, etc. During the user input process, several words can be selected from the system word library as candidate items and recommended to the user. However, with the continuous emergence of new terms and new expressions, the differentiation of user input needs is becoming more and more serious, resulting in some personalized high-frequency terms of users often not being selected into the system word library, so the system word library cannot meet the user's input needs.
[0003] In the prior art, a vocabulary for a certain user is usually recalled through a single or multi-way recall strategy to meet the user's input preferences. However, the vocabulary recalled using a single recall strategy usually cannot accurately cover the user's input needs, and the vocabulary recalled using a multi-way recall strategy is not comparable, so it is impossible to filter out accurate entries for user recommendations. Summary of the invention
[0004] The embodiments of the present application propose a method and device for recommending entries, and a device for recommending entries, so as to solve the technical problems in the prior art that the entries recommended to users cannot cover the user's input requirements and have low accuracy.
[0005] In a first aspect, an embodiment of the present application provides a method for recommending entries, the method comprising: recalling multiple vocabularies based on a multi-way recall strategy, the entries in each vocabularies having an original score; normalizing the original scores for each vocabularies respectively to obtain target scores for the entries in each vocabularies, and determining weights for the entries in each vocabularies respectively; selecting target entries from the multiple vocabularies based on the target scores and the weights, and pushing the target entries to a target client.
[0006] In some embodiments, respectively determining the weights of the terms in each vocabulary includes: grouping the terms in each vocabulary based on the original scores; and determining the weights of each group of terms, wherein terms in the same group have the same weight.
[0007] In some embodiments, the target entries are selected from the multiple vocabularies based on the target scores and the weights, including: based on the weights, weighted summing up the target scores of each recalled entry to obtain a weighted score for each recalled entry; sorting the recalled entries in descending order of the weighted scores; and based on the sorting results, selecting a preset number of entries as target entries.
[0008] In some embodiments, pushing the target terms to a target client includes: aggregating the target terms to obtain a target vocabulary; taking the user targeted by the multi-channel recall strategy as the target user, and pushing the target terms to a target client used by the target user.
[0009] In some embodiments, the normalizing the raw scores for each vocabulary respectively to obtain target scores for the entries in each vocabulary includes: for each recalled vocabulary, based on the minimum and maximum values among the raw scores of the entries in the vocabulary, normalizing the raw scores of the entries in the vocabulary to obtain target scores for the entries in the vocabulary.
[0010] In some embodiments, for each recalled vocabulary, the raw scores of the entries in the vocabulary are normalized based on the minimum and maximum values among the raw scores of the entries in the vocabulary to obtain a target score for the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values among the raw scores of the entries in the vocabulary; for each entry in the vocabulary, determining a first difference between the raw score of the entry and the minimum value, determining a second difference between the maximum value and the minimum value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0011] In some embodiments, for each recalled vocabulary, the raw scores of the entries in the vocabulary are normalized based on the minimum and maximum values in the raw scores of the entries in the vocabulary to obtain target scores for the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values in the raw scores of the entries in the vocabulary, taking the sum of the minimum value and a preset deviation value as a first target value, and taking the difference between the maximum value and the preset deviation value as a second target value; for each entry in the vocabulary, determining a first difference between the raw score of the entry and the first target value, determining a second difference between the second target value and the first target value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0012] In a second aspect, an embodiment of the present application provides a device for recommending entries, the device comprising: a recall unit, configured to recall multiple vocabularies based on a multi-way recall strategy, the entries in each vocabularies having an original score; a processing unit, configured to normalize the original scores for each vocabularies respectively, obtain target scores for the entries in each vocabularies, and respectively determine weights for the entries in each vocabularies; a push unit, configured to select target entries from the multiple vocabularies based on the target scores and the weights, and push the target entries to a target client.
[0013] In some embodiments, the processing unit is further configured to: group the terms in each vocabulary based on the original scores; and determine the weight of each group of terms, wherein terms in the same group have the same weight.
[0014] In some embodiments, the push unit is further configured to: based on the weight, perform weighted summation on the target score of each recalled entry to obtain a weighted score for each recalled entry; sort the recalled entries in descending order of the weighted scores; and based on the sorting result, select a preset number of entries as target entries.
[0015] In some embodiments, the push unit is further configured to: aggregate the target terms to obtain a target vocabulary; take the user targeted by the multi-channel recall strategy as the target user, and push the target terms to a target client used by the target user.
[0016] In some embodiments, the processing unit is further configured to: for each recalled vocabulary, based on the minimum and maximum values of the raw scores of the terms in the vocabulary, normalize the raw scores of the terms in the vocabulary to obtain a target score for the terms in the vocabulary.
[0017] In some embodiments, the processing unit is further configured to: for each recalled vocabulary, determine the minimum and maximum values among the raw scores of the entries in the vocabulary; for each entry in the vocabulary, determine a first difference between the raw score of the entry and the minimum value, determine a second difference between the maximum value and the minimum value, and determine the ratio of the first difference to the second difference as the target score for the entry.
[0018] In some embodiments, the processing unit is further configured to: for each recalled vocabulary, determine the minimum and maximum values of the original scores of the entries in the vocabulary, take the sum of the minimum value and a preset deviation value as the first target value, and take the difference between the maximum value and the preset deviation value as the second target value; for each entry in the vocabulary, determine a first difference between the original score of the entry and the first target value, determine a second difference between the second target value and the first target value, and determine the ratio of the first difference to the second difference as the target score for the entry.
[0019] In a third aspect, an embodiment of the present application provides a device for recommending entries, comprising a memory, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors. The one or more programs include instructions for performing the following operations: recalling multiple vocabularies based on a multi-way recall strategy, the entries in each vocabularies having an original score; normalizing the original scores for each vocabularies respectively to obtain a target score for the entries in each vocabularies, and determining the weights of the entries in each vocabularies respectively; selecting a target entry from the multiple vocabularies based on the target score and the weight, and pushing the target entry to a target client.
[0020] In some embodiments, respectively determining the weights of the terms in each vocabulary includes: grouping the terms in each vocabulary based on the original scores; and determining the weights of each group of terms, wherein terms in the same group have the same weight.
[0021] In some embodiments, the target entries are selected from the multiple vocabularies based on the target scores and the weights, including: based on the weights, weighted summing up the target scores of each recalled entry to obtain a weighted score for each recalled entry; sorting the recalled entries in descending order of the weighted scores; and based on the sorting results, selecting a preset number of entries as target entries.
[0022] In some embodiments, pushing the target terms to a target client includes: aggregating the target terms to obtain a target vocabulary; taking the user targeted by the multi-channel recall strategy as the target user, and pushing the target terms to a target client used by the target user.
[0023] In some embodiments, the normalizing the raw scores for each vocabulary respectively to obtain target scores for the entries in each vocabulary includes: for each recalled vocabulary, based on the minimum and maximum values among the raw scores of the entries in the vocabulary, normalizing the raw scores of the entries in the vocabulary to obtain target scores for the entries in the vocabulary.
[0024] In some embodiments, for each recalled vocabulary, the raw scores of the entries in the vocabulary are normalized based on the minimum and maximum values among the raw scores of the entries in the vocabulary to obtain a target score for the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values among the raw scores of the entries in the vocabulary; for each entry in the vocabulary, determining a first difference between the raw score of the entry and the minimum value, determining a second difference between the maximum value and the minimum value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0025] In some embodiments, for each recalled vocabulary, the raw scores of the entries in the vocabulary are normalized based on the minimum and maximum values in the raw scores of the entries in the vocabulary to obtain target scores for the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values in the raw scores of the entries in the vocabulary, taking the sum of the minimum value and a preset deviation value as a first target value, and taking the difference between the maximum value and the preset deviation value as a second target value; for each entry in the vocabulary, determining a first difference between the raw score of the entry and the first target value, determining a second difference between the second target value and the first target value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0026] In a fourth aspect, an embodiment of the present application provides a computer-readable medium having a computer program stored thereon, which, when executed by a processor, implements the method described in the first aspect above.
[0027] The entry recommendation method, device and device for recommending entries provided in the embodiments of the present application recall multiple vocabularies through a multi-way recall strategy; then normalize the original scores of the entries for each of the vocabularies to obtain the target scores of the entries in each of the vocabularies, and determine the weights of the entries in each of the vocabularies; finally, select the target entry based on the target score and the weight, so as to push the target entry to the target client. On the one hand, since the multi-way recall strategy can recall more abundant entries, the recalled entries cover the user's input needs to a higher degree. On the other hand, the processing based on normalization and weight can make the entries in different vocabularies comparable, so that the selection of target entries from the recalled vocabularies can improve the accuracy of the target entries recommended to the user. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] Other features, objects and advantages of the present application will become more apparent by reading the detailed description of non-limiting embodiments made with reference to the following drawings:
[0029] Figure 1is a flow chart of an embodiment of a method for recommending entries according to the present application;
[0030] Figure 2 is a flowchart of the steps of selecting a target term based on a target score and a weight in the term recommendation method of the present application;
[0031] Figure 3 is a structural schematic diagram of an embodiment of a term recommendation device according to the present application;
[0032] Figure 4 is a schematic diagram of the structure of a device for recommending entries according to the present application;
[0033] Figure 5 It is a schematic diagram of the structure of the server in some embodiments of the present application. DETAILED DESCRIPTION
[0034] The present application will be further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only used to explain the relevant invention, rather than to limit the invention. It should also be noted that, for ease of description, only the parts related to the relevant invention are shown in the accompanying drawings.
[0035] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.
[0036] Please refer to Figure 1 , which shows a process 100 of an embodiment of the entry recommendation method according to the present application. The above entry recommendation method can be run on various electronic devices, including but not limited to: servers, smart phones, tablet computers, e-book readers, MP3 (Moving Picture Experts Group Audio Layer III) players, MP4 (Moving Picture Experts Group Audio Layer IV) players, laptop computers, car computers, desktop computers, set-top boxes, smart TVs, wearable devices, etc.
[0037] The input method application mentioned in the embodiment of the present application can support multiple input methods. Among them, the input method can be a coding method used to input various symbols into electronic devices such as computers and mobile phones. Users can use the input method application to conveniently input the required characters or strings into electronic devices. It should be noted that in the embodiment of the present application, in addition to supporting common Chinese input methods (such as pinyin input method, Wubi input method, Zhuyin input method, voice input method, handwriting input method, etc.), the input method can also support input methods of other languages (such as English input method, Japanese Hiragana input method, Korean input method, etc.), and no limitation is made on the input method and the language type of the input method.
[0038] The term recommendation method in this embodiment may include the following steps:
[0039] Step 101 : recall multiple vocabularies based on a multi-way recall strategy, where entries in each vocabularies have original scores.
[0040] In this embodiment, the execution subject of the term recommendation method (such as the above-mentioned electronic device) can recall multiple vocabularies based on a multi-way recall strategy. Among them, the multi-way recall strategy can refer to a variety of different recall strategies. The multi-way recall strategy may include but is not limited to at least one of the following: a topic-based recall strategy, a recall strategy based on a deep tree matching (Tree-based Deep Match, TDM) model, a recall strategy based on word vectors, a region-based recall strategy, a client-based recall strategy, and other existing recall strategies that can be applied to term recall.
[0041] Among them, a vocabulary can be recalled through each recall strategy, and each vocabulary can contain a large number of entries. Different vocabulary can contain the same entries and different entries. The entries in different vocabulary are independent of each other. For example, the recall strategy based on the deep tree matching model can recall the entries such as "jacket", "skiing", and "skiing family". The recall strategy based on word vectors can recall the entries such as "skating", "snow sports", and "Beijing B skiing". The client-based recall strategy can recall the entries such as "learning to ski", "skiing family", and "fun skiing". The region-based recall strategy can recall "Beijing A Ski Resort", "Beijing B Ski Resort", "Beijing C Ski Resort", etc.
[0042] In this embodiment, the entries in each vocabulary that are recalled may have an original score. The original score is the score calculated during the execution of the recall strategy. Since different vocabulary are recalled based on different recall strategies, the scores of the entries in each vocabulary are independent of each other and are not comparable.
[0043] For example, the recall strategy based on the deep tree matching model can recall the word "jacket" with a score of 1.8, the word "skiing" with a score of 1.7, and the word "skiing family" with a score of 1.5. The recall strategy based on word vectors can recall the word "skating" with a score of 2.7, the word "snow sports" with a score of 2.6, and the word "Beijing B skiing" with a score of 2.5. The client-based recall strategy can recall the word "learning to ski" with a score of 3.7, the word "skiing family" with a score of 3.6, and the word "fun skiing" with a score of 3.4. The region-based recall strategy can recall the word "Beijing A ski resort" with a score of 4.6, the word "Beijing B ski resort" with a score of 4.5, and the word "Beijing C ski resort" with a score of 4.4. It can be seen that the score of "skiing family" in the vocabulary recalled by the recall strategy based on the deep tree matching model is 1.5, and the score in the vocabulary that can be recalled by the client-based recall strategy is 3.6, and the two are independent of each other.
[0044] Step 102 , normalize the original scores for each vocabulary to obtain the target scores of the terms in each vocabulary, and determine the weights of the terms in each vocabulary.
[0045] In this embodiment, for each recalled vocabulary, the execution subject can normalize the original score of each term in the vocabulary to obtain the target score of each term in the vocabulary. The normalization process here can be a data processing method that converts the original score into a numerical value so that the converted value is in the target numerical range (such as [0,1]). Normalizing the original scores of the terms in each vocabulary separately can make the target scores of the terms in different vocabulary distributed in the same numerical range, making the vocabulary that were originally not comparable comparable, so as to facilitate the selection of target terms.
[0046] In this embodiment, for each vocabulary that is recalled, the above-mentioned execution subject can also set weights for the entries in the vocabulary respectively. As an example, for each vocabulary that is recalled, the above-mentioned execution subject can sort the entries in the vocabulary in order from high to low according to the original scores. Then, the entries in the vocabulary can be grouped based on the sorting results, and the number of entries in each group can be the same or different. Finally, weights can be set for each group of entries respectively. Among them, the weights of the entries in the same group are the same, the weights of the entries in different groups are different, and the weights are positively correlated with the average score of the vocabulary in each group.
[0047] For example, if each vocabulary contains 60,000 entries, then for each vocabulary, every 20,000 entries can be divided into a group according to the sorting results, so that the entries in each vocabulary are divided into three groups, and each group of entries in each vocabulary has the same weight. For example, in the vocabulary recalled by the recall strategy based on the deep tree matching model, the weights of each group of entries are 0.7, 0.5, and 0.4, respectively. In the vocabulary recalled by the recall strategy based on word vectors, the weights of each group of entries are 0.6, 0.5, and 0.3, respectively. In the vocabulary recalled by the client-based recall strategy, the weights of each group of entries are 0.4, 0.2, and 0.1, respectively. In the vocabulary recalled by the region-based recall strategy, the weights of each group of entries are 0.4, 0.3, 0.1, etc.
[0048] It should be noted that the weight of each group of terms recalled by various recall strategies can be pre-set based on a large amount of data statistics, and the weight value of each group of terms is not specifically limited here. In addition, in addition to setting weights by grouping, other weight setting rules can be used to set weights as needed, such as setting the same weight for terms in the same vocabulary, etc., which will not be repeated here.
[0049] In some optional implementations of this embodiment, for each recalled vocabulary, the above-mentioned execution entity can normalize the original scores of the entries in the vocabulary based on the minimum and maximum values of the original scores of the entries in the vocabulary to obtain the target scores of the entries in the vocabulary.
[0050] As an example, for each recalled vocabulary, the execution subject may first determine the minimum value (which may be recorded as min) and the maximum value (which may be recorded as max) of the original scores of the terms in the vocabulary. Then, for each term in the vocabulary, determine the first difference between the original score of the term (which may be recorded as x) and the minimum value, determine the second difference between the maximum value and the minimum value, and determine the ratio of the first difference to the second difference as the target score of the term (which may be recorded as x). ’ ). See the following formula:
[0051]
[0052] As another example, the above-mentioned execution entity may first determine the minimum value (which may be recorded as min) and the maximum value (which may be recorded as max) in the original scores of the entries in the vocabulary. Then, the sum of the minimum value and the preset deviation value (which may be recorded as bias) is used as the first target value (i.e., min+bias), and the difference between the maximum value and the preset deviation value is used as the second target value (i.e., max-bias). Afterwards, for each entry in the vocabulary, the first difference between the original score of the entry (which may be recorded as x) and the first target value is determined, the second difference between the second target value and the first target value is determined, and the ratio of the first difference to the second difference is determined as the target score of the entry (which may be recorded as x'). By introducing a preset deviation value, the target score can be avoided from being 0 or 1, so that the normalized result is within the numerical value range (0,1). See the following formula:
[0053]
[0054] It should be noted that, in addition to the above normalization method, other normalization methods can be used to normalize the original scores of each vocabulary to obtain the target scores of the entries in each vocabulary, which will not be described in detail here.
[0055] Step 103 : Select a target term from the above multiple word lists based on the target score and weight, and push the target term to the target client.
[0056] In this embodiment, based on the target score and weight, the execution subject can select the target entry from the multiple word lists by weighted calculation or weighted summation, and push the selected target entry to the target client. The target client can be the client used by the target user, and the target user can be the user targeted by the multi-channel recall strategy.
[0057] As an example, since each entry in each vocabulary has a target score and a weight, the above-mentioned execution subject can first perform weighted calculation on the target score of each entry in each vocabulary based on the weight to obtain a weighted score. Then, target entries can be selected from multiple vocabulary based on the weighted score. For example, entries that meet preset conditions (such as weighted scores greater than a preset threshold) can be selected from each vocabulary as target entries, or a fixed number of entries with higher weighted scores can be selected from each vocabulary as target entries.
[0058] In some optional implementations of this embodiment, see Figure 2 , the above execution entity can select the target entry according to the following sub-steps:
[0059] Sub-step S11, based on the weight, weighted sum is performed on the target score of each recalled term to obtain a weighted score of each recalled term.
[0060] Here, each term may have at least one target score and a corresponding weight. When the same term appears in at least two vocabularies, it has at least two target scores and corresponding weights. The above-mentioned execution subject may process each term in the recalled vocabulary in a weighted summation manner, and use the weighted processing result as the weighted score of the term. Thus, the weighted score of each term incorporates its target scores in each vocabulary to which it belongs, thereby enabling the recall results under the multi-way recall strategy to be integrated and compared, enabling the terms recommended to the user to be more accurate and more in line with the user's input preferences.
[0061] As an example, the recall strategy based on the deep tree matching model can recall the terms "jacket", "skiing", and "skiers", and the target scores of "jacket", "skiing", and "skiers" are 0.9, 0.66, and 0.1, respectively, and the weights are 0.7, 0.7, and 0.7, respectively.
[0062] The recall strategy based on word embedding can recall the terms "ice skating", "snow sports", and "Beijing B skiing", and the target scores of "ice skating", "snow sports", and "Beijing B skiing" are 0.9, 0.5, and 0.1, respectively, and the weights are 0.6, 0.6, and 0.6, respectively.
[0063] The client-based recall strategy can recall the terms "learning to ski", "skiing family", and "fun skiing", and the target scores of "learning to ski", "skiing family", and "fun skiing" are 0.9, 0.66, and 0.1, respectively, and the weights are 0.4, 0.4, and 0.4, respectively.
[0064] The region-based recall strategy can recall the terms "Beijing A Ski Resort", "Beijing B Ski Resort", and "Beijing C Ski Resort", and the target scores of "Beijing A Ski Resort", "Beijing B Ski Resort", and "Beijing C Ski Resort" are 0.9, 0.5, and 0.1, respectively, and the weights are 0.4, 0.4, and 0.1, respectively.
[0065] Based on the weight, the target score of each recalled term is weighted and summed, and the following weighted scores can be obtained: the weighted score of "jacket" is 0.9*0.7=0.63; the weighted score of "skiing" is 0.66*0.7=0.46; the weighted score of "skiing family" is 0.1*0.7+0.66*0.4=0.33; the weighted score of "skating" is 0.9*0.6=0.54; the weighted score of "snow sports" is 0. The score is 0.5*0.6=0.3; the weighted score of "Beijing B Skiing" is 0.1*0.6+0.5*0.4=0.26; the weighted score of "Learning Skiing" is 0.9*0.4=0.36; the weighted score of "Fun Skiing" is 0.1*0.4=0.04; the weighted score of "Beijing A Ski Resort" is 0.9*0.4=0.36; the weighted score of "Beijing C Ski Resort" is 0.1*0.1=0.01.
[0066] Sub-step S12, sorting the recalled entries in descending order of weighted scores.
[0067] Here, each recalled word has a weighted score. Since the weighted score integrates the normalized target scores in each vocabulary to which it belongs, the recall results under the multi-way recall strategy are integrated, thereby realizing the integrated sorting of the terms recalled by the multi-way recall strategy and improving the accuracy of the term sorting results.
[0068] Sub-step S13, based on the sorting results, select a preset number (eg, 60,000) of entries as target entries.
[0069] Since the selected target terms are terms that are ranked higher in the ranking results, that is, terms with higher weighted scores, the accuracy of the target terms recommended to the user can be improved.
[0070] In some optional implementations of this embodiment, when the target terms are pushed to the target client, the target terms may be first summarized to obtain a target word list; then, the user targeted by the multi-way recall strategy is taken as the target user, and the target terms are pushed to the target client used by the target user. Thus, on the basis of the system word list and the cell word list, a target word list for the target user may be configured in the target client, and the word list is obtained by fusing and sorting the terms recalled by the multi-way recall strategy, thereby improving the coverage and accuracy of the target terms recommended to the user.
[0071] The method provided by the above-mentioned embodiment of the present application recalls multiple vocabularies through a multi-way recall strategy; then the original scores of the entries in each of the above-mentioned vocabularies are normalized to obtain the target scores of the entries in each vocabularies, and the weights of the entries in each vocabularies are determined respectively; finally, the target entry is selected based on the above-mentioned target score and the above-mentioned weight, so as to push the target entry to the target client. On the one hand, since the multi-way recall strategy can recall more abundant entries, the recalled entries can cover the user's input needs to a higher degree. On the other hand, the normalization process can make the entries in different vocabularies comparable, so that the selection of target entries from the recalled vocabularies can improve the accuracy of the target entries recommended to the user.
[0072] Further references Figure 3 As an implementation of the methods shown in the above figures, the present application provides an embodiment of a term recommendation device. Figure 1 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0073] like Figure 3 As shown, the term recommendation device 300 in this embodiment includes: a recall unit 301, which is configured to recall multiple vocabularies based on a multi-way recall strategy, and the terms in each vocabularies have original scores; a processing unit 302, which is configured to normalize the above original scores for each of the above vocabularies, obtain the target scores of the terms in each of the above vocabularies, and determine the weights of the terms in each of the above vocabularies; a push unit 303, which is configured to select target terms from the above multiple vocabularies based on the above target scores and the above weights, and push the above target terms to the target client.
[0074] In some optional implementations of this embodiment, the processing unit 302 is further configured to: group the terms in the above-mentioned vocabularies based on the above-mentioned original scores, and predict the recall rate of each group of terms; and determine the weights of the above-mentioned groups of terms based on the recall rates of the above-mentioned groups of terms.
[0075] In some optional implementations of the present embodiment, the push unit 303 is further configured to: based on the weights, perform weighted summation on the target scores of each recalled entry to obtain a weighted score for each recalled entry; sort the recalled entries in descending order of the weighted scores; and based on the sorting results, select a preset number of entries as target entries.
[0076] In some optional implementations of this embodiment, the push unit 303 is further configured to: aggregate the target terms to obtain a target vocabulary; take the user targeted by the multi-channel recall strategy as the target user, and push the target terms to the target client used by the target user.
[0077] In some optional implementations of the present embodiment, the processing unit 302 is further configured to: for each recalled vocabulary, based on the minimum and maximum values of the original scores of the entries in the vocabulary, normalize the original scores of the entries in the vocabulary to obtain the target scores of the entries in the vocabulary.
[0078] In some optional implementations of the present embodiment, the processing unit 302 is further configured to: for each recalled vocabulary, determine the minimum and maximum values of the original scores of the entries in the vocabulary; for each entry in the vocabulary, determine a first difference between the original score of the entry and the minimum value, determine a second difference between the maximum value and the minimum value, and determine the ratio of the first difference to the second difference as the target score of the entry.
[0079] In some optional implementations of the present embodiment, the processing unit 302 is further configured to: for each recalled vocabulary, determine the minimum and maximum values of the original scores of the entries in the vocabulary, take the sum of the minimum value and the preset deviation value as the first target value, and take the difference between the maximum value and the preset deviation value as the second target value; for each entry in the vocabulary, determine a first difference between the original score of the entry and the first target value, determine a second difference between the second target value and the first target value, and determine the ratio of the first difference to the second difference as the target score of the entry.
[0080] The device provided by the above-mentioned embodiment of the present application recalls multiple vocabularies through a multi-way recall strategy; then normalizes the original scores of the entries in each of the above-mentioned vocabularies respectively, obtains the target scores of the entries in each vocabularies, and determines the weights of the entries in each vocabularies respectively; finally, selects the target entry based on the above-mentioned target score and the above-mentioned weight, thereby pushing the target entry to the target client. On the one hand, since the multi-way recall strategy can recall more abundant entries, the recalled entries can cover the user's input needs to a higher degree. On the other hand, the normalization process can make the entries in different vocabularies comparable, thereby selecting the target entry from the recalled vocabularies, which can improve the accuracy of the target entry recommended to the user.
[0081] Figure 44 is a block diagram of an input device 400 according to an exemplary embodiment, and the device 400 may be a smart terminal or a server. For example, the device 400 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0082] Reference Figure 4 , the device 400 may include one or more of the following components: a processing component 402 , a memory 404 , a power component 406 , a multimedia component 408 , an audio component 410 , an input / output (I / O) interface 412 , a sensor component 414 , and a communication component 416 .
[0083] The processing component 402 generally controls the overall operation of the device 400, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 402 may include one or more processors 420 to execute instructions to complete all or part of the steps of the above-described method. In addition, the processing component 402 may include one or more modules to facilitate interaction between the processing component 402 and other components. For example, the processing component 402 may include a multimedia module to facilitate interaction between the multimedia component 408 and the processing component 402.
[0084] The memory 404 is configured to store various types of data to support operations on the device 400. Examples of such data include instructions for any application or method operating on the device 400, contact data, phone book data, messages, pictures, videos, etc. The memory 404 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0085] The power supply component 406 provides power to the various components of the device 400. The power supply component 406 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the device 400.
[0086] The multimedia component 408 includes a screen that provides an output interface between the above-mentioned device 400 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The above-mentioned touch sensor can not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the above-mentioned touch or slide operation. In some embodiments, the multimedia component 408 includes a front camera and / or a rear camera. When the device 400 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera can receive external multimedia data. Each front camera and rear camera can be a fixed optical lens system or have a focal length and optical zoom capability.
[0087] The audio component 410 is configured to output and / or input audio signals. For example, the audio component 410 includes a microphone (MIC), and when the device 400 is in an operating mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 404 or sent via the communication component 416. In some embodiments, the audio component 410 also includes a speaker for outputting audio signals.
[0088] I / O interface 412 provides an interface between processing component 402 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.
[0089] The sensor assembly 414 includes one or more sensors for providing various aspects of status assessment for the device 400. For example, the sensor assembly 414 can detect the open / closed state of the device 400, the relative positioning of the components, such as the display and keypad of the device 400, the sensor assembly 414 can also detect the position change of the device 400 or a component of the device 400, the presence or absence of user contact with the device 400, the orientation or acceleration / deceleration of the device 400 and the temperature change of the device 400. The sensor assembly 414 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 414 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 414 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.
[0090] The communication component 416 is configured to facilitate wired or wireless communication between the device 400 and other devices. The device 400 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 416 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 416 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0091] In an exemplary embodiment, the apparatus 400 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above method.
[0092] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 404 including instructions, and the instructions can be executed by a processor 420 of the device 400 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0093] Figure 5 5 is a schematic diagram of the structure of the server in some embodiments of the present application. The server 500 may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPU) 522 (for example, one or more processors) and a memory 532, and one or more storage media 530 (for example, one or more mass storage devices) storing application programs 542 or data 544. Among them, the memory 532 and the storage medium 530 can be short-term storage or permanent storage. The program stored in the storage medium 530 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations in the server. Furthermore, the central processing unit 522 can be configured to communicate with the storage medium 530 and execute a series of instruction operations in the storage medium 530 on the server 500.
[0094] The server 500 may also include one or more power supplies 526, one or more wired or wireless network interfaces 550, one or more input and output interfaces 558, one or more keyboards 556, and / or one or more operating systems 541, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.
[0095] A non-temporary computer-readable storage medium, when the instructions in the above storage medium are executed by the processor of a device (smart terminal or server), enables the device to execute a term recommendation method, the above method comprising: recalling multiple vocabularies based on a multi-way recall strategy, the terms in each vocabularies having an original score; normalizing the original scores for each of the vocabularies respectively to obtain a target score for the terms in each of the vocabularies, and determining the weights of the terms in each of the vocabularies respectively; selecting a target term from the multiple vocabularies based on the target score and the weight, and pushing the target term to a target client.
[0096] Optionally, respectively determining the weights of the entries in each vocabulary includes: grouping the entries in each vocabulary based on the original scores, and predicting the recall rate of each group of entries; and determining the weights of each group of entries based on the recall rate of each group of entries.
[0097] Optionally, the target entries are selected from the multiple vocabularies based on the target scores and the weights, including: based on the weights, weighted summing up the target scores of each recalled entry to obtain a weighted score for each recalled entry; sorting the recalled entries in descending order of the weighted scores; and based on the sorting results, selecting a preset number of entries as target entries.
[0098] Optionally, pushing the target terms to a target client includes: aggregating the target terms to obtain a target vocabulary; taking the user targeted by the multi-channel recall strategy as the target user, and pushing the target terms to a target client used by the target user.
[0099] Optionally, normalizing the original scores for each vocabulary respectively to obtain target scores for the entries in each vocabulary includes: for each recalled vocabulary, normalizing the original scores of the entries in the vocabulary based on the minimum and maximum values among the original scores of the entries in the vocabulary to obtain the target scores for the entries in the vocabulary.
[0100] Optionally, for each recalled vocabulary, the original scores of the entries in the vocabulary are normalized based on the minimum and maximum values among the original scores of the entries in the vocabulary to obtain a target score for the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values among the original scores of the entries in the vocabulary; for each entry in the vocabulary, determining a first difference between the original score of the entry and the minimum value, determining a second difference between the maximum value and the minimum value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0101] Optionally, for each recalled vocabulary, the original scores of the entries in the vocabulary are normalized based on the minimum and maximum values in the original scores of the entries in the vocabulary to obtain the target scores of the entries in the vocabulary, including: for each recalled vocabulary, determining the minimum and maximum values in the original scores of the entries in the vocabulary, taking the sum of the minimum value and a preset deviation value as the first target value, and taking the difference between the maximum value and the preset deviation value as the second target value; for each entry in the vocabulary, determining a first difference between the original score of the entry and the first target value, determining a second difference between the second target value and the first target value, and determining the ratio of the first difference to the second difference as the target score for the entry.
[0102] Those skilled in the art will readily appreciate other embodiments of the present application after considering the specification and practicing the application disclosed herein. The present application is intended to cover any modification, use or adaptation of the present application, which follows the general principles of the present application and includes common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The specification and examples are intended to be exemplary only, and the true scope and spirit of the present application are indicated by the following claims.
[0103] It should be understood that the present application is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present application is limited only by the appended claims.
[0104] The above is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application should be included in the protection scope of the present application.
[0105] The above is a detailed introduction to a method and device for recommending entries provided by the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for general technical personnel in this field, according to the idea of the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A method for recommending a term, characterized in that: The method comprises: Recalling multiple vocabularies based on a multi-way recall strategy, where the entries in each vocabularies have original scores; the multi-way recall strategy includes at least one of the following: a recall strategy based on a topic, a recall strategy based on a deep tree matching model, a recall strategy based on a word vector, a recall strategy based on a region, and a recall strategy based on a client; For each recalled vocabulary, based on the minimum and maximum values of the raw scores of the terms in each vocabulary, the raw scores of the terms in each vocabulary are normalized to obtain target scores for the terms in each vocabulary, and the weights of the terms in each vocabulary are determined respectively; Based on the target score and the weight, selecting a target term from the multiple vocabularies, and pushing the target term to a target client; The step of respectively determining the weights of the entries in each vocabulary includes: Based on the raw scores, grouping the entries in each vocabulary; The weight of each group of terms is determined, wherein terms in the same group have the same weight.
2. The method according to claim 1, characterized in that: The selecting a target term from the multiple vocabularies based on the target score and the weight comprises: Based on the weight, weighted summing is performed on the target score of each recalled term to obtain a weighted score of each recalled term; Sort the recalled terms in descending order of weighted scores; Based on the sorting results, a preset number of entries are selected as target entries.
3. The method according to claim 1, characterized in that The step of pushing the target entry to the target client includes: Summarizing the target terms to obtain a target word list; The user targeted by the multi-channel recall strategy is taken as the target user, and the target entry is pushed to the target client used by the target user.
4. The method according to claim 1, characterized in that: For each of the recalled vocabularies, based on the minimum and maximum values of the original scores of the entries in each vocabularies, the original scores of the entries in each vocabularies are normalized to obtain the target scores of the entries in each vocabularies, including: For each of the recalled vocabularies, determining a minimum and a maximum among the raw scores of the terms in the vocabularies; For each entry in each vocabulary, a first difference between the original score of each entry and the minimum value is determined, a second difference between the maximum value and the minimum value is determined, and a ratio of the first difference to the second difference is determined as the target score of each entry.
5. The method according to claim 1, characterized in that For each of the recalled vocabularies, based on the minimum and maximum values of the original scores of the entries in each vocabularies, the original scores of the entries in each vocabularies are normalized to obtain the target scores of the entries in each vocabularies, including: For each recalled vocabulary, determine the minimum and maximum values of the original scores of the entries in each vocabulary, take the sum of the minimum value and a preset deviation value as the first target value, and take the difference between the maximum value and the preset deviation value as the second target value; For each entry in each vocabulary, a first difference between the original score of each entry and the first target value is determined, a second difference between the second target value and the first target value is determined, and the ratio of the first difference to the second difference is determined as the target score of each entry.
6. A term recommendation device, characterized in that: The device comprises: A recall unit is configured to recall multiple vocabularies based on a multi-way recall strategy, wherein the entries in each vocabularies have original scores; the multi-way recall strategy includes at least one of the following: a recall strategy based on a topic, a recall strategy based on a deep tree matching model, a recall strategy based on a word vector, a recall strategy based on a region, and a recall strategy based on a client; a processing unit configured to normalize the raw scores of the terms in each of the recalled vocabularies based on the minimum and maximum values of the raw scores of the terms in each of the vocabularies to obtain target scores for the terms in each of the vocabularies, and to determine weights of the terms in each of the vocabularies respectively; a push unit, configured to select a target term from the multiple vocabularies based on the target score and the weight, and push the target term to a target client; The processing unit is further configured to: group the terms in each vocabulary based on the original scores; and determine the weight of each term, wherein terms in the same group have the same weight.
7. A device for recommending entries, characterized in that: The system comprises a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by one or more processors, wherein the one or more programs include instructions for performing the following operations: Recalling multiple vocabularies based on a multi-way recall strategy, where the entries in each vocabularies have original scores; the multi-way recall strategy includes at least one of the following: a recall strategy based on a topic, a recall strategy based on a deep tree matching model, a recall strategy based on a word vector, a recall strategy based on a region, and a recall strategy based on a client; For each recalled vocabulary, based on the minimum and maximum values of the raw scores of the terms in each vocabulary, the raw scores of the terms in each vocabulary are normalized to obtain target scores for the terms in each vocabulary, and the weights of the terms in each vocabulary are determined respectively; Based on the target score and the weight, selecting a target term from the multiple vocabularies, and pushing the target term to a target client; The step of respectively determining the weights of the entries in each vocabulary includes: Based on the raw scores, grouping the entries in each vocabulary; The weight of each group of terms is determined, wherein terms in the same group have the same weight.
8. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
A method and device for obtaining a user lexicon
CN109669550A
Commodity recommendation method, device and equipment
CN111353836A