Point of interest search method and apparatus, electronic device, and readable storage medium

CN116501952BActive Publication Date: 2026-08-18丰图科技(深圳)有限公司
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210074546.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-01-21
Publication Date
2026-08-18
Estimated Expiration
2042-01-21

AI Technical Summary

Technical Problem

[0004]本申请提供一种兴趣点搜索方法、装置、电子设备及可读存储介质,旨在解决目前的兴趣点搜索方法未考虑到用户的语义习惯,因此准确度不高的问题

Benefits of technology

[0062]In summary, the point-of-interest (POI) search method provided in this application includes: obtaining input text to be searched, wherein the input text includes a first POI name and a second POI name; retrieving the first POI name and the second POI name from the input text to obtain a first reference POI and a second reference POI; and outputting a target POI among the first reference POI and the second reference POI based on the distance between them. On one hand, the POI search method provided in this application, when the input text to be searched contains both a first POI name and a second POI name, simultaneously retrieves both names and determines the output target POI by combining the retrieval results of the first and second POI names. Compared to methods that only select one POI name from the first and second POI names for retrieval, or directly retrieve based on the input text, the output results are more accurate. On the other hand, the point of interest search method provided in this application uses the distance between the first reference point of interest and the second reference point of interest as a filtering condition to determine the target point of interest, which is more in line with the semantic habit of users to use other points of interest around the search target as references when conducting point of interest search, and thus can further improve the accuracy of the output results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116501952B_ABST
    Figure CN116501952B_ABST
Patent Text Reader

Abstract

The application discloses a point-of-interest search method and device, electronic equipment and a readable storage medium. On the one hand, when the input text to be searched contains a first point-of-interest name and a second point-of-interest name, the first point-of-interest name and the second point-of-interest name are searched simultaneously, and the target point-of-interest is determined in combination with the search result of the first point-of-interest name and the search result of the second point-of-interest name. Compared with the method of selecting one of the first point-of-interest name and the second point-of-interest name to search or directly searching according to the input text, the output result is more accurate. On the other hand, the distance between the first reference point-of-interest and the second reference point-of-interest is used as a screening condition to determine the target point-of-interest, which is more in line with the semantic habit of a user taking other point-of-interests around the search target as a reference when searching for a point-of-interest, and therefore the accuracy of the output result can be further improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of electronic map technology, specifically to a point of interest search method, apparatus, electronic device, and readable storage medium. Background Technology

[0002] Electronic maps installed on terminals can provide users with convenient map guidance services. For example, based on keywords entered by the user, the electronic map can display points of interest (POIs) corresponding to those keywords at the relevant locations on the map as guidance.

[0003] Current methods for searching points of interest typically treat the user's input text as a point of interest, compare its similarity with preset points of interest, and select the output point of interest based on the similarity comparison results. This method does not take into account the user's semantic habits, and therefore has low accuracy. Summary of the Invention

[0004] This application provides a method, apparatus, electronic device, and readable storage medium for searching points of interest, aiming to solve the problem that current methods for searching points of interest do not take into account users' semantic habits, resulting in low accuracy.

[0005] Firstly, this application provides a method for searching points of interest, including:

[0006] Obtain the input text to be searched, wherein the input text includes a first point of interest name and a second point of interest name;

[0007] The first and second point of interest names are retrieved respectively to obtain the first reference point of interest and the second reference point of interest;

[0008] Based on the distance between the first reference point of interest and the second reference point of interest, output the target point of interest among the first reference point of interest and the second reference point of interest.

[0009] In one possible implementation of this application, the step of retrieving the first point of interest name and the second point of interest name respectively to obtain the first reference point of interest and the second reference point of interest includes:

[0010] Extract the name of the first point of interest and the name of the second point of interest;

[0011] Query the first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name, respectively;

[0012] Based on the first point of interest type and the second point of interest type, the first point of interest name and the second point of interest name are retrieved respectively to obtain the first reference point of interest and the second reference point of interest.

[0013] In one possible implementation of this application, the point of interest type includes linked types and non-linked types;

[0014] The step of retrieving the first point of interest name and the second point of interest name according to the first point of interest type and the second point of interest type respectively to obtain the first reference point of interest and the second reference point of interest includes:

[0015] If the first point of interest type and the second point of interest type are different, then the point of interest type that is the non-linked type is retrieved to obtain the non-linked point of interest.

[0016] Based on the preset search distance and the location of the non-chained points of interest, the surrounding points of interest of the non-chained points of interest are determined, wherein the distance between the location of the surrounding points of interest and the location of the non-chained points of interest is less than or equal to the search distance.

[0017] Among the surrounding points of interest, the names of points of interest of type chain are retrieved to obtain chain points of interest;

[0018] The non-linked points of interest and the linked points of interest are set as the first reference point of interest and the second reference point of interest, respectively.

[0019] In one possible implementation of this application, the method further includes:

[0020] If the first point of interest type and the second point of interest type are the same, then the number of points of interest corresponding to the point of interest type is selected from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type, wherein the first preset number is greater than the second preset number;

[0021] The first and second point of interest names are retrieved to obtain the first and second reference points of interest, respectively, representing the number of points of interest.

[0022] In one possible implementation of this application, the step of outputting the target interest point between the first reference interest point and the second reference interest point based on the distance between the first reference interest point and the second reference interest point includes:

[0023] Obtain the Cartesian product combination between each of the first reference interest points and each of the second reference interest points;

[0024] Based on the distance between the first reference interest point and the second reference interest point in each of the Cartesian product combinations, determine the target combination with the shortest distance;

[0025] Select target points of interest from the target combination and output them.

[0026] In one possible implementation of this application, the step of selecting and outputting target interest points from the target combination includes:

[0027] If the preset database contains the area occupied by each candidate point of interest in the target combination, then the candidate point of interest with the smaller area is output as the target point of interest.

[0028] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the target point of interest is selected from the target combination and output according to the point of interest type of each candidate point of interest.

[0029] In one possible implementation of this application, the step of selecting and outputting target interest points from the target combination based on the interest point type of each candidate interest point if the preset database does not contain the area occupied by each candidate interest point in the target combination includes:

[0030] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the point of interest type of each candidate point of interest is compared, wherein the point of interest type includes chain type and non-chain type;

[0031] If all the interest points are of the same type, then according to the semantic order of each candidate interest point in the input text, the candidate interest point with the later semantic order is set as the target interest point.

[0032] If the types of interest points are different, the candidate interest point of the chain type will be output as the target interest point.

[0033] Secondly, this application provides a point-of-interest (POI) search device, comprising:

[0034] The acquisition module is used to acquire the input text to be searched, wherein the input text includes a first point of interest name and a second point of interest name;

[0035] The retrieval module is used to retrieve the first point of interest name and the second point of interest name respectively, and obtain the first reference point of interest and the second reference point of interest;

[0036] The output module is used to output the target interest point between the first reference interest point and the second reference interest point based on the distance between the first reference interest point and the second reference interest point.

[0037] In one possible implementation of this application, the retrieval module is further configured to:

[0038] Extract the name of the first point of interest and the name of the second point of interest;

[0039] Query the first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name, respectively;

[0040] Based on the first point of interest type and the second point of interest type, the first point of interest name and the second point of interest name are retrieved respectively to obtain the first reference point of interest and the second reference point of interest.

[0041] In one possible implementation of this application, the retrieval module is further configured to:

[0042] If the first point of interest type and the second point of interest type are different, then the point of interest type that is the non-linked type is retrieved to obtain the non-linked point of interest.

[0043] Based on the preset search distance and the location of the non-chained points of interest, the surrounding points of interest of the non-chained points of interest are determined, wherein the distance between the location of the surrounding points of interest and the location of the non-chained points of interest is less than or equal to the search distance.

[0044] Among the surrounding points of interest, the names of points of interest of type chain are retrieved to obtain chain points of interest;

[0045] The non-linked points of interest and the linked points of interest are set as the first reference point of interest and the second reference point of interest, respectively.

[0046] In one possible implementation of this application, the retrieval module is further configured to:

[0047] If the first point of interest type and the second point of interest type are the same, then the number of points of interest corresponding to the point of interest type is selected from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type, wherein the first preset number is greater than the second preset number;

[0048] The first and second point of interest names are retrieved to obtain the first and second reference points of interest, respectively, representing the number of points of interest.

[0049] In one possible implementation of this application, the output module is further used for:

[0050] Obtain the Cartesian product combination between each of the first reference interest points and each of the second reference interest points;

[0051] Based on the distance between the first reference interest point and the second reference interest point in each of the Cartesian product combinations, determine the target combination with the shortest distance;

[0052] Select target points of interest from the target combination and output them.

[0053] In one possible implementation of this application, the output module is further used for:

[0054] If the preset database contains the area occupied by each candidate point of interest in the target combination, then the candidate point of interest with the smaller area is output as the target point of interest.

[0055] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the target point of interest is selected from the target combination and output according to the point of interest type of each candidate point of interest.

[0056] In one possible implementation of this application, the output module is further used for:

[0057] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the point of interest type of each candidate point of interest is compared, wherein the point of interest type includes chain type and non-chain type;

[0058] If all the interest points are of the same type, then according to the semantic order of each candidate interest point in the input text, the candidate interest point with the later semantic order is set as the target interest point.

[0059] If the types of interest points are different, the candidate interest point of the chain type will be output as the target interest point.

[0060] Thirdly, this application also provides an electronic device, which includes a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor calls the computer program in the memory, it executes the steps in any of the point of interest search methods provided in this application.

[0061] Fourthly, this application also provides a readable storage medium storing a computer program, which, when executed by a processor, implements the steps in any of the point of interest search methods provided in this application.

[0062] In summary, the point-of-interest (POI) search method provided in this application includes: obtaining input text to be searched, wherein the input text includes a first POI name and a second POI name; retrieving the first POI name and the second POI name from the input text to obtain a first reference POI and a second reference POI; and outputting a target POI among the first reference POI and the second reference POI based on the distance between them. On one hand, the POI search method provided in this application, when the input text to be searched contains both a first POI name and a second POI name, simultaneously retrieves both names and determines the output target POI by combining the retrieval results of the first and second POI names. Compared to methods that only select one POI name from the first and second POI names for retrieval, or directly retrieve based on the input text, the output results are more accurate. On the other hand, the point of interest search method provided in this application uses the distance between the first reference point of interest and the second reference point of interest as a filtering condition to determine the target point of interest, which is more in line with the semantic habit of users to use other points of interest around the search target as references when conducting point of interest search, and thus can further improve the accuracy of the output results. Attached Figure Description

[0063] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0064] Figure 1 This is a schematic diagram illustrating an application scenario of the point of interest search method provided in the embodiments of this application;

[0065] Figure 2 This is a flowchart illustrating a point-of-interest search method provided in an embodiment of this application;

[0066] Figure 3 This is a schematic diagram of a process for obtaining a first reference point of interest and a second reference point of interest, provided in an embodiment of this application.

[0067] Figure 4 The electronic ground provided in the embodiments of this application Figure 1 A schematic diagram;

[0068] Figure 5 This is another schematic diagram of the electronic map provided in the embodiments of this application;

[0069] Figure 6This is a schematic diagram of an embodiment of the point of interest search device provided in this application.

[0070] Figure 7 This is a schematic diagram of an embodiment of the electronic device provided in this application. Detailed Implementation

[0071] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0072] In the description of the embodiments of this application, it should be understood that the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Therefore, features defined with "first" and "second" may explicitly or implicitly include one or more of the stated features. In the description of the embodiments of this application, "multiple" means two or more, unless otherwise explicitly specified.

[0073] To enable any person skilled in the art to implement and use this application, the following description is provided. In this description, details are set forth for purposes of explanation. It should be understood that those skilled in the art will recognize that this application can be implemented without using these specific details. In other instances, well-known processes will not be described in detail to avoid obscuring the description of the embodiments of this application with unnecessary detail. Therefore, this application is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed in the embodiments of this application.

[0074] This application provides a method, apparatus, electronic device, and readable storage medium for searching points of interest. The point of interest searching apparatus can be integrated into an electronic device, which may be a server or a terminal, etc.

[0075] The execution subject of the point of interest search method in this application embodiment can be the point of interest search device provided in this application embodiment, or different types of electronic devices such as server equipment, physical host, or user equipment (UE) that integrate the point of interest search device. The point of interest search device can be implemented in hardware or software. The UE can be a terminal device such as a smartphone, tablet computer, laptop computer, handheld computer, desktop computer, or personal digital assistant (PDA).

[0076] The electronic device can operate independently or in a cluster.

[0077] See Figure 1 , Figure 1 This is a schematic diagram of a scenario for the point-of-interest (POI) search system provided in an embodiment of this application. The POI search system may include an electronic device 101, which integrates a POI search device.

[0078] In addition, such as Figure 1 As shown, the point of interest search system may also include a memory 102 for storing data, such as text data.

[0079] It should be noted that, Figure 1 The schematic diagram of the point-of-interest search system shown is merely an example. The point-of-interest search system and scenario described in this application embodiment are for the purpose of more clearly illustrating the technical solutions of this application embodiment and do not constitute a limitation on the technical solutions provided in this application embodiment. As those skilled in the art will know, with the evolution of point-of-interest search systems and the emergence of new business scenarios, the technical solutions provided in the embodiments of this invention are also applicable to similar technical problems.

[0080] The following describes the point of interest (POI) search method provided in the embodiments of this application. In this embodiment, an electronic device is used as the execution subject. For simplicity and ease of description, the execution subject will be omitted in the subsequent method embodiments. The POI search includes: obtaining the input text to be searched, wherein the input text includes a first POI name and a second POI name; retrieving the first POI name and the second POI name respectively to obtain a first reference POI and a second reference POI; and outputting the target POI among the first reference POI and the second reference POI based on the distance between the first reference POI and the second reference POI.

[0081] Reference Figure 2 , Figure 2 This is a flowchart illustrating a point-of-interest (POI) search method provided in an embodiment of this application. It should be noted that although the logical order is shown in the flowchart, in some cases, the steps shown or described may be performed in a different order than that shown here. Specifically, the POI search method may include the following steps 201-203, wherein:

[0082] 201. Obtain the input text to be searched, wherein the input text includes the first point of interest name and the second point of interest name.

[0083] In this embodiment of the application, the input text can refer to the text entered by the user into the electronic device. The input text includes two point-of-interest (POI) names: a first POI name and a second POI name. A POI refers to a geographic entity object abstracted into a point, such as a school, bank, restaurant, gas station, hospital, supermarket, etc. The information of a POI can include its name, geographical location, etc.

[0084] In this embodiment of the application, the point of interest name can be the brand name of the point of interest or an alias of the point of interest, where an alias refers to a conventional, informal name. For example, when a user wants to search for a McDonald's near Walmart, they can enter "McDonald's Walmart" or "Walmart McDonald's", or they can enter "Golden Arches Walmart" or "Walmart Golden Arches", where "Golden Arches" and "McDonald's" correspond to the brand name and alias of the same point of interest, respectively.

[0085] In this embodiment, the order of the first point of interest (POI) name and the second POI name in the input text is not limited. For example, the POI name that appears first in the input text can be used as the first POI name, and the POI name that appears later in the input text can be used as the second POI name. Alternatively, the POI name that appears first in the input text can be used as the second POI name, and the POI name that appears later in the input text can be used as the first POI name.

[0086] For example, users can input the search text into an electronic device via voice, text, or other means. For instance, if a user wants to search for a McDonald's near Walmart, they can enter "McDonald's Walmart" or "Walmart McDonald's" into a map search app on their smartphone using the touchscreen keyboard. The entered text is "McDonald's Walmart" or "Walmart McDonald's". If "McDonald's Walmart" is entered, the first and second points of interest can be "McDonald's" and "Walmart" respectively, or vice versa.

[0087] 202. Search for the first point of interest name and the second point of interest name respectively to obtain the first reference point of interest and the second reference point of interest.

[0088] In some embodiments, the input text can be segmented to extract the first point of interest (POI) name and the second POI name, and then the first POI name and the second POI name can be retrieved respectively. For example, the open-source jieba segmentation model or the LAC (Lexical Analysis of Chinese) segmentation model can be used to segment the input to obtain the first POI name and the second POI name.

[0089] The jieba word segmentation model can perform word segmentation, part-of-speech tagging, keyword extraction, and other functions on Chinese text, and also supports custom dictionaries.

[0090] The LAC word segmentation model is a joint lexical analysis model that holistically completes Chinese word segmentation, part-of-speech tagging, and proper noun recognition tasks.

[0091] After obtaining the first point of interest name and the second point of interest name, you can search for the first point of interest name and the second point of interest name in the preset database to obtain the first reference point of interest and the second reference point of interest.

[0092] The preset database stores information on multiple preset points of interest (POIs) obtained through pre-collection. For example, information on all geographic entities such as schools, banks, restaurants, gas stations, hospitals, and supermarkets can be collected manually, and the names, locations, and other information corresponding to each geographic entity can be stored in the preset database to obtain the names, locations, and other information of the corresponding preset POIs. In this embodiment, the location of a POI refers to the actual location of the geographic entity corresponding to the POI. The preset database can refer to the backend database of the map search software, which stores the information of each geographic entity obtained through pre-collection, i.e., the information of multiple preset POIs.

[0093] Both the first and second reference points of interest are points of interest selected from a set of preset points of interest after a search. It can be understood that the first reference point of interest refers to the point of interest that matches the name of the first preset point of interest, and the second reference point of interest refers to the point of interest that matches the name of the second preset point of interest. For example, if the first point of interest is named "McDonald's" and the second point of interest is named "Walmart," then the first reference point of interest refers to the preset point of interest that matches "McDonald's," and the second reference point of interest refers to the preset point of interest that matches "Walmart." Here, a preset point of interest matching a point of interest name means that the information of that preset point of interest contains the matching point of interest name.

[0094] In some embodiments, a first similarity and a second similarity can be calculated between the first point of interest name, the second point of interest name and the information of each preset point of interest, and then a first reference point of interest can be selected from the preset points of interest based on the first similarity and a second reference point of interest can be selected from the preset points of interest based on the second similarity.

[0095] For example, the first and second point-of-interest (POI) names can be converted according to the storage format of the information of each POI in the preset database. Then, the converted first and second POI names are compared with the information of each POI in the preset database to calculate the first and second similarities. For instance, if the information of each POI in the preset database is stored in the form of hash values, the first and second POI names can be converted into a first and a second hash value, respectively. The first hash value is then compared with the hash values ​​corresponding to the information of each POI in the preset database to obtain the first similarity. The second hash value is then compared with the hash values ​​corresponding to the feature information of each POI in the preset database to obtain the second similarity.

[0096] A hash value is a byte array obtained through a preset hash function, which can be used to distinguish different inputs: if the inputs are different, the hash values ​​obtained are different; if the inputs are the same, the hash values ​​obtained are the same.

[0097] In this embodiment, one or more first reference points of interest can be selected from each preset point of interest based on a preset number of points of interest and a first similarity. Similarly, one or more second reference points of interest can be selected from each preset point of interest based on a preset number of points of interest and a second similarity. The number of points of interest refers to the number of each of the first and second reference points of interest when selecting them. The preset number of points of interest can be set according to actual needs. For example, to improve the speed of outputting the target point of interest, a smaller number of points of interest can be set to reduce the retrieval time when searching for the names of the first and second points of interest, thus outputting the target point of interest to the user as quickly as possible and improving the user's search experience. For instance, the number of points of interest can be set to 10, i.e., selecting 10 first reference points of interest and 10 second reference points of interest respectively.

[0098] The following example illustrates the process of obtaining the first and second reference interest points. Assuming there are 10 interest points, we can first sort them from highest to lowest according to their first similarity to obtain a sequence of first interest points. Then, we select the top 10 interest points with the highest first similarity as the first reference interest points. Similarly, we can first sort them from highest to lowest according to their second similarity to obtain a sequence of second interest points. Then, we select the top 10 interest points with the highest second similarity as the second reference interest points.

[0099] It should be noted that the above retrieval methods are merely illustrative examples for ease of understanding and should not be construed as limiting the embodiments of this application. For example, those skilled in the art can modify the number of points of interest accordingly, or when the information of each preset point of interest in the preset database is stored in the form of feature vectors, the first point of interest name and the second point of interest name can be converted into corresponding feature vectors respectively, and then the first similarity and the second similarity can be calculated, etc., without going into details.

[0100] 203. Based on the distance between the first reference point of interest and the second reference point of interest, output the target point of interest between the first reference point of interest and the second reference point of interest.

[0101] The distance between the first reference point of interest and the second reference point of interest refers to the shortest physical distance between their locations. This distance can be the actual distance or the distance on an electronic map, and this embodiment does not impose any limitations on this. For ease of explanation, unless otherwise specified, the distance will be considered as the distance on an electronic map in the following text.

[0102] The target interest point refers to the interest point output to the user from the first reference interest point and the second reference interest point, that is, the preset interest point that the user intends to search.

[0103] The reason for determining the target point of interest based on distance is that when the input text contains both a first point of interest name and a second point of interest name, the user's purpose is usually to use a preset point of interest corresponding to one of the point of interest names as a constraint to accurately describe the preset point of interest corresponding to the other point of interest name. For example, when the input text is "Walmart McDonald's", the user's purpose is to use the preset point of interest "Walmart" as a geographical constraint to search for another preset point of interest "McDonald's". That is, the target point of interest is a preset point of interest whose location is near the preset point of interest "Walmart" and whose corresponding information contains "McDonald's". Therefore, the target point of interest can be accurately selected based on the distance between the first reference point of interest and the second reference point of interest. Here, the meaning of the preset point of interest "Walmart" is that the information of the preset point of interest contains "Walmart". This will not be elaborated further for this example and other points of interest below.

[0104] As can be seen, the point of interest search method provided in this application simultaneously determines the output target point of interest based on the search results of the first point of interest name and the search results of the second point of interest name in the input text, i.e., the first reference point of interest and the second reference point of interest. Compared with the traditional method that only searches for one of the first and second point of interest names, the obtained target point of interest is more accurate. The following examples compare the method provided in this application with the traditional method for specific illustration:

[0105] In traditional methods, considering users' semantic habits, the point of interest name that appears last in the semantic order of the input text is usually used as the point of interest name to be retrieved. However, if the user does not enter the input text according to this rule, the output results will be inaccurate. For example, if the user's search target is McDonald's in Walmart, and the input text is "McDonald's Walmart", the traditional method will ultimately output the preset point of interest "Walmart". However, the method provided in this application will not have this effect because it determines the output target point of interest based on the search results of the first point of interest name and the search results of the second point of interest name in the input text.

[0106] In another traditional method, the input text is directly treated as a point of interest (POI) name for searching. For example, if a user's search target is McDonald's within Walmart, and the input text is "McDonald's Walmart," the search will look for "McDonald's Walmart." In this case, if none of the preset POIs contain information for both "McDonald's" and "Walmart"—for example, if the location corresponding to a preset POI whose name contains "McDonald's" does not contain "Walmart," or if there are no preset POIs whose name / location contains both "McDonald's" and "Walmart"—the output results will be inaccurate. However, the method provided in this application retrieves the first POI name and the second POI name separately, obtaining the first reference POI and the second reference POI corresponding to each of the first and second POI names, and then selects the target POI from the first and second reference POIs. Therefore, this effect will not occur.

[0107] In some embodiments, each first reference point of interest and each second reference point of interest can be combined to obtain all possible combinations of interest points. Then, based on the distance between the first and second reference points of interest in each combination, the target interest point combination with the shortest distance is determined, and the target interest point is selected from the target interest point combinations. In this case, the step "outputting the target interest point among the first and second reference points of interest based on the distance between the first and second reference points of interest" can be implemented in the following way:

[0108] (i) Obtain the Cartesian product combination between each of the first reference interest points and each of the second reference interest points.

[0109] The process of calculating the Cartesian product refers to pairing the elements in two sets to be processed to obtain all possible element pairs. For example, when the set to be processed is A = {a, b, c} and the set to be processed is B = {0, 1, 2}, the Cartesian product of the two sets to be processed is {(a, 0), (a, 1), (a, 2), (b, 0), (b, 1), (b, 2), (c, 0), (c, 1), (c, 2)}. A Cartesian product combination refers to the elements in a Cartesian product. Taking the Cartesian product {(a, 0), (a, 1), (a, 2), (b, 0), (b, 1), (b, 2), (c, 0), (c, 1), (c, 2)} as an example, it contains nine Cartesian product combinations: (a, 0), (a, 1), (a, 2), (b, 0), (b, 1), (b, 2), (c, 0), (c, 1), (c, 2). Understandably, in this step, the set to be processed, A, can be a set composed of the first reference points of interest, and the set to be processed, B, can be a set composed of the second reference points of interest. The number of elements in set A should be the same as the number of first reference points of interest, and the number of elements in set B should be the same as the number of second reference points of interest.

[0110] (ii) Determine the target combination with the shortest distance based on the distance between the first reference interest point and the second reference interest point in each of the Cartesian product combinations.

[0111] In some embodiments, a map coordinate system can be first established on a preset electronic map. Then, the positions of each first reference point of interest and each second reference point of interest are projected onto the map coordinate system to obtain the map coordinates corresponding to each first reference point of interest and each second reference point of interest. The distance between the first reference point of interest and the second reference point of interest in each Cartesian product combination is calculated based on the map coordinates to obtain the target combination with the shortest distance. Here, the electronic map can refer to the map in map search software that includes a point of interest search function. Users can download electronic maps through app stores on their smartphones or other means.

[0112] (iii) Select target points of interest from the target combination and output them.

[0113] In some embodiments, if the preset database stores information on the area occupied by each preset point of interest, a target point of interest can be selected and output based on the area occupied by the first and second reference points of interest in the target combination. If the preset database does not store information on the area occupied by each preset point of interest, a target point of interest can be selected and output based on the brand chain status of the first and second reference points of interest in the target combination. In this case, the step "selecting and outputting a target point of interest from the target combination" can be implemented in the following way:

[0114] (1) If the preset database contains the area occupied by each candidate point of interest in the target combination, then the candidate point of interest with the smaller area is output as the target point of interest.

[0115] Among them, the candidate points of interest include the first reference point of interest and the second reference point of interest in the target combination. For ease of explanation, the candidate point of interest corresponding to the first reference point of interest will be referred to as the first candidate point of interest, and the candidate point of interest corresponding to the second reference point of interest will be referred to as the second candidate point of interest. The area occupied by each candidate point of interest refers to the area occupied by the geographic entity object corresponding to each candidate point of interest. It can be obtained by field measurement when collecting data on each geographic entity object manually and stored in a preset database. When executing step (1), the electronic device can read the area occupied by each candidate point of interest in the target combination from the preset database.

[0116] For example, the area occupied by a candidate point of interest can refer to either the specific area value of the candidate point of interest or the level corresponding to the area value of the candidate point of interest among multiple preset area levels. For example, when the area occupied by the first candidate point of interest is 100 square meters, the area occupied by the first candidate point of interest can be 100 square meters. If multiple preset area levels are preset, such as [0, 50 square meters], (50 square meters, 200 square meters], and (200 square meters, +∞), corresponding to preset area level A, preset area level B, and preset area level C respectively, then if the area occupied by the first candidate point of interest is 100 square meters, then the area occupied by the first candidate point of interest is preset area level B.

[0117] Alternatively, the area occupied by a candidate point of interest can be determined according to the type of the corresponding geographic entity object. Each type corresponds to a preset area. When performing step (1), the type of geographic entity object corresponding to the first candidate point of interest can be queried and the preset area corresponding to the type can be obtained to obtain the area occupied by the first candidate point of interest. The same process is performed on the second candidate point of interest to obtain the area occupied by the second candidate point of interest. Then, the area occupied by the first candidate point of interest and the area occupied by the second candidate point of interest are compared, and the candidate point of interest with the smaller area is output as the target point of interest.

[0118] For example, the categories can include grocery stores, restaurants, shopping malls, city squares, specialty commercial streets, etc., and the categories of each geographic entity can be obtained manually. Alternatively, manual collection can only obtain the name of the geographic entity, and then the machine can match the name of the geographic entity with multiple preset categories. For example, for a geographic entity named "XXX Restaurant", the machine can match it with the preset category "Restaurant" based on the suffix "Restaurant" in the name, thereby determining that the category of the geographic entity is "Restaurant". When obtaining the area of ​​the candidate points of interest corresponding to the geographic entity, the result is the preset area corresponding to the category "Restaurant".

[0119] The following example illustrates the process of building a pre-defined database:

[0120] (a1) Multiple categories are preset, and a preset area is set for each category. For example, when the categories only include grocery stores, restaurants, shopping centers, city squares, and specialty commercial streets, the size relationship of the preset areas associated with different categories can be: grocery stores < restaurants < shopping centers < city squares < specialty commercial streets.

[0121] (a2) When manually collecting data on each geographic entity, record information such as the type, name, and geographical location of each geographic entity.

[0122] (a3) Store the types, names, geographical locations, etc. of each geographic entity in a preset database to obtain information about each preset point of interest.

[0123] (a4) Obtain the target combination based on the first point of interest name and the second point of interest name in the input text. The method for obtaining the target combination can be referred to above, and will not be repeated here.

[0124] (a5) Obtain the first type of the first candidate point of interest and the second type of the second candidate point of interest in the target combination, and query the preset areas associated with the first type and the second type respectively, so as to obtain the first area occupied by the first candidate point of interest and the second area occupied by the second candidate point of interest.

[0125] (a6) Compare the first and second land areas, and output the candidate interest point with the smaller land area as the target interest point.

[0126] The reason for determining the target point of interest (POI) by its area is to take into account users' semantic habits. Users typically use a reference point in their input text that is larger in area than the search target and more easily seen and familiar in daily life as a location constraint to accurately express the location of the search target. For example, when searching for McDonald's inside Walmart, to more accurately represent the location of McDonald's, a user would usually enter both the POI name "Walmart" and the POI name "McDonald's," using "McDonald's inside Walmart" as the input text for the search. Therefore, considering semantic habits, if the input text contains a first POI name and a second POI name, the user's actual search target is usually the candidate POI with the smaller area between the first and second candidate POIs. Thus, the candidate POI with the smaller area can be output as the target POI.

[0127] In some embodiments, the electronic device can output multiple points of interest (POIs) simultaneously in a list. In this case, the electronic device can place the target POI at the beginning of the list and then place another candidate POI from the target combination after the target POI, to avoid failing to find the correct target POI if the user does not input based on the aforementioned semantic habits.

[0128] Furthermore, when an electronic device simultaneously outputs multiple points of interest (POIs) in a list format, in addition to the target combination, multiple alternative combinations can be selected based on the distance between the first and second candidate POIs in each Cartesian product combination. The candidate POIs in each alternative combination are then sorted in a list according to certain rules and output to the user, thus providing more preset POIs. The following example illustrates the case of outputting candidate POIs from multiple Cartesian product combinations:

[0129] (b1) Sort the Cartesian product combinations in order of the distance between the first and second candidate interest points in each Cartesian product combination from shortest to longest to obtain the Cartesian product sequence.

[0130] (b2) Select m Cartesian product combinations with the shortest corresponding distances from the Cartesian product sequence to obtain multiple candidate combinations, where m is an integer greater than 0 and less than M, and M is the total number of Cartesian product combinations.

[0131] (b3) For each candidate combination, obtain the area occupied by the first candidate interest point and the second candidate interest point, and select the interest point with the smaller area in each candidate combination to be output based on the area occupied.

[0132] (b4) Sort the points of interest to be output according to the order of the corresponding candidate combinations in the Cartesian product sequence, and output the sorted sequence of points of interest. For example, if there are 3 candidate combinations: candidate combination a, candidate combination b, and candidate combination c, which respectively contain the first candidate point of interest a1 and the second candidate point of interest a2, the first candidate point of interest b1 and the second candidate point of interest b2, and the first candidate point of interest c1 and the second candidate point of interest c2, and the selected points of interest to be output are a1, b1, and c1, and the order of candidate combination a, candidate combination b, and candidate combination c in the Cartesian product sequence from shortest to longest is: candidate combination a, candidate combination b, and candidate combination c, then the sequence of points of interest obtained after sorting the points of interest to be output is: a1, b1, and c1, where a1 is at the beginning of the sequence of points of interest.

[0133] In addition to the methods in steps (b1)-(b2), a candidate combination selection method that can improve the fault tolerance rate is also provided. Assume there are a total of 9 Cartesian product combinations: (a, 0), (a, 1), (a, 2), (b, 0), (b, 1), (b, 2), (c, 0), (c, 1), (c, 2), where a, b, and c each represent a first candidate interest point, and 0, 1, and 2 each represent a second candidate interest point.

[0134] (c1) Classify each Cartesian product combination according to the elements it contains. For example, the Cartesian product combinations containing the first candidate interest point a, the first candidate interest point b, and the first candidate interest point c can be classified into three categories: (a, 0), (a, 1), (a, 2); (b, 0), (b, 1), (b, 2); and (c, 0), (c, 1), (c, 2).

[0135] (c2) Among the three types of Cartesian product combinations, select the Cartesian product combination with the shortest distance between the corresponding first candidate interest point and the second candidate interest point to obtain three candidate combinations. For example, if (a, 0), (b, 1), and (c, 2) are the Cartesian product combinations with the shortest distance between the corresponding first candidate interest point and the second candidate interest point among the three types of Cartesian product combinations, then the candidate combinations are (a, 0), (b, 1), and (c, 2).

[0136] After obtaining the candidate combinations, the subsequent operations are similar to steps (b3)-(b4), and will not be repeated here.

[0137] The advantage of selecting candidate combinations through steps (c1)-(c2) is that it avoids the influence of an inappropriate preset number n in step (b2) on the search results. The following example illustrates the potential impact of the preset number n: Suppose that candidate combinations are selected from (a, 0), (a, 1), (a, 2), (b, 0), (b, 1), (b, 2), (c, 0), (c, 1), (c, 2) according to steps (b1)-(b2). If the Cartesian product sequence obtained according to step (b1) is: (a, 0), (c, 1), (b, 2), (b, 0), (b, 1), (a, 2), (c, 0), (a, 1), (c, 2), and the preset number is 2, then the selected candidate combination is (a, 0), (c, 1). However, if the first candidate point of interest b is the user's search target, then the output target point of interest will inevitably not match the user's search target. There are several reasons why (b, 2) might be ranked after (a, 0) and (c, 1). For example, if the names of the first candidate points of interest (a, b, and c) are not significantly different, and the user's input of the first point of interest name is inaccurate, it may cause (b, 2) to be ranked after (a, 0) and (c, 1). See the scenario in Scenario 1 for reference.

[0138] Scenario 1: Assume the first candidate point of interest a is "Madonna Restaurant", the first candidate point of interest b is "McDonald's", and the first candidate point of interest c is "McDonald's Clothing Store". The second candidate points of interest include second candidate point of interest 0, second candidate point of interest 1, and second candidate point of interest 2. Here, the first candidate point of interest a being "Madonna Restaurant" can mean that the information of the first candidate point of interest a contains "Madonna Restaurant", as explained above. If the user's search target is the first candidate point of interest b "McDonald's", but the user misses part of the text when entering the search text, resulting in the first point of interest name in the input text being "McDonald", it may cause the Cartesian product combination (McDonald's, 2) to be sorted after the Cartesian product combination (Madonna Restaurant, 0) and the Cartesian product combination (McDonald's Clothing Store, 1) in the Cartesian product sequence obtained according to step (b1).

[0139] As can be seen, step (1) can accurately obtain the target interest point based on the user's semantic habits.

[0140] (2) If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then select the target point of interest from the target combination and output it according to the point of interest type of each candidate point of interest.

[0141] In this embodiment, the point of interest type can refer to the brand chain type of the point of interest, that is, whether the brand of the point of interest is chain or non-chain. Therefore, the point of interest type can include chain type and non-chain type. For example, the point of interest type of "McDonald's" is chain type, while the point of interest type of "Madonna Restaurant" operated by a sole proprietorship is non-chain type. The point of interest type can be determined based on a preset chain brand database. This database stores the brand names of all chain brands. When determining the point of interest type of a candidate point of interest, the name of the corresponding candidate point of interest can be queried in the chain brand database. If a query result is obtained, the point of interest type of the candidate point of interest is chain type; if no query result is obtained, the point of interest type of the candidate point of interest is non-chain type. The data in the chain brand database can be obtained from the internet through a search engine. For example, all chain brand names can be obtained from the internet through a search engine and stored on a cloud server, which can serve as the chain brand database.

[0142] If the preset database does not contain the area occupied by each candidate point of interest, the point of interest types of the first and second candidate points of interest can be compared, and the selection method of the target point of interest can be determined based on the comparison results.

[0143] If the interest type of the first candidate interest point is the same as that of the second candidate interest point, i.e., both are linked or non-linked types, then the candidate interest point with the later semantic order in the input text is set as the target interest point. In other words, the semantic order of the first and second candidate interest points in the input text is the same as the semantic order of the first and second interest point names. If the first interest point name follows the second interest point name in the input text, then the first candidate interest point obtained by retrieving the first interest point name is used as the target interest point; conversely, if the second interest point name follows the first interest point name in the input text, then the second candidate interest point obtained by retrieving the second interest point name is output as the target interest point.

[0144] The reason for setting candidate points of interest that appear later in the semantic order as target points of interest is based on users' semantic habits. Search targets that are of primary semantic importance are usually placed after the semantic order of the reference targets. For example, when describing McDonald's in Walmart, a user would typically use "McDonald's in Walmart" as input text. Therefore, the user's search target should be McDonald's, which appears later in the semantic order of the input text.

[0145] If the interest type of the first candidate point of interest differs from that of the second candidate point of interest—that is, one is a chain type and the other is a non-chain type—then the candidate point of interest with the chain type will be output as the target point of interest. This selection is also based on the user's semantic habits. For example, when describing a chain-type shopping mall B, to distinguish shopping mall B from other shopping malls with the same chain brand, a user would typically use a non-chain type, with a unique interest name and other information, as a reference target for shopping mall B. Therefore, when it's impossible to select a target point of interest based on its size, if the interest types of the first and second candidate points of interest differ, using the candidate point of interest with the chain type as the target point of interest is more in line with the user's semantic habits.

[0146] In summary, the point-of-interest (POI) search method provided in this application includes: obtaining input text to be searched, wherein the input text includes a first POI name and a second POI name; retrieving the first POI name and the second POI name from the input text to obtain a first reference POI and a second reference POI; and outputting a target POI among the first reference POI and the second reference POI based on the distance between them. On one hand, the POI search method provided in this application, when the input text to be searched contains both a first POI name and a second POI name, simultaneously retrieves both names and determines the output target POI by combining the retrieval results of the first and second POI names. Compared to methods that only select one POI name from the first and second POI names for retrieval, or directly retrieve based on the input text, the output results are more accurate. On the other hand, the point of interest search method provided in this application uses the distance between the first reference point of interest and the second reference point of interest as a filtering condition to determine the target point of interest, which is more in line with the semantic habit of users to use other points of interest around the search target as references when conducting point of interest search, and thus can further improve the accuracy of the output results.

[0147] In some embodiments, the search can first query the point of interest types corresponding to the first and second point of interest names, and then employ different search methods based on the two point of interest types. (See reference) Figure 3 At this point, the step "searching the first point of interest name and the second point of interest name respectively to obtain the first reference point of interest and the second reference point of interest" includes:

[0148] 301. Extract the name of the first point of interest and the name of the second point of interest.

[0149] The methods for extracting the names of the first and second points of interest have been explained above and will not be repeated here.

[0150] 302. Query the first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name, respectively.

[0151] The type of interest corresponding to a point of interest name refers to the type of interest of the preset point of interest corresponding to that point of interest name.

[0152] Similarly, the first and second point of interest types can be determined using the chain brand database described above. The chain brand database stores the brand names of all chain brands. When determining the first point of interest type, the name of the first point of interest can be queried in the chain brand database. If a query result is obtained, the point of interest type corresponding to the first point of interest name is a chain type. If no query result is obtained, the point of interest type corresponding to the first point of interest name is a non-chain type. The same applies to the second point of interest type.

[0153] It should be noted that if the first reference point of interest and the second reference point of interest are obtained through the method of steps 301-303, then when performing step (2) above, that is, "if the preset database does not contain the area occupied by each candidate point of interest in the target combination, then select the target point of interest from the target combination and output it according to the point of interest type of each candidate point of interest", there is no need to repeatedly query the point of interest type of each candidate point of interest.

[0154] 303. Based on the first point of interest type and the second point of interest type, the first point of interest name and the second point of interest name are retrieved respectively to obtain the first reference point of interest and the second reference point of interest.

[0155] The following two examples illustrate this:

[0156] Scenario 1: The first point of interest type and the second point of interest type are different:

[0157] (d1) When the first interest type and the second interest type are different, that is, one of the first interest type and the second interest type is a linked type and the other is a non-linked type, the interest point name with the interest point type of non-linked can be searched to obtain the non-linked interest point.

[0158] For ease of explanation, this embodiment of the application uses the example of a first point of interest type being a linked type and a second point of interest type being a non-linked type. Therefore, in this embodiment of the application, a non-linked point of interest refers to a preset point of interest obtained after searching the name of the second point of interest. It can be understood that when the second point of interest type is a linked type and the first point of interest type is a non-linked type, the execution process is similar.

[0159] To reduce computational load, only the n preset interest points with the highest similarity to the second interest point name can be considered as non-linked interest points, where n is a positive integer greater than 0 and less than or equal to N, and N is the total number of preset interest points. For example, n can be set to 1, and the one preset interest point with the highest similarity to the non-linked interest point name can be considered as the first reference interest point.

[0160] (d2) Then, based on the preset search distance and the location of the non-chained points of interest, the surrounding points of interest of the non-chained points of interest are determined, wherein the distance between the location of the surrounding points of interest and the location of the non-chained points of interest is less than or equal to the search distance.

[0161] In this embodiment, the search distance can refer to the actual search distance, which can be set according to actual needs. For example, to reduce the retrieval time spent searching for the first and second point of interest names, a smaller search distance can be set to output the target point of interest to the user as quickly as possible, improving the user's search experience. For instance, the search distance can be set to 1 kilometer.

[0162] The search range can be obtained based on the search distance and the location of points of interest that are not linked.

[0163] The search range can refer to the geographic area centered on the location of a non-linked point of interest. For example, the search range can be a circular area centered on the location of a non-linked point of interest, with the search distance as the radius.

[0164] Step (d2) allows for the initial filtering of preset points of interest, selecting nearby points of interest that are close to non-linked points of interest, thereby reducing the computational load during subsequent searches.

[0165] (d3) Among the surrounding points of interest, the names of the points of interest whose type is the chain type are retrieved to obtain the chain points of interest.

[0166] In the embodiments of this application, a chain point of interest refers to a preset point of interest obtained after searching for the name of a first point of interest.

[0167] For specific search methods, please refer to step 202; details will not be elaborated here. It is understandable that the first reference point of interest is of the chain type.

[0168] (d4) The non-linked points of interest and the linked points of interest are set as the first reference point of interest and the second reference point of interest.

[0169] In this embodiment of the application, since the first point of interest type is a linked type and the second point of interest type is a non-linked type, the non-linked point of interest is set as the second reference point of interest and the linked point of interest is set as the first reference point of interest.

[0170] In scenario one, non-chained points of interest can be used as search centers to perform surrounding searches to obtain chained points of interest, reducing the computational load when searching for the first and second reference points of interest.

[0171] Scenario 2: The first point of interest type and the second point of interest type are the same:

[0172] (e1) If the first point of interest type and the second point of interest type are the same, then select the number of points of interest corresponding to the point of interest type from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type.

[0173] (e2) Search the first point of interest name and the second point of interest name to obtain the first reference point of interest and the second reference point of interest of the number of points of interest, respectively.

[0174] The explanation of the number of points of interest (POIs) can be found in step 202, and will not be repeated here. In scenario two, different numbers of POIs can be selected based on the type of POI. When both the first and second POI types are chained, the number of POIs is the first preset number corresponding to the chained type. When both the first and second POI types are non-chained, the number of POIs is the second preset number corresponding to the non-chained type. The first preset number is greater than the second preset number. The specific values ​​of the first and second preset numbers can be set according to actual needs, provided they satisfy the above relationship. For example, to improve the speed of outputting target POIs, smaller first and second preset numbers can be set to reduce the retrieval time when searching for the first and second POI names, thus outputting the target POIs to the user as quickly as possible and improving the user's search experience. For example, the first preset number can be set to 10, and the second preset number can be set to 50.

[0175] The reason why the first preset number is greater than the second preset number is mainly to consider the difference in similarity between the names of interest points in the input text and the information of each preset interest point when the interest point types of the first and second reference interest points are linked and non-linked. The following example illustrates this; for simplicity, only the difference in similarity between the name of the first interest point and the feature information of each preset interest point will be explained:

[0176] Assuming the first point of interest is "Shenzhen Walmart" and the second is "McDonald's," both are considered chain stores. When searching for "Shenzhen Walmart," all corresponding information containing "Shenzhen Walmart" will be retrieved. Let's assume there are 5 such results. Figure 4 , Figure 4 The diagram shows five preset points of interest (POIs) a1-a5 on the electronic map 400 that contain the information for "Shenzhen Walmart", and two preset POIs b1 and b2 that contain the information for "McDonald's". The names of the POIs a1-a5 are "Shenzhen Walmart (Area A)", "Shenzhen Walmart (Area B)", "Shenzhen Walmart (Area C)", "Shenzhen Walmart (Area D)" and "Shenzhen Walmart (Area E)" respectively. Among a1-a5, the distance between b1 and a1 is the smallest, and the distance between b2 and a3 is the second smallest.

[0177] If a user intends to refer to a1 and b1 (the McDonald's closest to Walmart in Shenzhen) by inputting the first and second point of interest names, and the first preset number is small (e.g., 2 or 3), the similarity between the information of a1-a5 and the first point of interest name is small because all point of interest names a1-a5 contain "Walmart in Shenzhen". Even if reference points of interest are selected from high to low similarity, the preset point of interest a1 may still not be included, thus failing to obtain the target combination (a1, b1), resulting in an incorrect target point of interest. Figure 4 Taking the case in the example, if the reference interest points do not include the preset interest point a1, the resulting target combination might be (a3, b2) among the candidate interest points with the closest distance, and the final output target interest point might be b2. However, when the first preset number is set large enough, the reference interest points will necessarily include interest point a1. Therefore, in subsequent processing, the (a1, b1) among the included candidate interest points can be set as the target combination, thus obtaining the correct target interest point b1.

[0178] When both the first and second point of interest names correspond to non-linked types of interest, the probability of duplicate names among preset interest points of non-linked types is relatively low. Therefore, even if the number of second preset interest points is small, suitable reference interest points can still be obtained by ranking them from high to low similarity. The following example illustrates this:

[0179] Assume the first point of interest is named "Shenzhen Y Restaurant" and the second point of interest is named "X Grocery Store". (Reference) Figure 5 , Figure 5 In the electronic map 500, c1, c2, and c3 are all preset points of interest (POIs) that contain "Shenzhen Y Restaurant" in the corresponding information. For example, the POI name of c1 is "Shenzhen Y Restaurant", the POI name of c2 is "Shenzhen Yy Restaurant", and the POI name of c3 is "Shenzhen Yz Luxury Restaurant". d1 is a preset POI that contains "X Grocery Store" in the corresponding information. Among c1-c3, the distance between c1 and d1 is the smallest.

[0180] If the user intends to refer to c1 and d1, i.e., the X grocery store closest to Shenzhen Y Restaurant, by inputting the first and second point of interest names, since the point of interest names c2 and c3 both contain information other than "Shenzhen Y Restaurant", while the point of interest name c1 only contains "Shenzhen Y Restaurant", the similarity between the information of c1 and the first point of interest name is much higher than that between the information of c2 and the first point of interest name, and the information of c3 and the first point of interest name. Even if the second preset number is small, the reference point of interest selected according to the similarity from high to low will still include c1. Therefore, the correct target point of interest can be obtained, and b1 can be output to the user.

[0181] As can be seen, by using the method in steps (e1)-(e2), an appropriate number of points of interest can be selected based on the type of points of interest corresponding to the first point of interest name and the second point of interest name. When the type of points of interest corresponding to the first point of interest name and the second point of interest name is a chain type, the completeness of the search is guaranteed. When the type of points of interest corresponding to the first point of interest name and the second point of interest name is a non-chain type, the amount of calculation is reduced.

[0182] To better implement the point of interest (POI) search method in the embodiments of this application, an POI search device is also provided in the embodiments of this application, such as... Figure 6 The diagram shown is a structural schematic of one embodiment of the point of interest search device in this application. The point of interest search device 600 includes:

[0183] The acquisition module 601 is used to acquire the input text to be searched, wherein the input text includes a first point of interest name and a second point of interest name;

[0184] The retrieval module 602 is used to retrieve the first point of interest name and the second point of interest name respectively, and obtain the first reference point of interest and the second reference point of interest;

[0185] The output module 603 is used to output the target interest point between the first reference interest point and the second reference interest point based on the distance between the first reference interest point and the second reference interest point.

[0186] In one possible implementation of this application, the retrieval module 602 is further configured to:

[0187] Extract the name of the first point of interest and the name of the second point of interest;

[0188] Query the first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name, respectively;

[0189] Based on the first point of interest type and the second point of interest type, the first point of interest name and the second point of interest name are retrieved respectively to obtain the first reference point of interest and the second reference point of interest.

[0190] In one possible implementation of this application, the retrieval module 602 is further configured to:

[0191] If the first point of interest type and the second point of interest type are different, then the point of interest type that is the non-linked type is retrieved to obtain the non-linked point of interest.

[0192] Based on the preset search distance and the location of the non-chained points of interest, the surrounding points of interest of the non-chained points of interest are determined, wherein the distance between the location of the surrounding points of interest and the location of the non-chained points of interest is less than or equal to the search distance.

[0193] Among the surrounding points of interest, the names of points of interest of type chain are retrieved to obtain chain points of interest;

[0194] The non-linked points of interest and the linked points of interest are set as the first reference point of interest and the second reference point of interest, respectively.

[0195] In one possible implementation of this application, the retrieval module 602 is further configured to:

[0196] If the first point of interest type and the second point of interest type are the same, then the number of points of interest corresponding to the point of interest type is selected from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type, wherein the first preset number is greater than the second preset number;

[0197] The first and second point of interest names are retrieved to obtain the first and second reference points of interest, respectively, representing the number of points of interest.

[0198] In one possible implementation of this application, the output module 603 is further configured to:

[0199] Obtain the Cartesian product combination between each of the first reference interest points and each of the second reference interest points;

[0200] Based on the distance between the first reference interest point and the second reference interest point in each of the Cartesian product combinations, determine the target combination with the shortest distance;

[0201] Select target points of interest from the target combination and output them.

[0202] In one possible implementation of this application, the output module 603 is further configured to:

[0203] If the preset database contains the area occupied by each candidate point of interest in the target combination, then the candidate point of interest with the smaller area is output as the target point of interest.

[0204] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the target point of interest is selected from the target combination and output according to the point of interest type of each candidate point of interest.

[0205] In one possible implementation of this application, the output module 603 is further configured to:

[0206] If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the point of interest type of each candidate point of interest is compared, wherein the point of interest type includes chain type and non-chain type;

[0207] If all the interest points are of the same type, then according to the semantic order of each candidate interest point in the input text, the candidate interest point with the later semantic order is set as the target interest point.

[0208] If the types of interest points are different, the candidate interest point of the chain type will be output as the target interest point.

[0209] In practice, the above modules can be implemented as independent entities or combined in any way to be implemented as the same or several entities. For the specific implementation of the above modules, please refer to the previous method implementation examples, which will not be repeated here.

[0210] Since the point of interest search device can execute the steps in the point of interest search method in any embodiment, it can achieve the beneficial effects that the point of interest search method in any embodiment of this application can achieve, as detailed in the preceding description, and will not be repeated here.

[0211] Furthermore, to better implement the point of interest search method in the embodiments of this application, based on the point of interest search method, the embodiments of this application also provide an electronic device, see below. Figure 7 , Figure 7 This illustration shows a structural schematic diagram of an electronic device according to an embodiment of this application. Specifically, the electronic device provided in this embodiment includes a processor 701. The processor 701 is used to execute a computer program stored in a memory 702 to implement the steps of the point of interest search method in any embodiment; or, the processor 701 is used to execute a computer program stored in a memory 702 to implement, for example... Figure 6 The functions of each module in the corresponding embodiment.

[0212] For example, a computer program can be divided into one or more modules / units, one or more of which are stored in memory 702 and executed by processor 701 to complete the embodiments of this application. One or more modules / units can be a series of computer program instruction segments capable of performing a specific function, which describe the execution process of the computer program in a computer device.

[0213] The electronic device may include, but is not limited to, processor 701 and memory 702. Those skilled in the art will understand that the illustrations are merely examples of an electronic device and do not constitute a limitation on the electronic device. It may include more or fewer components than illustrated, or combine certain components, or use different components.

[0214] The processor 701 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor can be a microprocessor or any conventional processor. The processor is the control center of the electronic device, connecting various parts of the electronic device through various interfaces and lines.

[0215] The memory 702 can be used to store computer programs and / or modules. The processor 701 implements various functions of the computer device by running or executing the computer programs and / or modules stored in the memory 702 and by calling data stored in the memory 702. The memory 702 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, application programs required for at least one function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device (such as audio data, video data, etc.). In addition, the memory may include high-speed random access memory, and may also include non-volatile memory, such as hard disk, RAM, plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, at least one disk storage device, flash memory device, or other volatile solid-state storage device.

[0216] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the point of interest search device, electronic device and its corresponding modules described above can be referred to the description of the point of interest search method in any embodiment, and will not be repeated here.

[0217] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by instructions, or by instructions controlling related hardware. These instructions can be stored in a readable storage medium and loaded and executed by a processor.

[0218] Therefore, embodiments of this application provide a readable storage medium storing a computer program. When the computer program is executed by a processor, it performs the steps of the point of interest search method in any embodiment of this application. For specific operations, please refer to the description of the point of interest search method in any embodiment, which will not be repeated here.

[0219] The readable storage medium may include: read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, etc.

[0220] Since the instructions stored in the readable storage medium can execute the steps of the point of interest search method in any embodiment of this application, the beneficial effects that the point of interest search method in any embodiment of this application can achieve can be realized, as detailed in the preceding description, and will not be repeated here.

[0221] The above provides a detailed description of the point of interest search method, apparatus, storage medium, and electronic device provided in the embodiments of this application. Specific examples have been used to illustrate the principles and implementation methods of this application. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of this application. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this application. Therefore, the content of this specification should not be construed as a limitation of this application.

Claims

1. A method for searching points of interest, characterized in that, include: Obtain the input text to be searched, wherein the input text includes a first point of interest name and a second point of interest name; The first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name are determined according to the preset chain brand database, wherein any point of interest type is a chain type or a non-chain type. Based on the first point of interest type and the second point of interest type, the first point of interest name and the second point of interest name are retrieved respectively to obtain the first reference point of interest and the second reference point of interest, including: If the first point of interest type and the second point of interest type are the same, then the number of points of interest corresponding to the point of interest type is selected from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type, wherein the first preset number is greater than the second preset number; The first and second point of interest names are retrieved to obtain the first and second reference points of interest of the number of points of interest, respectively. Based on the distance between the first reference point of interest and the second reference point of interest, output the target point of interest among the first reference point of interest and the second reference point of interest.

2. The point-of-interest search method according to claim 1, characterized in that, Before determining the first point of interest type and the second point of interest type corresponding to the first point of interest name and the second point of interest name respectively based on the preset chain brand database, the method further includes: Extract the name of the first point of interest and the name of the second point of interest.

3. The point-of-interest search method according to claim 2, characterized in that, The types of points of interest include chained and non-chained types; The step of retrieving the first point of interest name and the second point of interest name according to the first point of interest type and the second point of interest type respectively to obtain the first reference point of interest and the second reference point of interest includes: If the first point of interest type and the second point of interest type are different, then the point of interest type that is the non-linked type is retrieved to obtain the non-linked point of interest. Based on the preset search distance and the location of the non-chained points of interest, the surrounding points of interest of the non-chained points of interest are determined, wherein the distance between the location of the surrounding points of interest and the location of the non-chained points of interest is less than or equal to the search distance. Among the surrounding points of interest, the names of points of interest of type chain are retrieved to obtain chain points of interest; The non-linked points of interest and the linked points of interest are set as the first reference point of interest and the second reference point of interest, respectively.

4. The point-of-interest search method according to claim 1, characterized in that, The step of outputting the target interest point between the first reference interest point and the second reference interest point based on the distance between the first reference interest point and the second reference interest point includes: Obtain the Cartesian product combination between each of the first reference interest points and each of the second reference interest points; Based on the distance between the first reference interest point and the second reference interest point in each of the Cartesian product combinations, determine the target combination with the shortest distance; Select target points of interest from the target combination and output them.

5. The point-of-interest search method according to claim 4, characterized in that, The step of selecting and outputting target points of interest from the target combination includes: If the preset database contains the area occupied by each candidate point of interest in the target combination, then the candidate point of interest with the smaller area is output as the target point of interest. If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then a target point of interest is selected from the target combination and output according to the point of interest type of each candidate point of interest.

6. The point-of-interest search method according to claim 5, characterized in that, If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then according to the point of interest type of each candidate point of interest, a target point of interest is selected from the target combination and output, including: If the preset database does not contain the area occupied by each candidate point of interest in the target combination, then the point of interest type of each candidate point of interest is compared. If all the interest points are of the same type, then according to the semantic order of each candidate interest point in the input text, the candidate interest point with the later semantic order is set as the target interest point. If the types of interest points are different, the candidate interest point of the chain type will be output as the target interest point.

7. A point-of-interest (POI) search device, characterized in that, include: The acquisition module is used to acquire the input text to be searched, wherein the input text includes a first point of interest name and a second point of interest name; The retrieval module is configured to determine, based on a preset chain brand database, the first point of interest (POI) name and the second POI name, respectively, their corresponding first and second POI types, wherein either POI type is a chain type or a non-chain type; and to retrieve the first POI name and the second POI name based on the first POI type and the second POI type, respectively, to obtain a first reference POI and a second reference POI, including: If the first point of interest type and the second point of interest type are the same, then the number of points of interest corresponding to the point of interest type is selected from the first preset number corresponding to the chain type and the second preset number corresponding to the non-chain type, wherein the first preset number is greater than the second preset number; The first and second point of interest names are retrieved to obtain the first and second reference points of interest of the number of points of interest, respectively. The output module is used to output the target interest point between the first reference interest point and the second reference interest point based on the distance between the first reference interest point and the second reference interest point.

8. An electronic device, characterized in that, The electronic device includes a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the point of interest search method as described in any one of claims 1 to 6.

9. A readable storage medium, characterized in that, The readable storage medium stores a computer program that, when executed by a processor, implements the steps of the point of interest search method according to any one of claims 1 to 6.

Citation Information

Patent Citations

  • Interest point display method and device

    CN110413886A