A method for intelligent mining of map POI knowledge graph tasks based on large language model
Through the intelligent mining method of map POI knowledge graph tasks based on a large language model, the problem that traditional machine learning is difficult to handle multiple tasks of map POI data is solved, and efficient and accurate data mining and analysis are achieved, providing high-quality services for geographic information services and business recommendations.
Patent Information
- Application Number
- CN202411630816.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-15
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2044-11-15
AI Technical Summary
Traditional machine learning methods find it difficult to effectively handle various tasks of map POI data, such as parent-child point mining, similarity identification, and place name and address information extraction. In addition, the unstructured characteristics of POI data make information representation and extraction complex.
A map POI knowledge graph task intelligent mining method based on a large language model is adopted. By constructing a fine-tune dataset, data augmentation, SFT retraining, reward learning and reinforcement learning, the PPO algorithm is used to optimize model parameters and achieve multi-task processing.
It improves the efficiency and consistency of map POI data processing, enhances the performance of the model, can better learn data characteristics and patterns, and provide efficient and accurate knowledge graph task mining, which is applied to fields such as geographic information services and business recommendations.
Smart Images

Figure CN119514663B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and more particularly to a method for intelligent mining of map POI knowledge graph tasks based on a large language model. Background Art
[0002] In today's information explosion era, unstructured data such as text, images, and audio is increasing. Among them, map POI (Point of Interest) data, as a key type of unstructured data, contains a wealth of valuable content, including geographic locations, business information, and tourist attraction introductions. However, due to the unstructured nature of POI data, its information mining and utilization have always faced significant challenges.
[0003] Machine learning-based methods have achieved numerous successes in fields such as text and images. However, due to the unique nature of map POI data, traditional machine learning approaches face a number of challenges when processing this data. First, POI data presents a wide variety of tasks, such as parent-child point mining, similarity identification, category determination, and place name and address information extraction. Traditional machine learning methods struggle to simultaneously handle these diverse tasks. Second, the unstructured nature of POI data complicates the representation and extraction of its information, requiring more advanced models.
[0004] Therefore, we need a new, large-model-based technical approach to process the unstructured data of map POIs to solve the problems of traditional methods. Summary of the Invention
[0005] In view of this, the present invention provides a map POI knowledge graph task intelligent mining method based on a large language model, which can process the unstructured data of map POI and can handle various tasks of map POI data.
[0006] In order to achieve the above object, the present invention adopts the following technical solutions:
[0007] A method for intelligent mining of map POI knowledge graph tasks based on a large language model, including:
[0008] Get map POI data;
[0009] Construct a finetune dataset based on map POI data and task type, and perform data augmentation on the finetune dataset;
[0010] After pre-training the large language model with the expanded dataset, SFT retraining and reward learning optimization are performed;
[0011] Reinforce learning of large language models based on the PPO algorithm;
[0012] Based on the trained large language model, map POI data is processed to perform knowledge graph mining tasks.
[0013] Preferably, the task types include POI parent-child point mining, POI similarity identification, POI category determination, and POI place name and address information extraction.
[0014] Preferably, for the parent-child point mining of POI, the objective function of the large language model is:
[0015]
[0016] Among them, θ represents the large model parameter, L text Represents the loss function between text description and parent-child point labels, L label is the loss function between parent and child point labels, α is the learning rate, N is the number of POI data samples, represents the i-th parent node label, Represents the label of the i-th child node.
[0017] Preferably, for the parent-child point mining of POI, the large language model SFT further includes the following steps before retraining:
[0018] Use the pre-trained large language model to encode the text description x to obtain the text representation z, where the POI data sample consists of the text description x and the corresponding parent and child point labels;
[0019] Use the softmax function to map the text representation z to the probability distribution of parent-child point labels;
[0020] P(y parent / x;θ)=softmax(W parent z+b parent );
[0021] P(y child / x;θ)=softmax(W child z+b child );
[0022] Among them, W parent 、b parent Represent the weight matrix and bias vector of the parent node label, W child 、b child Represent the weight matrix and bias vector of the child node labels respectively.
[0023] Preferably, in reward learning, the cumulative reward R is calculated as follows:
[0024]
[0025] Where T represents the number of interaction steps, r t represents the reward at step t;
[0026] Use rw algorithm for gradient update:
[0027] θ←θ+αΔθf(θ)R
[0028] Among them, α is the task weight hyperparameter, θ represents the large model parameter, and f(θ) represents the learning optimization objective function.
[0029] Preferably, in reinforcement learning, the update formula for defining the policy network is:
[0030]
[0031] Among them, θ' is the updated model parameter, J(θ) represents the performance of the current policy network, max_kl represents a hyperparameter used to limit the update amplitude, and ε represents a positive number.
[0032] Preferably, the map POI data includes text and image unstructured information.
[0033] As can be seen from the above technical solution, compared with the prior art, the present invention discloses a method for intelligent mining of map POI knowledge graph tasks based on a large language model, which has the following advantages:
[0034] Multi-task processing: It can handle multiple tasks of map POI data, such as parent-child point mining, similarity point identification, category judgment, and place name and address information extraction, improving the efficiency and consistency of data processing.
[0035] Large model application: Using the LLM large model can better learn the characteristics and patterns of data, improving the performance and expression of the model.
[0036] Reward learning optimization: The introduction of reward learning model and RW algorithm can calculate the reward signal according to the task objective function, automatically optimize the model parameters, and improve the performance of knowledge graph tasks.
[0037] Further optimization of reinforcement learning: Using the PPO algorithm, the parameters of the policy network are continuously updated through interaction with the environment, further optimizing the performance of knowledge graph mining.
[0038] By combining these techniques, we can achieve efficient and accurate mining and analysis of map POI data, providing superior services for geographic information services, business recommendations, and tourist navigation. This approach also has potential for application in other unstructured data mining fields, and is expected to promote the wider use of large models in data mining and analysis.
[0039] In general, the present invention has important significance and practical value in solving the unstructured problem of map POI data, and is expected to achieve significant application effects in the fields of geographic information processing, business recommendations, and intelligent navigation. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are merely embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.
[0041] Figure 1 This is a flow chart of a map POI knowledge graph task intelligent mining method based on a large language model provided by the present invention. DETAILED DESCRIPTION
[0042] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.
[0043] The embodiment of the present invention discloses a map POI knowledge graph task intelligent mining method based on a large language model, such as Figure 1 As shown, including:
[0044] Get map POI data;
[0045] Construct a finetune dataset based on map POI data and task type, and perform data augmentation on the finetune dataset;
[0046] After pre-training the large language model with the expanded dataset, SFT retraining and reward learning optimization are performed;
[0047] Reinforce learning of large language models based on the PPO algorithm;
[0048] Based on the trained large language model, map POI data is processed to perform knowledge graph mining tasks.
[0049] In this embodiment, the task types include mining parent and child points of POIs, identifying similar points of POIs, determining the category of POIs, and extracting place name and address information of POIs.
[0050] For example, specifically for the POI similarity task, the examples used to construct the finetune dataset might include POI pairs with similar geographic locations, business types, or other related attributes. For example, a sample might include two POIs, with a similarity label between them indicating that they are similar in some way. This helps the model learn how to discriminate the similarity of POI pairs.
[0051] Data augmentation is performed on the finetune dataset to improve the model's ability to generalize data so that it can still perform well in different situations and changes.
[0052] Data augmentation can be implemented in a variety of ways. For text data, synonym replacement, random word insertion, or word deletion can be used to improve the model's robustness to the text. These data augmentation methods help improve the model's generalization capabilities, making it more robust across diverse scenarios and addressing the issue of insufficient training due to data scarcity.
[0053] In this embodiment, the core of the algorithm of the present invention is based on a large language model. SFT (Soft Fine-Tuning) retraining is performed through a pre-trained model (such as glm-6b), and the instruction process is used to transform the various tasks of POI into a unified learning framework. Then, a reward learning model and a reinforcement learning process are used to optimize the performance of the model. Among them, the reward learning model uses the RW (Reward Weighting) algorithm, and the reinforcement learning process uses the PPO (Proximal Policy Optimization) algorithm. These training methods are all based on LoRA (Low-Rank Approximation).
[0054] First, a pre-trained large language model (such as GLM-6B) is used as the base model and SFT (Soft Fine-Tuning) retraining is performed. In SFT retraining, the instruction process is used to convert the various tasks of POI into an instructional form to facilitate model learning.
[0055] For various tasks related to map POIs, we transform them into semantic guidance tasks. For example, we use POI parent-child point mining as an example. Given N POI data samples, each sample consists of a text description x and corresponding parent-child point labels. We transform this task into a joint task of predicting text descriptions and parent-child point labels.
[0056] For the parent-child point mining of POI, the objective function of the large language model is:
[0057]
[0058] Among them, θ represents the large model parameter, Ltext Represents the loss function between text description and parent-child point labels, L label is the loss function between the parent and child point labels, α is the learning rate, which is used to balance the importance of the two loss functions, and N is the number of POI data samples. represents the i-th parent node label, Represents the label of the i-th child node.
[0059] In order to perform SFT retraining, the task objectives need to be represented as soft labels. For POI parent-child point mining, a pre-trained large language model is used to encode the text description x to obtain the text representation z, where the POI data sample consists of the text description x and the corresponding parent-child point labels;
[0060] Use the softmax function to map the text representation z to the probability distribution P(y) of the parent node label parent / x;θ) and the probability distribution P(y) of the child node labels child / x;θ);
[0061] P(y parent / x;θ)=softmax(W parent z+b parent );
[0062] P(y child / x;θ)=softmax(W child z+b child );
[0063] Among them, W parent 、b parent Represent the weight matrix and bias vector of the parent node label, W child 、b child Represent the weight matrix and bias vector of the child node labels respectively.
[0064] Based on the pre-trained model, labeled data is used to further adjust the model parameters to make it better suited to specific tasks.
[0065] In this example, to optimize the model's performance in knowledge graph tasks, a reward learning model is introduced and trained using the RW algorithm (Reward-Weighted Regression). The goal of the reward learning model is to maximize the cumulative reward through interaction with the environment. Specifically, based on the POI annotated data and the task objective function, a reward signal is calculated and used to update the model parameters to improve the model's performance in the task.
[0066] In the reward learning model, the cumulative reward R is defined as the sum of all rewards obtained from the interaction with the environment:
[0067]
[0068] Where T represents the number of interaction steps, r t represents the reward at step t;
[0069] In order to update the model parameters, the RW algorithm is used for gradient update. Assuming f(θ) is the learning optimization objective function of the model, θ represents the parameters of the model, then the model parameter update formula is:
[0070] θ←θ+αΔθf(θ)R
[0071] Among them, α is the learning rate, which is set to 0.01.
[0072] In this embodiment, based on the reward learning model, the PPO algorithm (Proximal Policy Optimization) is further used to perform a reinforcement learning process to further optimize the performance of knowledge graph mining. In this process, the parameters of the policy network are continuously updated through interaction with the environment to maximize the cumulative reward.
[0073] In reinforcement learning, the update formula for the large language model policy network is defined as:
[0074]
[0075] Among them, θ' is the updated model parameter, J(θ) represents the performance of the current policy network, max_kl represents a hyperparameter used to limit the update amplitude, max__kl = 0.01, and ε represents a small positive number, ε = 0.1.
[0076] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on the differences from other embodiments. Reference can be made to the common and similar parts between the various embodiments. For the devices disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the description is relatively simple, and the relevant parts can be referred to the method description.
[0077] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present invention. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention is not limited to the embodiments shown herein but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A map POI knowledge graph task intelligent mining method based on a large language model, characterized by: include: Get map POI data; Construct a finetune dataset based on map POI data and task type, and perform data augmentation on the finetune dataset; After pre-training the large language model with the expanded dataset, SFT retraining and reward learning optimization are performed; Reinforce learning of large language models based on the PPO algorithm; Process map POI data based on the trained large language model to perform knowledge graph task mining; The task types include POI parent-child point mining, POI similarity identification, POI category judgment and POI place name and address information extraction; For the parent-child point mining of POI, the objective function of the large language model is: Among them, θ represents the large model parameter, L text Represents the loss function between text description and parent-child point labels, L label is the loss function between parent and child point labels, α is the learning rate, N is the number of POI data samples, represents the i-th parent node label, Represents the label of the i-th child node.
2. A map POI knowledge graph task intelligent mining method based on a large language model according to claim 1, characterized in that: For POI parent-child point mining, the large language model SFT also includes the following before retraining: Use the pre-trained large language model to encode the text description x to obtain the text representation z, where the POI data sample consists of the text description x and the corresponding parent and child point labels; Use the softmax function to map the text representation z to the probability distribution of parent-child point labels; P(y parent / x:θ)=softmax(W parent ·z+b parent ): P(y child / x:θ)=softmax(W child ·z+b child ): Among them, W parent 、b parent Represent the weight matrix and bias vector of the parent node label, W child 、b child Represent the weight matrix and bias vector of the child node label, P(y parent / x; θ) is the probability distribution of the parent node label, P(y chid / x; θ) is the probability distribution of child node labels.
3. The method for intelligent mining of map POI knowledge graph tasks based on a large language model according to claim 1, characterized in that: In reward learning, the cumulative reward R is calculated as follows: Where T represents the number of interaction steps, r t represents the reward at step t; Use rw algorithm for gradient update: θ←θ+αΔθf(θ)R Among them, α is the learning rate, θ represents the large model parameters, and f(θ) represents the learning optimization objective function.
4. The method for intelligent mining of map POI knowledge graph tasks based on a large language model according to claim 1, characterized in that: In reinforcement learning, the update formula for defining the policy network is: Among them, θ' is the updated model parameter, J(θ) represents the performance of the current policy network, max_kl represents a hyperparameter used to limit the update amplitude, and ε represents a positive number.
5. The method for intelligent mining of map POI knowledge graph tasks based on a large language model according to claim 1, characterized in that: Map POI data includes unstructured information such as text and images.
Citation Information
Patent Citations
Method and system for establishing POI parent-child point pairs
CN111881371A
Map data validity verification method and device, electronic equipment and storage medium
CN117131954A