A user query recommendation method, device, electronic device and storage medium

By obtaining the user's preference weight and searching for query results in the corresponding preference sub-regions and adjacent areas, the problem that existing query methods cannot provide accurate and personalized recommendations is solved, and the accurate recommendation of personalized results that users are interested in is achieved.

CN114528478BActive Publication Date: 2025-06-10SOUTHERN UNIVERSITY OF SCIENCE AND TECHNOLOGY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210044512.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-14
Publication Date
2025-06-10
Estimated Expiration
2042-01-14

AI Technical Summary

Technical Problem

Existing query methods cannot provide both high accuracy and personalized recommendations for results, especially when user input is uncertain or inaccurate.

Method used

By receiving query conditions entered by the user, the user's preference weight is obtained and all search users' preference areas are split into multiple sub-regions. Search for preset number of query results in the corresponding sub-region and adjacent areas based on the user's preference weight, and return personalized recommendation results.

Benefits of technology

It realizes that even if the user's query terms are inaccurate, it can obtain accurate recommendations of personalized results with controllable number of search results and user interest.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114528478B_ABST
    Figure CN114528478B_ABST
Patent Text Reader

Abstract

The present invention is applicable to the field of computer technology, and provides a user query recommendation method, device, electronic device and storage medium. The method includes: receiving a query condition input by a current user, which includes a query object; obtaining a preference weight of the current user for the query object according to the query condition; obtaining preference regions of all search users for the query object; splitting the preference regions into multiple preference sub-regions; obtaining the preference sub-region where the preference weight of the current user is located; searching for a preset number of query results in the preference sub-region where the current user is located and its adjacent regions in ascending order of the distance to the preference weight of the current user; and returning the preset number of query results thus searched. In this way, even if the user's query term is inaccurate, it is possible to obtain an accurate recommendation of personalized results with a controllable number of retrieval results and that the user is interested in.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of computer technology, and in particular relates to a user query and recommendation method, device, electronic device, and storage medium. Background Art

[0002] In the era when the Internet is everywhere, through query retrieval, users can obtain many recommended results. Sometimes, none of the numerous recommended results may be what the user wants. Sometimes, only a few of the numerous recommended results are what the user wants, and the user needs to comprehensively consider various factors among a large number of recommended results to select the few that best meet the expectations, and these various factors often conflict with each other. If the user wants to obtain the results they want more accurately, they usually need to give more and more precise query conditions. However, users are often uncertain about which precise conditions to give during the retrieval process. More often, different people give the same retrieval conditions but want the same results. Currently, query retrieval websites or systems cannot recommend according to the interests of different people to achieve personalized results for each person.

[0003] Generally, there are two main factors that determine the most interesting solutions for users, namely sorting based on advantages and sorting based on utility. The common sorting based on advantages is Skyline query, which is a query method for a product data set that returns all products that are not dominated by other products. Skyline query does not require the user to input preference weights, that is, it does not require the user to input precise preference weights. However, the number of results returned by Skyline query is uncertain, and it may return a large number of results that users cannot handle, that is, the output size is uncontrollable, and Skyline query returns the same results for all users and cannot achieve personalized recommendation. The common query in decision support systems for data management is top-k query. This query method can recommend different products according to the preferences of different users based on the user's preference input, and the recommended results are the top k, and the results are controllable. However, this query method requires the user to input a precise preference weight and then returns results based on this preference weight.

[0004] Generally speaking, users do not clearly tell to what extent they have a certain preference during the retrieval process. Even many users may not be sure what they like themselves. What users want more is a relatively casual input query to obtain personalized recommended results that meet the user's interests and have controllable results. However, existing query methods, such as Skyline query and top-k query, cannot meet the user's needs simultaneously. Summary of the Invention

[0005] The object of the present invention is to provide a user query recommendation method, device, electronic device and storage medium, aiming to solve the problem that due to the inability of the existing technology to provide an effective search method, the accuracy of the results in the existing retrieval or query is not high.

[0006] On the one hand, the present invention provides a user query recommendation method, and the method includes the following steps:

[0007] Receive a query condition including a query object input by the current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0008] Obtain the preference areas of all search users for the query object, and split the preference areas into multiple preference sub-areas;

[0009] Obtain the preference sub-area where the preference weight of the current user is located, and search for a preset number of query results in the located preference sub-area and adjacent areas in ascending order of the distance to the preference weight of the current user, and return the preset number of query results found.

[0010] On the other hand, the present invention provides a user query recommendation device, and the device includes:

[0011] A weight acquisition unit, configured to receive a query condition including a query object input by the current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0012] A region splitting unit, configured to obtain the preference areas of all search users for the query object, and split the preference areas into multiple preference sub-areas; and

[0013] A result return unit, configured to obtain the preference sub-area where the preference weight of the current user is located, and search for a preset number of query results in the located preference sub-area and adjacent areas in ascending order of the distance to the preference weight of the current user, and return the preset number of query results found.

[0014] On the other hand, the present invention further provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, and when the processor executes the computer program, the steps of the user query recommendation method described above are implemented.

[0015] On the other hand, the present invention further provides a computer-readable storage medium, which stores a computer program, and when the computer program is executed by a processor, the steps of the user query recommendation method described above are implemented.

[0016] After receiving the query condition including the query object input by the current user, the present invention obtains the preference weight of the current user for the query object according to the query condition, obtains the preference regions of all search users for the query object, splits the preference regions into multiple preference sub-regions, obtains the preference sub-region where the preference weight of the current user is located, and searches for a preset number of query results in the located preference sub-region and adjacent regions in ascending order of the distance to the preference weight of the current user, and returns the preset number of searched query results. In this way, even if the user's query term is inaccurate, accurate recommendations of personalized results with a controllable number of retrieval results and of interest to the user can be obtained. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 is a flowchart of the implementation of the user query recommendation method provided in Embodiment 1 of the present invention;

[0018] Figure 2 is a schematic diagram of the preference region provided in Embodiment 1 of the present invention;

[0019] Figure 3 is a flowchart of the implementation of the user query recommendation method provided in Embodiment 2 of the present invention;

[0020] Figure 4 is a schematic structural diagram of the user query recommendation device provided in Embodiment 3 of the present invention;

[0021] Figure 5 is a schematic structural diagram of the user query recommendation device provided in Embodiment 4 of the present invention; and

[0022] Figure 6 is a schematic structural diagram of the electronic device provided in Embodiment 5 of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0023] In order to make the objectives, technical solutions and advantages of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0024] The following describes the specific implementation of the present invention in detail with reference to specific embodiments:

[0025] Example 1:

[0026] Figure 1 shows the implementation process of the user query recommendation method provided in Embodiment 1 of the present invention. For the sake of convenience of description, only the parts related to Embodiment 1 of the present invention are shown and are described in detail as follows:

[0027] In step S101, receive the query condition including the query object input by the current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0028] The embodiments of the present invention are applicable to electronic devices, such as personal computers, servers, etc. Specifically, they are applicable to data or information query software on electronic devices. The query condition input by the current user includes the query object. For example, when the user inputs "mobile phone", the mobile phone is the object to be queried. Further, the query condition may also include the preferences of the current user. For example, when the user queries, they can input or select the price, performance, hardware parameters, etc. of the mobile phone. At this time, the preference weight of the current user for the query object can be directly obtained from the query condition. The preference weight of the current user for the query object can be specifically represented by a preference weight vector. For example, the preference weights are combined to obtain a preference weight vector, and the sum of each element value in the preference weight vector is 1. Of course, the user may not input the preference weight when inputting the query condition. At this time, it can be obtained from the user preference weight pre-stored on the electronic device. For example, the user preference weight can be obtained from the query historical data of the current user.

[0029] Therefore, in a preferred embodiment, when obtaining the preference weight of the current user for the query object according to the query condition, obtain the preference weight vector of the current user for the query object from the query condition; or, obtain the preference weight vector of the current user for the query object pre-stored, so as to accurately recommend the query results preferred by the user subsequently.

[0030] In step S102, obtain the preference regions of all search users for the query object, and split the preference regions into multiple preference sub-regions;

[0031] Since all search users have different preferences when querying the query object, in the embodiments of the present application, obtain the preference weights of all search users for the query object, and the preference weights of all users can form a preference region. As an example, for example, when the preference of each user is represented by the vector u = (w1, w2) and w1 + w2 = 1, draw the points of the preference vectors of all users with coordinates, then the entire user region is the line segment w1 + w2 = 1, 0 <= w1 <= 1, as Figure 2 shown.

[0032] When splitting the preference region into multiple preference sub-regions, users with similar preferences can be grouped into one region. Correspondingly, it is to split the preference region into multiple preference sub-regions. In a preferred manner of the embodiment of the present invention, when splitting the preference region into multiple preference sub-regions, according to the preference weight vectors of all search users for the query object and the evaluation vectors of each candidate object corresponding to the query object, the evaluation value of each candidate object corresponding to the query object under each search user is calculated. The user preference weight vectors corresponding to the same candidate object and with the highest evaluation value ranking of this candidate object are divided into the same preference sub-region, so as to accurately divide the same or similar user preferences into the same preference sub-region. In this preferred manner, the preference weight of the user for the query object is represented by a preference weight vector, the candidate object is the candidate result returned when querying the query object, and the evaluation vector is the evaluation of each aspect or dimension of the candidate object by the manufacturer or user. For example, when the user's query object is a mobile phone, the candidate objects are iPhone, Huawei mobile phone, and Samsung mobile phone, and the evaluation dimensions of the mobile phone are performance and price. As an example, the evaluation vector of the iPhone can be expressed as p1=(0.7, 0.3), and this evaluation vector indicates that the performance score is 0.7 and the price score is 0.3. As an example, when calculating the evaluation value of each candidate object corresponding to the query object under each search user, for example, if the preference weight vector of a user for the query object is expressed as u1=(0.1, 0.9), and the evaluation vector of a queried candidate object is expressed as p1=(0.3, 0.7), then the evaluation value of the candidate object in the eyes of the user is (0.3, 0.7)·(0.1, 0.9)=0.3*0.1 + 0.7*0.9 = 0.66.

[0033] Specifically, when calculating the evaluation value of each candidate object corresponding to the query object under each search user and dividing the user preference weight vectors corresponding to the same candidate object and with the highest evaluation value ranking of this candidate object into the same preference sub-region, the preference weight vector of each search user (for the search object) is set as the unknown variable u (here, for the convenience of description, the user of a certain query object can be represented by a preference weight vector), the evaluation vector of the current candidate object (or product) is represented as the known vector p (here, for the convenience of description, the candidate object can be represented by an evaluation vector), and the other candidate objects are represented as P=(p1, p2,..., pn). A desired preference sub-region can be transformed into solving a system of inequality equations:

[0034] p*u >= p1*u,

[0035] p*u >= p2*u,

[0036] …,

[0037] p*u >= pn*u.

[0038] If the above system of inequality equations has a solution, it indicates that there exists a preference sub-region, and for all search users corresponding to this preference sub-region, there is the same candidate object that ranks first in terms of evaluation value when searching for the query object. If the above system of inequality equations has no solution, it indicates that there is no such same candidate object that ranks first in terms of evaluation value. After solving a system of the above inequality equations for each candidate object, a series of preference sub-regions are obtained, and each preference sub-region has its corresponding candidate object that ranks first.

[0039] In step S103, obtain the preference sub-region where the preference weight of the current user is located, and in the order of the distance from the preference weight of the current user from small to large, search for a preset number of query results in the preference sub-region where it is located and its adjacent regions, and return the preset number of query results found.

[0040] In an embodiment of the present invention, obtain the preference sub-region where the preference weight of the current user is located, and in the order of the distance from the preference weight of the current user from small to large, search for a preset number of query results in the preference sub-region where it is located and its adjacent regions, and return the preset number of query results found.

[0041] After receiving the query condition including the query object input by the current user in an embodiment of the present invention, obtain the preference weight of the current user for the query object according to the query condition, obtain the preference regions of all search users for the query object, split the preference regions into multiple preference sub-regions, obtain the preference sub-region where the preference weight of the current user is located, and in the order of the distance from the preference weight of the current user from small to large, search for a preset number of query results in the preference sub-region where it is located and its adjacent regions, and return the preset number of query results found. In this way, even if the user's query term is inaccurate, it is possible to obtain an accurate recommendation of personalized results with a controllable number of retrieval results and that the user is interested in.

[0042] Example 2:

[0043] Figure 3 The implementation process of the user query recommendation method provided in the second embodiment of the present invention is shown. For the sake of convenience of description, only the parts related to the embodiments of the present invention are shown and are described in detail as follows:

[0044] In step S301, receive the query condition including the query object input by the current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0045] In step S302, obtain the preference regions of all search users for the query object, and split the preference regions into multiple preference sub-regions;

[0046] In the embodiment of the present invention, the specific implementation manners of steps S301 - S302 may refer to the corresponding descriptions of steps S101 - S102 in Embodiment 1, which will not be elaborated herein.

[0047] In step S303, the multiple preference sub - regions obtained by splitting are defined as top - 1 type regions;

[0048] In the embodiment of the present invention, the type of each region (sub - region) is divided into top - i type, where i = 1,..., k, and k is a preset positive integer, that is, the types of regions include top - 1, top - 2,..., top - k. The top - 1 type region indicates that the region corresponds to the same candidate object with the first - ranked evaluation value for the user. The top - 2 type region is obtained by dividing the top - 1 type region, indicating that the region corresponds to the same candidate objects with the first - ranked and second - ranked evaluation values for the user, and so on. After the sub - regions obtained by splitting through step S302, the sub - regions obtained by the first division are defined or marked, and the multiple preference sub - regions obtained by splitting are defined as top - 1 type regions.

[0049] In step S304, the preference sub - region where the preference weight vector of the current user is located is put into the minimum heap, and the key value is the distance between the region and the preference weight vector of the current user;

[0050] In the embodiment of the present invention, a minimum heap is used to maintain the preference sub - regions. When the preference sub - region where the preference weight vector of the current user is located is put into the minimum heap, the minimum heap automatically sorts the entered elements to meet the structural requirements of the minimum heap. When calculating the distance between the region and the preference weight vector of the current user, specifically, if the region is a line segment, the distance between the line segment and the point of the preference weight vector of the current user can be calculated to calculate the distance between the region and the preference weight vector of the current user. If the region is three - dimensional, the distance between the polygon and the point can be calculated to calculate the distance between the region and the preference weight vector of the current user.

[0051] In step S305, the first element in the minimum heap is taken out;

[0052] In step S306, the type of the region corresponding to the first element in the minimum heap is judged;

[0053] In the embodiment of the present invention, after taking out the first element in the minimum heap, the type of the region corresponding to the element is judged. If the region type of the first element is top - 1, step S307 is executed. If the region type of the first element is top - i and i is not equal to 1 or k, step S308 is executed. If the region type of the first element is top - k, step S309 is executed.

[0054] In step S307, if the region type of the first element is the top-1 type, put other top-1 regions that are adjacent to the preferred sub-region of the first element and have not entered the min-heap into the min-heap.

[0055] In step S308, split the region of the first element into top-(i + 1) regions, and put the obtained top-(i + 1) regions into the min-heap;

[0056] In the embodiment of the present invention, if the region type of the first element is the top-1 type, execute step S307, then execute step S308, and then jump to step S305. That is, after executing step S307, split the region of the first element into top-(i + 1) regions, put the obtained top-(i + 1) regions into the min-heap, and the min-heap will automatically sort the elements put into the heap, and then jump to step S305. That is to say, after executing step S307, split the region of the first element into top-2 regions, put the obtained top-2 regions into the min-heap, and then turn to step S305.

[0057] If the region type of the first element is the top-i type and i is not equal to 1 or k, split the region of the first element into top-(i + 1) regions, put the obtained top-(i + 1) regions into the min-heap, and then jump to step S305.

[0058] In step S309, if the region type of the first element is the top-k type, put the k candidate objects of the region of the first element into the query result set;

[0059] In step S310, confirm whether the query result set includes a preset number of query results. If so, execute step S311 to return a preset number of query results to the current user; otherwise, jump to step S305.

[0060] In step S311, return a preset number of query results to the current user.

[0061] In the embodiment of the present invention, if the query result set includes a preset number of query results, it means that a preset number of query results have been searched. At this time, return a preset number of query results to the current user; otherwise, continue the search.

[0062] After receiving the query condition including the query object input by the current user in an embodiment of the present invention, the preference weight of the current user for the query object is obtained according to the query condition, the preference regions of all search users for the query object are obtained, the preference regions are split into multiple preference sub-regions, the preference sub-region where the preference weight of the current user is located is obtained, and a preset number of query results are searched in the preference sub-region where it is located and its adjacent regions in ascending order of the distance to the preference weight of the current user, and the preset number of searched query results are returned. In this way, even if the user's query term is inaccurate, accurate recommendations of personalized results with a controllable number of retrieval results and of interest to the user can be obtained.

[0063] Example 3:

[0064] Figure 4 Fig. shows the structure of the user query recommendation device provided in the third embodiment of the present invention. For the sake of convenience of description, only the parts related to the embodiment of the present invention are shown, including:

[0065] A weight acquisition unit 41, configured to receive a query condition including a query object input by a current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0066] A region splitting unit 42, configured to obtain the preference regions of all search users for the query object, and split the preference regions into multiple preference sub-regions; and

[0067] A result return unit 43, configured to obtain the preference sub-region where the preference weight of the current user is located, search a preset number of query results in the preference sub-region where it is located and its adjacent regions in ascending order of the distance to the preference weight of the current user, and return the preset number of searched query results.

[0068] In an embodiment of the present invention, each unit of the user query recommendation device can be implemented by corresponding hardware or software units. Each unit can be an independent software or hardware unit, or can be integrated into a software or hardware unit, which is not used to limit the present invention here. The specific implementation manners of each unit can refer to the description of Embodiment 1 and will not be elaborated here.

[0069] Example 4:

[0070] Figure 5 Fig. shows the structure of the user query recommendation device provided in the fourth embodiment of the present invention. For the sake of convenience of description, only the parts related to the embodiment of the present invention are shown, including:

[0071] A weight acquisition unit 51, configured to receive a query condition including a query object input by a current user, and obtain the preference weight of the current user for the query object according to the query condition;

[0072] A region splitting unit 52, configured to obtain the preference regions of all search users for a query object, and split the preference regions into multiple preference sub-regions; and

[0073] A result returning unit 53, configured to obtain the preference sub-region where the preference weight of the current user is located, search for a preset number of query results in the preference sub-region where it is located and adjacent regions in ascending order of the distance to the preference weight of the current user, and return the preset number of query results found.

[0074] Wherein, the weight obtaining unit 51 includes:

[0075] A first obtaining subunit 511, configured to obtain the preference weight vector of the current user for the query object from the query condition; or

[0076] A second obtaining subunit 512, configured to obtain the preference weight vector of the current user for the query object stored in advance.

[0077] The region splitting unit 52 includes:

[0078] A region splitting subunit 521, configured to calculate the evaluation value of each candidate object corresponding to the query object under each search user according to the preference weight vector of all search users for the query object and the evaluation vector of each candidate object corresponding to the query object, and divide the user preference weight vectors with the same candidate object and the highest ranking evaluation value of the candidate object into the same preference sub-region.

[0079] The result returning unit 53 includes:

[0080] A type defining unit 531, configured to define the multiple split preference sub-regions as top-1 type regions;

[0081] A first inserting unit 532, configured to put the preference sub-region where the preference weight vector of the current user is located into a minimum heap, and the key value is the distance between the region and the preference weight vector of the current user;

[0082] A taking-out unit 533, configured to take out the first element in the minimum heap. If the region type of the first element is top-1 type, put other top-1 regions that are adjacent to the preference sub-region of the first element and have not entered the minimum heap into the minimum heap, split the region of the first element into top-2 regions, put the split top-2 regions into the minimum heap, and trigger the taking-out unit to continue taking out the first element in the minimum heap;

[0083] A second insertion unit 534, configured to, if the region type of the first element is the top-i type and i is not equal to 1 or k, split the region of the first element into a top-(i + 1) region, place the obtained top-(i + 1) region into the min-heap, and trigger the extraction unit to continue extracting the first element from the min-heap;

[0084] A result feedback unit 535, configured to, if the region type of the first element is the top-k type, place the k candidate objects of the region of the first element into the query result set, confirm whether the query result set includes a preset number of query results, if so, return the preset number of query results, otherwise trigger the extraction unit to continue extracting the first element from the min-heap.

[0085] In the embodiments of the present invention, each unit of the user query recommendation device may be implemented by corresponding hardware or software units. Each unit may be an independent software or hardware unit, or may be integrated into a software or hardware unit, which is not intended to limit the present invention herein. The specific implementation manners of each unit may refer to the description of Embodiment 2 and will not be elaborated herein.

[0086] Example 5:

[0087] Figure 6 FIG. shows the structure of an electronic terminal provided in Embodiment 5 of the present invention. For ease of description, only parts related to the embodiments of the present invention are shown.

[0088] The electronic terminal 6 in the embodiments of the present invention includes a processor 60, a memory 61, and a computer program 62 stored in the memory 61 and executable on the processor 60. When the processor 60 executes the computer program 62, the steps in the above-mentioned method embodiments of the user query recommendation method are implemented, for example Figure 1 the steps S101 to S103 shown. Alternatively, when the processor 60 executes the computer program 62, the functions of each unit in the above-mentioned device embodiments are implemented, for example Figure 4 the functions of the units 41 to 43 shown.

[0089] The electronic device in the embodiments of the present invention may be a personal computer or a server. The steps implemented when the processor 60 in the electronic device 6 executes the computer program 62 to implement the user query recommendation method may refer to the description of the foregoing method embodiments and will not be elaborated herein.

[0090] Example 5:

[0091] In the embodiments of the present invention, a computer-readable storage medium is provided. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the above-mentioned method embodiments of the user query recommendation method are implemented. For example, Figure 1Steps S101 to S103 shown. Alternatively, when the computer program is executed by a processor, it implements the functions of each unit in the above device embodiments, for example Figure 4 the functions of units 41 to 43 shown.

[0092] The computer-readable storage medium of the embodiments of the present invention may include any entity or device, recording medium that can carry computer program code, for example, memories such as ROM / RAM, magnetic disks, optical disks, flash memories, etc.

[0093] The above are only the preferred embodiments of the present invention and are not intended to limit the present invention. Any modifications, equivalent replacements, and improvements made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.

Claims

1. A user query recommendation method, characterized in that, the method comprises the following steps: Receiving a query condition including a query object input by a current user, and obtaining a preference weight of the current user for the query object according to the query condition; Obtaining preference regions of all search users for the query object, and splitting the preference regions into a plurality of preference sub-regions; Obtaining a preference sub-region where the preference weight of the current user is located, and searching for a preset number of query results in the preference sub-region where the preference weight of the current user is located and adjacent regions in ascending order of the distance to the preference weight of the current user, and returning the preset number of query results found; The step of searching for a preset number of query results in the preference sub-region where the preference weight of the current user is located and adjacent regions in ascending order of the distance to the preference weight of the current user and returning the query results to the current user includes: Defining the plurality of preference sub-regions obtained by splitting as top-1 type regions; Putting the preference sub-region where the preference weight vector of the current user is located into a minimum heap, and the key value is the distance between the region and the preference weight vector of the current user; Taking out the first element in the minimum heap, if the region type of the first element is top-1 type, putting other top-1 regions adjacent to the preference sub-region of the first element and not entered into the minimum heap into the minimum heap, splitting the region of the first element into top-2 regions, putting the split top-2 regions into the minimum heap, and jumping to the step of taking out the first element in the minimum heap; If the region type of the first element is top-i type and i is not equal to 1 or k, splitting the region of the first element into top-(i + 1) regions, putting the split top-(i + 1) regions into the minimum heap, and jumping to the step of taking out the first element in the minimum heap; If the region type of the first element is top-k type, putting k candidate objects in the region of the first element into a query result set, confirming whether the query result set includes the preset number of query results, if so, returning the preset number of query results, otherwise jumping to the step of taking out the first element in the minimum heap.

2. The method according to claim 1, characterized in that, the step of obtaining a preference weight of the current user for the query object according to the query condition includes: Obtaining a preference weight vector of the current user for the query object from the query condition; or Obtaining a preference weight vector of the current user for the query object stored in advance.

3. The method according to claim 1, characterized in that, the step of splitting the preference regions into a plurality of preference sub-regions includes: According to the preference weight vectors of all the search users for the query object and the evaluation vectors of each candidate object corresponding to the query object, calculate the evaluation value of each candidate object corresponding to the query object for each search user, and divide the user preference weight vectors with the same candidate object and the highest-ranked evaluation value of this candidate object into the same preference sub-region.

4. A user query recommendation device, characterized in that, the device includes: a weight acquisition unit, configured to receive a query condition including a query object input by a current user, and acquire the preference weight of the current user for the query object according to the query condition; a region splitting unit, configured to acquire the preference regions of all search users for the query object, and split the preference regions into multiple preference sub-regions; and a result return unit, configured to acquire the preference sub-region where the preference weight of the current user is located, search for a preset number of query results in the preference sub-region where it is located and adjacent regions in ascending order of the distance to the preference weight of the current user, and return the preset number of query results found; the result return unit includes: a type definition unit, configured to define the multiple preference sub-regions obtained by splitting as top-1 type regions; a first insertion unit, configured to put the preference sub-region where the preference weight vector of the current user is located into a minimum heap, and the key value is the distance between this region and the preference weight vector of the current user; a fetching unit, configured to fetch the first element in the minimum heap. If the region type of the first element is top-1 type, put other top-1 regions that are adjacent to the preference sub-region of the first element and have not entered the minimum heap into the minimum heap, split the region of the first element into top-2 regions, put the split top-2 regions into the minimum heap, and trigger the fetching unit to continue fetching the first element in the minimum heap; a second insertion unit, configured to if the region type of the first element is top-i type and i is not equal to 1 or k, split the region of the first element into top-(i + 1) regions, put the split top-(i + 1) regions into the minimum heap, and trigger the fetching unit to continue fetching the first element in the minimum heap; a result feedback unit, configured to if the region type of the first element is top-k type, put the k candidate objects of the region of the first element into the query result set, confirm whether the preset number of query results is included in the query result set. If so, return the preset number of query results, otherwise trigger the fetching unit to continue fetching the first element in the minimum heap.

5. The device according to claim 4, characterized in that, the weight acquisition unit includes: a first acquisition subunit, configured to acquire the preference weight vector of the current user for the query object from the query condition; or a second acquisition subunit, configured to acquire the preference weight vector of the current user for the query object stored in advance.

6. The device according to claim 4, It is characterized in that The area splitting unit includes: An area splitting sub-unit, configured to calculate the evaluation value of each candidate object corresponding to the query object under each search user according to the preference weight vector of all search users for the query object and the evaluation vector of each candidate object corresponding to the query object, and divide the corresponding user preference weight vectors with the same candidate object and the highest-ranked evaluation value of this candidate object into the same preference sub-region.

7. An electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, It is characterized in that When the processor executes the computer program, the steps of the method according to any one of claims 1 to 3 are implemented.

8. A computer-readable storage medium storing a computer program, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 3 are implemented.

Citation Information

Patent Citations

  • Query term recommending method and query term recommending system

    CN103870505A

  • A preference space Skyline query processing method based on a Spark environment

    CN109947904A