A knowledge graph-based tourist attraction recommendation method and system

By employing a knowledge graph-based approach, utilizing the BiLSTM-Att-CRF model and a random walk strategy to construct user preferences, this method addresses the timeliness and maintenance challenges of existing tourist attraction recommendation methods. It achieves efficient and accurate attraction recommendations, thereby improving user satisfaction.

CN116910364BActive Publication Date: 2025-12-12XI AN JIAOTONG UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310891448.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-07-19
Publication Date
2025-12-12
Estimated Expiration
2043-07-19

AI Technical Summary

Technical Problem

Existing methods for recommending tourist attractions are time-sensitive and require extensive maintenance, but they lack knowledge graph applications tailored to tourist needs, resulting in unsatisfactory recommendation results and failing to meet the demands of the rapid recovery of the modern service industry.

Method used

We employ a knowledge graph-based approach, using a BiLSTM-Att-CRF model for entity extraction and fusion, combined with a random walk strategy and attention mechanism, to construct users' long-term and short-term preferences and generate a list of recommended attractions.

Benefits of technology

It improved the accuracy and timeliness of attraction recommendations, reduced manual maintenance costs, increased user satisfaction, and met the needs of the rapid recovery of the modern service industry.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116910364B_ABST
    Figure CN116910364B_ABST
Patent Text Reader

Abstract

The application discloses a kind of tourism scenic spot recommendation method and system based on knowledge graph, comprising the following steps: obtaining tourism original data, and constructs entity extraction model, based on entity extraction model to the entity extraction of obtained tourism original data, and the knowledge fusion of entity after extraction;Determine the actual application range of entity, extract the relevant data of ontology based on the actual application range of entity, continue ontology construction based on the relevant data of ontology, tourism original data and the entity data obtained after knowledge fusion, obtain knowledge graph;From the extracted scenic spot information in knowledge graph, obtain the feature vector of scenic spot, train the feature vector of scenic spot, obtain the latent vector representation of scenic spot sequence, construct the long-term preference and short-term preference of user based on the latent vector representation of scenic spot sequence, obtain the recommendation list of scenic spot.The construction of knowledge graph of the application improves the completeness of graph, guarantees the accuracy of later scenic spot recommendation, timeliness is higher, improves the satisfaction of user.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The application belongs to the technical field of atlas recognition, and relates to a tourism attraction recommendation method and system based on a knowledge graph. BACKGROUND

[0002] With the rapid development of the tourism industry, many places in China are strengthening the importance of the tourism industry, and some cities even regard the tourism industry as a pillar industry or a leading industry. In recent years, with the development of the Internet and cloud computing, a large amount of data has also been generated in the tourism field, and many companies such as Ctrip have built their own knowledge graph applications.

[0003] Therefore, the Internet online travel platform provides convenient and fast information services for users, but at the same time, the problem of "information overload" is becoming more and more serious, which leads users to spend a lot of time and effort to read, identify and screen the information to assist in travel planning. Therefore, the means of the recommendation system emerges as the times require. They analyze the interests and needs of users, infer the related destination or attraction set, and filter out a large amount of irrelevant information to assist people in travel planning. Existing attraction recommendation methods can be divided into two categories: traditional recommendation methods represented by content-based recommendation and collaborative filtering, and recommendation methods based on deep learning. The traditional content-based recommendation method and the collaborative filtering method are relatively intuitive and transparent, and the similarity between the user history and the candidate attraction is measured to make recommendations, but the performance is limited by complex feature engineering and inevitable data sparsity. The recommendation method based on deep learning introduces a large number of parameters to describe unknown mechanisms in tourism activities, thereby obtaining performance improvement superior to traditional methods, but there is a widely criticized "black box" problem, which leads to a lack of transparency and timeliness, and it is difficult to meet the wishes of some users to understand the basis of the recommendation, so that users cannot get satisfactory evaluation of the recommendation results.

[0004] In order to make up for the shortcomings of the current recommended method, the industry introduces knowledge graph into the recommendation system. The concept of knowledge graph was proposed by Google in 2012, which aims to use it as a knowledge base to improve the performance of search engines. The search engine can extract the semantics of the user's query statement through the constructed knowledge graph, and through further inference of the knowledge graph, it can feed back more accurate and more structured query results to the user, so as to meet the user's needs as much as possible and directly give the user the data he wants. The knowledge graph forms a network of all entities and relationships between entities, and through the reasoning engine, the computer has reasoning ability. With continuous development, knowledge graph technology has a deeper application in the fields of search and automatic question answering. Therefore, it can be seen that the application field of knowledge graph is relatively wide, and in the development process of modern service industry, many industries will apply knowledge graph to their own industry. This is because the recommendation method based on knowledge graph can help tourists filter a large amount of irrelevant information and also assist in mining potential customers.

[0005] But the existing knowledge graph in the tourism field is mostly applied to tourism product recommendation, and the knowledge graph is applied to service vendors for recommendation, and there is a lack of knowledge graph application directly facing the needs of tourists. The purpose of knowledge graph construction is to meet the needs of tourists, so a reasonable interactive mode needs to be selected in knowledge construction to extract a knowledge base that can meet the understanding of tourists. Since the data generated by the tourist destination contains multi-modal data and has the characteristics of multi-source heterogeneity, single data cannot truly understand the emotions of tourists, and cannot achieve a satisfactory recommendation scheme for tourists. In the existing recommendation method, only the tourism industry is recommended as a single industry, but with the development of the overall economic situation, it is necessary to combine the collaborative knowledge construction of multiple industries in the modern service industry to effectively recommend the tourism industry better. The existing recommendation method has low timeliness and high maintenance intensity, so a knowledge construction and recommendation method based on knowledge graph of the modern service industry of the tourism industry is needed to solve the problem of un-friendly tourist experience after the rapid recovery of the tourism industry after the epidemic SUMMARY

[0006] The purpose of the present application is to solve the problems in the prior art and provide a tourism scenic spot recommendation method and system based on knowledge graph.

[0007] To achieve the above purpose, the following technical solutions are adopted:

[0008] A tourism scenic spot recommendation method based on knowledge graph, comprising the following steps:

[0009] S1: Obtain tourism original data and construct an entity extraction model, perform entity extraction on the obtained tourism original data based on the entity extraction model, and perform knowledge fusion on the extracted entities;

[0010] S2: determining the actual application range of the entity, extracting relevant data of the ontology based on the actual application range of the entity, continuing the ontology construction based on the relevant data of the ontology, the original data of the tourism industry and the entity data obtained after knowledge fusion, and obtaining the knowledge graph;

[0011] S3: extracting the scenic spot information from the obtained knowledge graph, obtaining the feature vector of the scenic spot, training the feature vector of the scenic spot, obtaining the latent vector representation of the scenic spot sequence, constructing the long-term preference and short-term preference of the user based on the latent vector representation of the scenic spot sequence, and obtaining the recommendation list of the scenic spot.

[0012] Further improvement of the application is that:

[0013] In the step S1, the process of entity extraction includes:

[0014] A BiLSTM-Att-CRF model is constructed to learn the context information of the entity and identify the entity.

[0015] The extracted entity is given different weights according to importance.

[0016] The entity is labeled to identify the entity type.

[0017] In the step S1, the process of knowledge fusion includes:

[0018] Entity alignment:

[0019] The string similarity of the entity is calculated, and a string similarity threshold is set.

[0020] When the obtained string similarity is greater than the threshold, the two entities are aligned.

[0021] When the obtained string similarity is less than the threshold, the attribute similarity of the entity is calculated, and an attribute similarity threshold is set, when the obtained attribute similarity is greater than the set threshold, the entity alignment is performed, and if it is less than the set threshold, the entity alignment is not performed.

[0022] Based on the aligned entity, entity disambiguation is performed.

[0023] In the step S2, the ontology construction includes the following steps:

[0024] The determination of the actual application range of the entity includes extracting the ontology and related terms according to the actual application scenario.

[0025] The actual application scenario includes scenic spot recommendation and route planning.

[0026] The step S3 includes the following steps:

[0027] Extract scenic spot information from the knowledge graph based on the random walk strategy, and map the extracted scenic spot information to a low-dimensional space to obtain the feature vector representation of the scenic spot;

[0028] Input the obtained feature vector representation of the scenic spot into the gated recurrent unit network for training to obtain the latent vector representation of the scenic spot sequence;

[0029] Use the attention mechanism to model the long-term and short-term preferences of users, and generate a list of scenic spot recommendations that users may like.

[0030] Step S3 includes the following steps:

[0031] The random walk strategy includes the following steps:

[0032] Given a source node v, randomly walk a sequence S = {v1, v2,..., v

[0039] , u,1 ,

[0038] ,

[0040] , u,n , u,2 , , , s , }, v i represents the i-th node in the random walk process, and the starting node of the walk is v0 = v. The v0 node is generated according to the distribution in formula (1):

[0033]

[0034] where E represents the set of edges in the knowledge graph, Z is the regularization parameter, and π vx represents the transition probability between node v and node x, and is expressed by formula (2):

[0035] π vx = α pq (t, x) * w vx (2)

[0036] where α pq represents the bias on the edge and is expressed by formula ():

[0037]

[0038] where p and q are parameters that control the graph walk. If p > max(q, 1), the next sampled node is not the previously visited node t; if p < max(q, 1), the next sampled node will always sample around the previously visited node t.

[0039] Step S4 includes the following steps:

[0040] Given the游玩 sequence u of tourist u = {v u,1 , v<00​​​​​u,n , excluding the last sight in the sequence, the long-term preference of the tourist is obtained by multiplying and accumulating the weight sight vector of each sight in the sequence using the attention mechanism, and the weight of the i th sight is represented by formula (4),

[0041] a i =q T σ(W1v n +W2v i +c) (4)

[0042] The long-term preference of the tourist is represented by formula (5):

[0043]

[0044] Further, the long-term preference of the tourist is linearly spliced with the current preference to obtain the final vector representation of the tourist:

[0045] s h =W3[s l ;s s ] (6)

[0046] The vector representation of the tourist is dot multiplied with the vector of the i th sight to be predicted to obtain the estimated score of the sight:

[0047]

[0048] Will Using the softmax function to normalize, the prediction probability of each sight is obtained

[0049]

[0050] A tourism attraction recommendation system based on a knowledge graph, comprising an original data processing module, an ontology construction module and a recommended list of attractions acquisition module;

[0051] The original data processing module is used to obtain tourism original data, and an entity extraction model is constructed. Based on the entity extraction model, the obtained tourism original data is subjected to entity extraction, and the extracted entity is subjected to knowledge fusion;

[0052] The ontology construction module is used to determine the actual application range of the entity, extract the related data of the ontology based on the actual application range of the entity, and continue the ontology construction based on the related data of the ontology, the tourism original data and the entity data obtained after knowledge fusion, and obtain the knowledge graph;

[0053] The attraction recommendation list acquisition module is used for extracting attraction information from the acquired knowledge graph, acquiring a feature vector of the attraction, training the feature vector of the attraction, obtaining a latent vector representation of an attraction sequence, constructing long-term preference and short-term preference of a user based on the latent vector representation of the attraction sequence, and acquiring a recommendation list of the attraction.

[0054] A terminal device comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method according to any one of the present application when executing the computer program.

[0055] A computer-readable storage medium stores a computer program, wherein the computer program is executable by a processor to implement the steps of the method according to any one of the present application.

[0056] The application discloses a tourism attraction recommendation method based on a knowledge graph, which comprises the following steps: firstly, acquiring original data, and extracting and fusing the original data; secondly, constructing an ontology by combining the acquired results with the ontology collected in the actual application range; thirdly, comprehensively considering the factors in the actual application scene and the data in the field; and fourthly, forming a knowledge graph, so that the graph has stronger coverage for different needs in the later period, and the problem of long artificial standard consumption time is solved.

[0057] Further, in the application, the similarity of entities is judged from two aspects of strings and entity attributes, and the diversity fusion efficiency between multi-source heterogeneous data is improved. BRIEF DESCRIPTION OF DRAWINGS

[0058] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the following will briefly introduce the drawings needed to be used in the embodiments. It should be understood that the following drawings only show some embodiments of the present application, and therefore should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.

[0059] Figure 1 The method flowchart of the present application;

[0060] Figure 2 The BiLSTM-Att-CRF model structure diagram of the present application;

[0061] Figure 3 The entity alignment flowchart of the present application;

[0062] Figure 4 A flowchart is constructed for the body of the present application;

[0063] Figure 5 A flowchart is constructed for the user preference recommendation technique of the present application. DETAILED DESCRIPTION

[0064] In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are only some but not all of the embodiments of the present application. The components of the embodiments of the present application described and shown in the drawings can be arranged and designed in various different configurations.

[0065] Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the claimed present application, but only represents selected embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments in the present application without creative labor fall within the scope of protection of the present application.

[0066] It should be noted that: similar reference numerals and letters represent similar items in the following drawings, therefore, once an item is defined in one drawing, it does not need to be further defined and explained in the subsequent drawings.

[0067] In the description of the embodiments of the present application, it should be noted that if the terms "upper", "lower", "horizontal", "inner" and the like indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, or the orientation or positional relationship when the product of the present application is usually placed, which is only for the convenience of describing the present application and simplifying the description, and does not indicate or imply that the indicated device or element must have a particular orientation, be constructed and operated in a particular orientation, therefore, it cannot be understood as a limitation on the present application. In addition, the terms "first", "second" and the like are only used to distinguish the description, and cannot be understood as indicating or implying relative importance.

[0068] In addition, if the term "horizontal" appears, it does not mean that the component must be absolutely horizontal, but can be slightly inclined. For example, "horizontal" only means that its direction is relatively more horizontal than "vertical", and does not mean that the structure must be completely horizontal, but can be slightly inclined.

[0069] In the description of the embodiments of the present application, it should also be explained that, unless otherwise explicitly specified and limited, if the terms "arrange", "install", "connect", "connect" appear, they should be understood in a broad sense, for example, they can be fixedly connected, or can be detachably connected, or integrally connected; can be mechanically connected, or can be electrically connected; can be directly connected, or can be indirectly connected through an intermediate medium, or can be the communication inside two elements. For those skilled in the art, the specific meaning of the above terms in the present application can be understood according to the specific circumstances.

[0070] The present application will be further described in detail below with reference to the accompanying drawings:

[0071] Referring to Figure 1 , the present application discloses a kind of based on knowledge graph's tourist attraction recommendation method, comprising the following steps:

[0072] Step 1: obtain tourism original data, and construct entity extraction model, based on entity extraction model to the tourism original data obtained is entity extraction, and the knowledge fusion of entity after extraction is carried out;

[0073] Step 1.1: the acquisition of original data:

[0074] Through data collection mode such as network crawler, collect tourism-related structured or unstructured data in public website and statistical data, including statistical information, comments, scenic spot information etc., for subsequent knowledge graph construction

[0075] Further, the original data is processed:

[0076] To the data collected, it needs to be form and content on noise cleaning, can be used in subsequent knowledge graph building process;

[0077] Further, the present application uses BiLSTM-Att-CRF model to obtain tourism original data and carries out entity extraction, referring to Figure 2 ,

[0078] Step 1.2: entity extraction

[0079] Step 1.2.1: BiLSTM-Att-CRF model first utilizes bidirectional long short-term memory network to identify entity by learning the context information of entity, to achieve the effect of accurately identifying entity:

[0080] The model first inputs the vector representation X of multi-source data = [x1,x2,...,x n ] into forward propagation LSTM model, to obtain forward feature information

[0081] Further, the backward feature information is obtained by inputting into the backward propagation LSTM model

[0082] Further, the forward feature information and the backward feature information are combined to obtain the final hidden state

[0083] Step 1.2.2: using an attention mechanism to assign different weights to the entities extracted in the BiLSTM according to their importance, so as to achieve the purpose of screening important entities;

[0084] The ontology weight is calculated by formula (9):

[0085]

[0086] Step 1.2.3: annotating entity categories by superimposing a layer of CRF

[0087] The CRF model is a sequence labeling at the sentence level. In order to be able to predict the relationship between labels and labels, the CRF model uses the dependency information between sentence-level labels;

[0088] In the embodiment of the application, the state transition matrix Q is defined as a parameter accompanying model to be trained, representing the transition probability value, that is, the probability value of transferring from the i-th label to the j-th label, Y is the label sequence to be predicted:

[0089] Y=(y1,y2,...,y n ) (10)

[0090] The prediction probability of the model on the sequence Y is determined by the word feature vector output by the attention layer and the parameter matrix of the CRF, which is the sum of the probabilities of each position, and the formula is:

[0091]

[0092] Step 1.3: knowledge fusion

[0093] Knowledge fusion includes entity alignment and entity disambiguation, in the embodiment of the application, the similarity of entities is judged from two aspects of string and entity attribute, and a similarity-based entity alignment method is used;

[0094] Step 1.3.1: string similarity calculation:

[0095] Referring to Figure 3The string similarity of the entities is calculated by the edit distance similarity, if the entities are not similar, the attribute similarity of the entities is calculated, the edit distance refers to the minimum edit times of transforming one string into another string, and the edit here refers to inserting, modifying or deleting a character in one string. The smaller the edit distance between the strings, the greater the character similarity of the strings.

[0096] The edit distance similarity of the strings s1, s2 is expressed as follows:

[0097]

[0098] Wherein, len(s1) is the length of the string, n op is the minimum edit times of transforming the string s1 into s2. After calculating the edit distance similarity of the entities, a threshold t is set, when the similarity is higher than the threshold, it is considered that the two entities need to be aligned, otherwise, the attribute similarity of the entities is calculated, and it is judged from the structure whether the entities need to be aligned.

[0099]

[0100] sim e (e1, e2) represents the edit distance similarity of the entities, sim q (e1, e2) represents the attribute similarity of the entities, if the attributes between the two entities are consistent, it is explained from the structure that the two entities refer to the same thing, therefore, the attribute similarity can be calculated to judge whether the entities need to be aligned

[0101] Step 1.3.2: Calculation of attribute similarity:

[0102] The common attribute set of the entities e1 and e2 is calculated, property1 and property2 are the attribute sets of the entities e1 and e2 respectively, and the common attributes are as follows:

[0103] commen(e1, e2) = property1∩property2 (14)

[0104] pi∈commen(e1, e2), v i1 is the attribute value corresponding to the entity e1 at pi, v i2 is the attribute value corresponding to the entity e2 at pi;

[0105] Further, the similarity of the two entities at the attribute pi is calculated, and the edit distance similarity is also used to represent the attribute similarity here

[0106]

[0107] Further, the attribute similarity of the entities e1, e2 is calculated:

[0108]

[0109] After the attribute similarity is obtained, similarly, a similarity threshold t is set, if the attribute similarity is greater than t, it is considered that the entities need to be aligned, otherwise, the entities do not perform the alignment operation

[0110] Step 1.3.3: entity disambiguation

[0111] The method disclosed in the application can adopt an end-to-end entity disambiguation method based on joint coding.

[0112] Step 2: determining the actual application range of the entity, extracting related data of the ontology based on the actual application range of the entity, and continuing the ontology construction based on the related data of the ontology, the original data of the tourism industry and the entity data obtained after knowledge fusion, and obtaining a knowledge graph;

[0113] In the embodiment of the application, first, the entity range in the tourism industry in the modern service industry is determined, the ontology and the terminology are extracted according to the actual application scene (such as scenic spot recommendation, route planning, etc.), and the related information in the field is collected. Not only the top-down design of extracted knowledge is considered, but also the design of enriching and correcting the ontology from the two lower layers of the actual application scene and the field data is considered. In this way, the design for different tourism scenes can cover various needs.

[0114] Further, the definition, simplification and optimization, reuse and evaluation of the ontology are further performed, so that the final design of the ontology is not too complex. Finally, the ontology instantiation also contains the step of iterative evolution of the ontology, see Figure 4 .

[0115] Further, the missing values in the knowledge graph are processed through knowledge reasoning, and the obtained knowledge graph is quality evaluated through quality evaluation. In the embodiment of the application, the rule-based reasoning method is used for knowledge reasoning, and the statistical method is used for quality evaluation of the knowledge graph.

[0116] The embodiment of the application discloses a process of ontology construction:

[0117] First, the boundary is determined

[0118] The boundary includes the field category, the business scene, the processing intention and the data range.

[0119] Second, the data is collected

[0120] The collected data includes: obtaining business corpus, text, table and existing knowledge base, etc., and listing important terms related to the field and collecting whether the field ontology exists.

[0121] Third, analyze data

[0122] Using text clustering, word frequency analysis, clustering, statistical analysis, etc., the high-frequency feature words and terms in the field are counted, and the possibility of reusing existing ontology is examined.

[0123] Fourth, preliminary development of ontology construction;

[0124] From the general ontology or reuse of field ontology, list the relatively high-level concept set.

[0125] Further concept division:

[0126] Distinguish between field-specific concepts and cross-field concepts. Cross-field concepts are expanded from general concepts as much as possible, and attention is paid to semantic compatibility, such as: distributors, manufacturers. Field-specific concepts should pay attention to semantic specificity: such as financial events, research reports, automobile parts, and faults.

[0127] Fifth: ontology construction optimization and verification.

[0128] Step 3: Extracting scenic spot information from the acquired knowledge graph, obtaining the feature vector of the scenic spot, training the feature vector of the scenic spot, obtaining the latent vector representation of the scenic spot sequence, and constructing the long-term preference and short-term preference of the user based on the latent vector representation of the scenic spot sequence, obtaining the recommendation list of the scenic spot, see Figure 5 .

[0129] Step 3.1: Using the Node2Vec method in network representation learning, through the biased random walk strategy, using the neural network language model Word2Vec to extract scenic spot information from the knowledge graph, and mapping to a low-dimensional space to obtain the feature vector representation of the scenic spot;

[0130] Given a source node v, a random walk sequence S = {v1, v2,..., v n} of length L is performed, where v i represents the i-th node in the random walk process. The starting node of the walk is v0 = v, and the v0 node is generated by the following distribution:

[0131]

[0132] Where E represents the set of edges in the knowledge graph, Z is a regularization parameter, and π vx represents the transition probability between node v and node x. Given by the following formula:

[0133] π vx = α pq (t, x) * w vx (2)

[0134] where π vx denotes the weight on the edge between nodes, and is taken as 1 if there is no weight between nodes. a pq denotes the bias on the edge. It is calculated as follows:

[0135]

[0136] p and q are parameters that control the graph walk. Parameter p is used to control the likelihood of immediately re-visiting a node that has already been visited during the walk. If p > max(q, 1), then the next sampled node is less likely to be the last node t that has already been visited. If p < max(q, 1), then the next sampled node will always be sampled around the last node t that has already been visited.

[0137] Step 3.2: Use the attention mechanism to model the long-term preference and short-term preference of the user, and generate a list of recommended scenic spots that the user may like;

[0138] The scenic spot vector learned through the knowledge graph and the gated recurrent unit contains both semantic information on the scenic spot attributes and sequence information of the scenic spots. Although the feature vector representation of each scenic spot has been obtained, the similarity measurement criteria such as the cosine formula or the Euclidean distance are usually used to calculate the similarity between the scenic spots in the tourist visit sequence and the to-be-predicted scenic spot according to the past way, and then the recommendation and sorting are performed. However, considering that the preference of the tourist may change over time, a strategy is proposed to combine the long-term preference and the current preference of the tourist in order to more accurately predict the next scenic spot to be visited by the tourist.

[0139] For the visit sequence u = {v u,1 ,v u,2 ,...,v u,n} of the tourist u, the last scenic spot visited by the tourist is used as the short-term preference representation of the tourist u, i.e., s s = v u,n . The long-term preference of the tourist is obtained by using the attention mechanism to multiply the weight of each scenic spot (except the last scenic spot in the sequence) with the scenic spot vector and then accumulating them, and the weight of the i-th scenic spot is represented by formula (4):

[0140] a i = q T σ(W1v n +W2v i +c) (4)

[0141] Formula (5) represents the long-term preference s l of the tourist:

[0142]

[0143] Further, the long-term preference of the tourist is linearly spliced with the current preference to obtain a final vector representation of the tourist;

[0144] s h =W3[s l ;s s ] (6)

[0145] Step 3.3: Attraction pre-prediction

[0146] The estimated score of the i-th attraction to be predicted is obtained by performing a dot product operation on the vector representation of the tourist and the vector of the attraction

[0147]

[0148] The The prediction probability of each attraction is obtained by normalizing using a softmax function

[0149]

[0150] The embodiment of the application solves the problem of knowledge extraction in the tourism industry using a hybrid model, solves the problem of high consumption of manpower and material resources, and judges the similarity of entities at two levels of strings and entity attributes, uses an entity alignment method based on similarity to solve the diversity fusion problem between multi-source heterogeneous data, discloses a tourism knowledge graph ontology construction method for modern service industry through a knowledge graph and user preferences, realizes the function of tourist attraction recommendation, has high timeliness and low maintenance intensity, and can realize accurate recommendation of tourist attractions.

[0151] The method disclosed by the application is applied in the tourism industry as a source of tourist attraction recommendation, realizes the characteristics of high timeliness and better application actual effect of the knowledge graph in the post-epidemic tourism recovery period, solves the problem of low satisfaction of current tourism recommendation, further improves the tourist experience, and promotes the high-quality development of future modern service industry.

[0152] The embodiment of the application further discloses a tourist attraction recommendation system based on a knowledge graph, which comprises an original data processing module, an ontology construction module and an attraction recommendation list acquisition module.

[0153] The original data processing module is used for acquiring tourism original data, constructing an entity extraction model, performing entity extraction on the acquired tourism original data based on the entity extraction model, and performing knowledge fusion on the extracted entities.

[0154] The ontology construction module is used for determining the actual application range of the entities, extracting related data of the ontology based on the actual application range of the entities, and continuing the ontology construction based on the related data of the ontology, the tourism original data and the entity data obtained after knowledge fusion, and acquiring a knowledge graph.

[0155] The scenic spot recommendation list acquisition module is configured to extract scenic spot information from the acquired knowledge graph, acquire a feature vector of the scenic spot, train the feature vector of the scenic spot, obtain a latent vector representation of a scenic spot sequence, construct long-term preference and short-term preference of a user based on the latent vector representation of the scenic spot sequence, and acquire a scenic spot recommendation list.

[0156] An embodiment of the terminal device provided by the present application provides a schematic diagram of the terminal device. The terminal device of the embodiment includes a processor, a memory, and a computer program stored in the memory and executable on the processor. The processor implements the steps in each of the method embodiments when executing the computer program. Alternatively, the processor implements the functions of each module / unit in each of the device embodiments when executing the computer program.

[0157] The computer program can be divided into one or more modules / units, which are stored in the memory and executed by the processor to complete the present application.

[0158] The terminal device can be a desktop computer, a notebook computer, a palm computer, a cloud server, and other computing devices. The terminal device can include, but is not limited to, a processor and a memory.

[0159] The processor can be a central processing unit (CPU), and can also be other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.

[0160] The memory can be used to store the computer program and / or modules, and the processor realizes various functions of the terminal device by running or executing the computer program and / or modules stored in the memory, and calling data stored in the memory.

[0161] The modules / units integrated in the terminal device, if realized in the form of software function units and sold or used as independent products, can be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the above-mentioned embodiment methods can also be completed by a computer program instructing related hardware, and the computer program can be stored in a computer readable storage medium. When the computer program is executed by a processor, the steps of the above-mentioned various method embodiments can be implemented. The computer program includes computer program code, which can be in the form of source code, object code, executable files or some intermediate forms, etc. The computer readable medium can include any entity or device capable of carrying the computer program code, recording medium, U disk, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium, etc. It should be noted that the content included in the computer readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction, for example, in some jurisdictions, according to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.

[0162] The above only describes the preferred embodiments of the present application and is not intended to limit the present application. The present application can have various modifications and changes for those skilled in the art. Any modification, equivalent replacement, improvement, etc. within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A knowledge graph-based scenic spot recommendation method, characterized in that, The method comprises the following steps: S1: obtaining tourism original data, and constructing an entity extraction model, performing entity extraction on the obtained tourism original data based on the entity extraction model, and performing knowledge fusion on the extracted entities; S2: determining the actual application range of the entity, extracting related data of the ontology based on the actual application range of the entity, and continuing ontology construction based on the related data of the ontology, the tourism original data and the entity data obtained after knowledge fusion to obtain a knowledge graph; S3: extracting scenic spot information from the obtained knowledge graph, obtaining a feature vector of the scenic spot, training the feature vector of the scenic spot to obtain a latent vector representation of a scenic spot sequence, constructing long-term preference and short-term preference of a user based on the latent vector representation of the scenic spot sequence, and obtaining a recommendation list of the scenic spot; In the step S1, the process of entity extraction comprises: constructing a BiLSTM-Att-CRF model to learn the context information of the entity and identify the entity; assigning different weights to the extracted entities according to importance; annotating the entities to identify the entity type; In the step S1, the process of knowledge fusion comprises: entity alignment: calculating the string similarity of the entity and setting a string similarity threshold; aligning two entities when the obtained string similarity is greater than the threshold; when the obtained string similarity is less than the threshold, calculating the attribute similarity of the entity and setting an attribute similarity threshold, aligning the entities when the obtained attribute similarity is greater than the set threshold, and not aligning the entities if the obtained attribute similarity is less than the set threshold; performing entity disambiguation based on the aligned entities; In the step S2, the ontology construction comprises the following steps: The determination of the actual application range of the entity comprises extracting the ontology and related terms according to the actual application scenario; The actual application scenario comprises scenic spot recommendation and route planning. 2.The knowledge graph-based scenic spot recommendation method of claim 1, wherein, The step S3 comprises the following steps: extracting scenic spot information from the knowledge graph based on a random walk strategy, and mapping the extracted scenic spot information to a low-dimensional space to obtain a feature vector representation of the scenic spot; inputting the obtained scenic spot feature vector representation into a gated recurrent unit network for training to obtain a latent vector representation of a scenic spot sequence; using an attention mechanism to model the long-term preference and short-term preference of the user to generate a scenic spot recommendation list that the user may like. 3.The method of claim 2, wherein, The step S3 comprises the following steps: The random walk strategy comprises the following steps: Given a source node v, a random walk of length L is generated , The i-th node in the random walk process is denoted as , The nodes are generated by the distribution in equation (1): where E denotes a set of edges in the knowledge graph, and Z is a regularization parameter, denotes the transition probability between node v and node x, which is expressed by formula (2): wherein represents the bias on the edges, expressed by equation (3): wherein p and q are parameters for controlling the graph walk, if p>max(q,1), the next sampling node is not the node t that has been visited before; if p<max(q,1), the next sampling node will always be sampled around the node t that has been visited before. 4.The method of claim 3, wherein, The step S3 comprises the following steps: Given a play sequence of a tourist u , using the last played attraction of the tourist as the short-term preference representation of the tourist u, i.e. , excluding the last attraction in the sequence, using an attention mechanism to multiply and accumulate the weight attraction vectors of each attraction in the sequence to obtain the long-term preference of the tourist, formula (4) represents the weight of the i-th attraction, The long-term preference of the visitor is represented by formula (5): Further, the long-term preference of the visitor is linearly spliced with the current preference to obtain the final vector representation of the visitor: performing dot product operation on the visitor vector representation and the vector of the i-th to-be-predicted scenic spot to obtain the estimated score of the scenic spot: will be described below. The predicted probability of each point of interest is normalized using a softmax function 5.A knowledge graph-based tourist attraction recommendation system for implementing the method of claim 1, characterized in that, The method comprises an original data processing module, an ontology construction module and a scenic spot recommendation list obtaining module. The original data processing module is configured to acquire tourism original data, construct an entity extraction model, perform entity extraction on the acquired tourism original data based on the entity extraction model, and perform knowledge fusion on the extracted entities. The ontology construction module is configured to determine an actual application range of the entities, extract relevant data of the ontology based on the actual application range of the entities, continue the ontology construction based on the relevant data of the ontology, the tourism original data, and the entity data obtained after the knowledge fusion, and acquire a knowledge graph. The scenic spot recommendation list acquisition module is configured to extract scenic spot information from the acquired knowledge graph, acquire a feature vector of the scenic spot, train the feature vector of the scenic spot to obtain a latent vector representation of a scenic spot sequence, construct long-term preference and short-term preference of a user based on the latent vector representation of the scenic spot sequence, and acquire a scenic spot recommendation list.

6. A terminal device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, The computer program is executed by the processor to implement the steps of the method according to any one of claims 1-4.

7. A computer-readable storage medium storing a computer program, wherein the computer program comprises the following steps of: receiving a request for a resource from a client; determining whether the client is authorized to access the resource; and if the client is authorized to access the resource, providing the resource to the client. The computer program is executed by the processor to implement the steps of the method according to any one of claims 1-4.