Deep learning hybrid model-based multi-dimensional construction method and system for tourism knowledge graph

By combining deep learning hybrid models with LLMs and MLP_Boost, the problems of accuracy and efficiency in the construction of tourism knowledge graphs are solved, achieving efficient and accurate knowledge graph construction to support intelligent tourism services.

CN120541234BActive Publication Date: 2026-05-19SICHUAN UNIV JINCHENG INST
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
SICHUAN UNIV JINCHENG INST
Filing Date
2025-04-18
Publication Date
2026-05-19

AI Technical Summary

Technical Problem

Existing methods for constructing tourism knowledge graphs suffer from accuracy and efficiency issues when dealing with large-scale, multi-source, heterogeneous data. Reliance on expert knowledge leads to inefficiency and difficulty in responding to rapid data changes. LLMs have low accuracy and interpretability in the generated content and require a lot of manual intervention.

Method used

A hybrid deep learning model, combining LLMs and MLP_Boost, is adopted to generate a pre-extracted knowledge set through data extraction, knowledge extraction, fusion, evaluation, and storage. The MLP_Boost deep learning algorithm is used to improve the multivariate relationship classification and the knowledge is stored in the form of a graph.

Benefits of technology

It improves the efficiency and accuracy of tourism knowledge graph construction, reduces the cost of manual intervention, enhances the accessibility and understandability of data, and provides personalized support for smart tourism services.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120541234B_ABST
    Figure CN120541234B_ABST
Patent Text Reader

Abstract

The application provides a tourism knowledge graph multi-dimensional construction method and system of a deep learning hybrid model, and belongs to the technical field of knowledge graph construction. The method comprises the following steps: S1. data extraction; S2. knowledge extraction; S3. knowledge fusion; S4. knowledge evaluation; and S5. knowledge storage. Through the combination of LLMs and the deep learning technology MLP_Boost, the application can effectively solve many problems in the current knowledge graph construction process and provide more accurate and personalized support for intelligent tourism services.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of tourism knowledge graph construction technology, and in particular to a method and system for multi-dimensional construction of tourism knowledge graphs using a deep learning hybrid model. Background Technology

[0002] With the development of big data and artificial intelligence technologies, knowledge graphs have been widely applied, especially in the tourism sector, where their application has gradually attracted attention from academia and industry. Nevertheless, the application of knowledge graphs in the tourism industry still faces several challenges, particularly regarding accuracy and efficiency when processing large-scale, multi-source, heterogeneous data. Furthermore, how to effectively embed tourism-specific entities and relationships and build scalable knowledge graphs remains a crucial problem that academia urgently needs to solve.

[0003] Currently, many studies have proposed different methods for constructing knowledge graphs to improve their construction efficiency and expressive power. For example, Guoqiang Liu et al. integrated multi-source data and expert knowledge through ontology construction and knowledge fusion to establish a knowledge-driven neural network model (KPNFE). Furthermore, Tangzhao Wei et al. proposed a template-based semi-automated knowledge graph construction method, which extracts triple data from multiple data sources using template filling, thereby improving the automation level of knowledge graph construction. However, although these methods have improved the construction efficiency of knowledge graphs to some extent, they still face challenges such as high training costs, high computational resource consumption, and how to improve computational efficiency while ensuring accuracy and recall.

[0004] With the development of generative AI technology, the application of large language models (LLMs) in knowledge graph construction has gradually become a research hotspot. LLMs possess powerful natural language processing capabilities, enabling them to extract rich semantic information from large amounts of text, and are therefore widely used in knowledge extraction and knowledge graph construction. For example, Yichong Zhang et al. proposed a few-shot learning method based on LLMs to construct and optimize a knowledge graph in the field of traditional Chinese medicine. Shirui Pan et al. proposed a roadmap pattern that integrates LLMs and knowledge graphs, achieving a complementary advantage between large models and knowledge graphs. Nevertheless, the black-box nature and susceptibility to illusions inherent in LLMs result in low accuracy and interpretability of the generated content, requiring significant manual intervention to correct errors and improve data quality.

[0005] To address the above issues, the construction of tourism knowledge graphs requires more precise domain knowledge extraction methods and more efficient knowledge graph generation mechanisms. Existing methods for constructing tourism domain knowledge graphs largely rely on expert knowledge and manual operation. This reliance can lead to inefficiency and error accumulation, and is unable to cope with the diversity and rapid changes in tourism data.

[0006] In conclusion, knowledge graph technology has great potential for application in the tourism sector, but it also faces a series of challenges, such as how to improve construction efficiency, reduce human intervention, and enhance accuracy and interpretability. Summary of the Invention

[0007] This invention provides a method and system for constructing a multi-dimensional tourism knowledge graph using a deep learning hybrid model. By combining LLMs with deep learning technology (MLP_Boost), it can effectively solve many problems in the current knowledge graph construction process and provide more accurate and personalized support for intelligent tourism services.

[0008] To achieve the above objectives, the present invention adopts the following technical solution:

[0009] This specification discloses a multi-dimensional method for constructing tourism knowledge graphs using deep learning hybrid models, including:

[0010] S1. Data Extraction: Collect tourism information, including structured data, semi-structured data, and unstructured data;

[0011] S2. Knowledge Extraction: Based on large-scale language models and MLP_Boost deep learning models, valuable information is extracted from structured, semi-structured, and unstructured data and converted into a structured form, including entities, attributes, and relationships between entities.

[0012] S3. Knowledge Fusion: Based on the results of knowledge extraction in S2, entity fusion is performed to eliminate redundant information and correct erroneous data that may have been generated during the data extraction stage.

[0013] S4. Knowledge Assessment: Based on the results of S3 knowledge fusion, entity assessment and relationship assessment are performed using precision, recall, and F1 score;

[0014] S5. Knowledge Storage: Based on the results of the knowledge assessment in S4, the structured knowledge is stored in the form of a graph to obtain a tourism knowledge graph.

[0015] In this manual, in S1, unstructured data is systematically organized and transformed into structured data, and entity types and relationship types are initially explored; in the tourism text data collection stage, text data is collected according to the initially explored entity types and relationship types, and the collected text needs to cover every entity type and relationship type;

[0016] Using data annotation software, preliminary data annotation is performed on the text data. The text data annotation is defined in JSON format, with each element being an object. Each object has text and list attributes, storing text data and triplet relationships.

[0017] In this specification, S2 includes:

[0018] S2.1. Knowledge Pre-extraction: Weighted fusion is performed using the matching Few-Shot Prompting method and fine-tuning techniques to generate a knowledge pre-extraction set;

[0019] S2.2. Named Entity Recognition: Based on a pre-extracted knowledge set, identify entities with specific meanings from unstructured text and classify them into predefined categories;

[0020] S2.3. Relation Extraction: Based on the knowledge pre-extraction set, semantic relationships between entities are extracted by identifying the relationships between entity pairs in the text;

[0021] S2.4. Attribute Extraction: Based on the knowledge pre-extraction set, identify and extract attribute information related to specific entities from unstructured or semi-structured text data.

[0022] In this specification, S2.1 includes:

[0023] S2.1.1. Prompt word construction: Using matching Few-Shot Prompting, we obtain accurate examples of matching for different entity types and different relationship types;

[0024] S2.1.2. Fine-tuning of the large model: Based on examples of accurate classification and matching for different entity types and different relationship types, the large language model is further trained;

[0025] S2.1.3. Weight-based fusion: The matching Few-Shot Prompting is combined with the large model fine-tuning of limited labeled data. While taking into account the precision and recall of the model, the knowledge extraction results of the two are weighted and fused to obtain the knowledge pre-extraction set.

[0026] In this specification, S2.3 includes:

[0027] S2.3.1. Multivariate Relation Classification Based on MLP_Boost Deep Learning Algorithm: The MLP_Boost deep learning algorithm is used to train a multivariate relation classification model using manually annotated text corpus, thereby improving the accuracy and standardization of knowledge graph triples;

[0028] S2.3.2. Relationship Validation: The matching Few-Shot Prompting technique is used to provide different input and output examples for different types of tourism entity relationships, and validation is performed through questioning and limiting the response format.

[0029] In this specification, in section S2.4, after extracting the attribute type and attribute value, the attribute type and attribute value information are mapped to the corresponding entity by associating them with entity keywords.

[0030] In this specification, in S3, entity fusion refers to the merging of records that appear in different forms in different tourism scenario corpora but actually refer to the same entity.

[0031] In this specification, in section S4, the evaluation formula is:

[0032] Where P is precision, R is recall, TP means the model predicts the same class as the actual class, FP means the model predicts other classes as the class to be identified, and FN means the model predicts other classes as the class to be identified.

[0033] In this specification, in S5, knowledge storage uses the graph-based database Neo4j.

[0034] This specification also discloses a multi-dimensional construction system for a tourism knowledge graph using a deep learning hybrid model, used to implement the multi-dimensional construction method for a tourism knowledge graph using a deep learning hybrid model as described above. The multi-dimensional construction system for a tourism knowledge graph using a deep learning hybrid model includes:

[0035] The data extraction module is used to collect tourism information, including structured data, semi-structured data, and unstructured data.

[0036] The knowledge extraction module is used to extract valuable information from structured, semi-structured, and unstructured data based on large language models and MLP_Boost deep learning models, and to convert it into a structured form, including entities, attributes, and relationships between entities.

[0037] The knowledge fusion module is used to perform entity fusion based on the results of knowledge extraction, so as to eliminate redundant information and correct erroneous data that may be generated in the data extraction stage.

[0038] The knowledge assessment module is used to evaluate entities and relationships based on the results of knowledge fusion, using precision, recall, and F1 score.

[0039] The knowledge storage module is used to save structured knowledge in the form of a graph based on the results of knowledge evaluation, thus obtaining a tourism knowledge graph.

[0040] In summary, the present invention has at least the following beneficial effects:

[0041] This invention is applicable to the construction of efficient and accurate tourism knowledge graphs in the smart tourism industry, improving data accessibility and understandability. This construction method can be used for decision support in areas such as intelligent question answering, smart customer service, and recommendation systems, providing tourists with richer and more personalized travel experiences. This contributes to further promoting the development of the tourism industry and economic recovery, opening up new possibilities for innovation and optimization in the tourism sector.

[0042] We adopted a weighted fusion method using few-shot learning and fine-tuning techniques of LLMs to generate a pre-extracted set of knowledge graph triples, which significantly reduced the cost of manual annotation and laid a solid foundation for building an accurate tourism knowledge graph.

[0043] We propose the MLP_Boost deep learning enhancement algorithm to perform multivariate classification of the pre-extracted relations, thus ensuring the standardization and relation verification of knowledge graph networks.

[0044] The few-shot learning technique of LLM classification matching is used to self-verify the results of named entity recognition and relation extraction, which effectively reduces the illusion problem in the LLM information extraction process and improves the accuracy and reliability of LLM named entity recognition and relation extraction results. Attached Figure Description

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

[0046] Figure 1 This is a schematic diagram illustrating the construction of a tourism knowledge graph based on model fusion involved in this invention.

[0047] Figure 2 This is a schematic diagram of the data collection and preprocessing process for tourism knowledge graphs.

[0048] Figure 3 This is a flowchart illustrating a method for extracting knowledge graph triples using few-sample hints based on LLMs matching.

[0049] Figure 4 This is a schematic diagram of the FSP_FT_Weighted_Fusion algorithm.

[0050] Figure 5 This is a schematic diagram of the matching-based Few-Shot Prompting self-verification method for tourism entity types.

[0051] Figure 6 This is a schematic diagram of the learning algorithm process based on MLP_Boost deep learning.

[0052] Figure 7 This is a schematic diagram of the matching-based Few-Shot Prompting self-verification method for tourism entity relationships.

[0053] Figure 8 A schematic diagram for extracting the triplets of tourism entity attributes.

[0054] Figure 9 This is a schematic diagram of knowledge fusion based on synonyms and pattern matching.

[0055] Figure 10-1 This is a schematic diagram of the confusion matrix of the CART algorithm for a single individual learner.

[0056] Figure 10-2 This is a schematic diagram of the confusion matrix of a single-entity learner MLP algorithm.

[0057] Figure 10-3 This is a schematic diagram of the confusion matrix of the GaussianNB algorithm for a single-entity learner.

[0058] Figure 10-4 This is a schematic diagram of the confusion matrix for the MLP_Boost deep learning enhancement algorithm. Detailed Implementation

[0059] The embodiments of the present invention will now be described in detail with reference to the accompanying drawings.

[0060] like Figure 1 As shown, this embodiment provides a multi-dimensional construction method for tourism knowledge graph using a deep learning hybrid model, including five stages: data extraction, knowledge extraction, knowledge fusion, knowledge evaluation, and knowledge storage.

[0061] S1. The data extraction stage mainly involves structured, semi-structured, and unstructured data. Web crawling technology is used to automate the collection of tourism information. Subsequently, this unstructured data is systematically organized and transformed to ultimately form structured data, allowing for an initial exploration of entity and relationship types.

[0062] S2. Knowledge extraction is a crucial step in the knowledge graph construction process. It involves extracting valuable information from unstructured, semi-structured, or structured data sources and converting it into a structured form, such as entities, attributes, and relationships between entities, thereby forming an ontological knowledge representation. This step in the present invention includes four parts:

[0063] S2.1. Knowledge Pre-extraction; To obtain a knowledge graph triple set that balances breadth and accuracy, this invention introduces a knowledge pre-extraction step based on LLMs. A weighted fusion method using matching Few-Shot Prompting and fine-tuning techniques is employed to generate the pre-extracted knowledge set. The knowledge pre-extraction part includes three main processes.

[0064] S2.1.1. Constructing Cue Words. Few-Shot Prompting is a technique used in pre-trained language models in the field of NLP. Its core idea is to guide the model to complete a specific task by providing a small number of examples, without requiring large-scale fine-tuning or training of the model.

[0065] S2.1.2. Large Model Fine-tuning. Large model fine-tuning refers to further training a pre-trained large language model using a specific dataset to adapt the model to a specific task or domain. The core goal of fine-tuning is to achieve refined knowledge infusion and precise matching of instruction systems. Through fine-tuning, the model can better adapt to the needs and characteristics of a specific domain, learn the knowledge and language patterns of that domain, and thus achieve better performance on specific tasks.

[0066] S2.1.3. Weight-based fusion. This invention combines matched Few-Shot Prompting with large-scale model fine-tuning based on limited labeled data, proposing the FSP_FT_Weighted_Fusion algorithm. This algorithm weights and fuses the knowledge extraction results of both methods while considering both the model's precision and recall, thus achieving the knowledge pre-extraction stage.

[0067] S2.2. Named Entity Recognition; Named Entity Recognition (NER) is the foundation of information extraction in the field of Natural Language Processing (NLP) and a prerequisite for attribute and relation extraction. Its goal is to identify entities with specific meanings from unstructured text and classify them into predefined categories.

[0068] S2.3. Relation Extraction; Relation extraction is a crucial step in information extraction. By identifying the relationships between entity pairs in a text, semantic relationships between entities are extracted, thereby providing support for the construction and application of knowledge graphs. This step in the present invention is divided into two parts.

[0069] S2.3.1. Multivariate Relation Classification Based on MLP_Boost Deep Learning Algorithm: Due to issues such as non-standard relation types, incorrect relation logic, and diverse relation expressions in the knowledge pre-extraction stage of large models, the MLP_Boost deep learning algorithm is mainly used to train a multivariate relation classification model using manually annotated text corpus, thereby improving the accuracy and standardization of knowledge graph triples.

[0070] S2.3.2. Relationship Validation: After the triplet prediction is corrected by the multivariate relationship classification model, the matching Few-Shot Prompting technique is mainly used to provide different input and output examples for different types of tourism entity relationships. Validation is carried out through methods such as questioning and limiting the response format to reduce the false information caused by the large model illusion phenomenon.

[0071] S2.4. Attribute Extraction; The purpose of attribute extraction is to identify and extract attribute information related to a specific entity from unstructured or semi-structured text data.

[0072] S3. Knowledge Fusion. The entity fusion stage aims to eliminate redundant information and correct any errors that may have occurred during the data extraction phase.

[0073] S4. Knowledge Assessment. The main tasks of the knowledge assessment stage are to ensure the accuracy, completeness, and reliability of the knowledge graph, discover new knowledge, optimize the construction method, and support application development. The knowledge assessment in this invention primarily focuses on entity recognition and relationship recognition, and is evaluated using precision, recall, and F1 score.

[0074] S5. Knowledge Storage. The main task of knowledge storage is to save structured knowledge in the form of a graph, facilitating retrieval and analysis. Its functions include providing efficient data retrieval, supporting large-scale data management, and facilitating knowledge integration and updates. Knowledge storage enables knowledge graphs to quickly respond to query requests, achieve effective knowledge organization and sharing, and provide a foundation for subsequent knowledge reasoning and applications.

[0075] In some embodiments, S1. Data extraction involves data collection and preprocessing: The data types involved in this invention mainly include structured data, semi-structured data, and unstructured data. Automated data collection of tourism information is achieved through the application of web crawling technology. Subsequently, this unstructured data is systematically organized and transformed to ultimately form structured data, and entity and relationship types are initially explored. In the tourism text data collection stage, text data needs to be collected according to the initially explored entity and relationship types. The collected text needs to cover every entity and relationship type, ensuring at least 500 high-quality text entries after filtering. To enrich the collection requirements, data sources are diversified, such as various tourism websites, tourism software, popular science encyclopedias and other websites and software, local cultural websites and software, etc.

[0076] The task of the data annotation phase is to transform raw data into a structured format that the model algorithm can understand and learn. This phase uses data annotation software to perform initial data annotation on the text data. Simultaneously, to meet the model's input data requirements, the text data annotations are defined in JSON format, with each element being an object. Each object has 'text' and 'list' attributes, storing text data and triplet relationships. The workflow of the data acquisition and data preprocessing phase is as follows: Figure 2 As shown.

[0077] S2. Knowledge Extraction; Knowledge extraction is a crucial step in the knowledge graph construction process, involving extracting valuable information from unstructured, semi-structured, or structured data sources and converting it into a structured form, such as entities, attributes, and relationships between entities, thereby forming an ontological knowledge representation. This invention primarily employs LLMs technology for knowledge extraction. First, a pre-extracted knowledge set is generated based on a weighted fusion method using matching, Few-Shot Prompting, and fine-tuning techniques. Second, in the named entity recognition part, a large model is used for self-verification of entities and their types. Next, in the relation extraction stage, the MLP_Boost deep learning algorithm is first used to perform multi-class classification of the pre-extracted relations, and then a large model is used for relation type self-verification. In the attribute extraction part, based on network data collection and cleaning, a structured triplet structure is formed through rules.

[0078] S2.1. Knowledge Pre-extraction; In order to obtain knowledge graph triples that balance breadth and accuracy.<Entity,Relation,Entity> In this invention, a knowledge pre-extraction step based on LLMs is introduced, which uses the matching Few-Shot Prompting method and fine-tuning technology to perform weighted fusion and generate a knowledge pre-extraction set.

[0079] S2.1.1. Prompt Construction; Few-Shot Prompting is a technique used in pre-trained language models in the NLP field. Its core idea is to guide the model to complete a specific task by providing a small number of examples, without requiring large-scale fine-tuning or training. Few-Shot Prompting has two key components: the Prompt template and Examples. The Prompt template component, typically composed of structured strings, is used to insert variables and guide the model on how to understand and process the input data. The Examples component, combined with the actual characteristics of the data, is presented to the model to help it understand the task. Each example typically includes the input and the expected output. This invention uses matching-based Few-Shot Prompting, that is, matching precise examples for different entity types and different relation types, rather than generic examples. The information extraction method (a few-shot prompt extraction knowledge graph triple method based on LLMs matching) is shown below (see the corresponding flowchart). Figure 3 ):

[0080] Input: A collection of tourism text corpora T{item1,item2,…,item N};

[0081] 1. Clean the text corpus T by removing symbols such as 【】|\r|\n|*|#|0-9|AZ|az|; 2. Construct an entity type set entity_type={e i |i=1,2,3,…,n}, where e i 3. Construct a relation type set `relation_type = {r}` where `n` is the number of entities and `n` is the number of entities. i |i=1,2,3,…,m}, where r i 4. Construct an example text set example_set = {text i |i=1,2,3,…,p}, where text i 5. Construct a set of example text triples: example_triple = {triple ...} i |i=1,2,3,…,p}, where p is the number of triplet example extraction results. i For the i-th input sample text i The implied triple relation, in JSON logical format, is:

[0082] ;

[0083] Where q is the example text.i The number of entity types contained, k is text i The number of relationships implied;

[0084] 6. Construct the prompt word template: template{entity_type,relation_type,example_set,example_triple,item i};

[0085] 7. for i init to Nmax do; 8. Based on the text item to be extracted i 9. Generate prompt word template; 10. Call pre-trained knowledge extraction LLMs and parse the knowledge pre-extraction results; 11. end; 12. Output: A set of triples in JSON format; Json = {triple i} i∈[1,N] ={nodes i ,edges i} i∈[1,N] .

[0086] In the process of knowledge graph triple pre-extraction using matching Few-Shot Prompting, the first step is to clean the corpus data, removing characters such as *, \r\n, and alphanumeric characters. The entity type and relation type to be pre-extracted are defined, where the entity type is entity_type = {e i |i=1,2,3,...,n},e i For specific entity types, such as scenic spots, hotels, festivals, traditional culture, etc., n is the number of entities; relation type relation_type={r i |i=1,2,3,...,m},r i Let m represent the relationships between entities, such as being located, being nearby, or being popular, and m be the number of relationships.

[0087] Next, we define an example component, which contains an input text example_set and an output result example_triple, where example_set = {text_set}. i |i=1,2,3,...,p},text i Let p be the i-th input example text, and p be the number of example texts; example_triple = {triple i |i=1,2,3,...,p},triple i For the i-th input sample text i The implied triple relation consists of a set of nodes and a set of edges, i.e., a triple. i{nodes i ,deges i}, node group i { <e ij ,type ij >| <e ij :entity j ,type ij :e l >}, containing the entity type e of the nodes l And e l ∈entity_type, and entity j For specific entity elements, q represents the node group. i The number of entities in the set. Edges (relationship edge groups). i { <e_left iω :e ω1 ,R iω :r ω ,e_right iω :e ω2 >}, where e ω1 ,e ω2 nodes belonging to the entity node group of this text extraction i r ω The relationship between the two is as follows, and r ω ∈relation_type, k is the relation edge group i The number of relationships implied.

[0088] The definition of the tourism prompt template component includes elements such as roles, objectives, steps, rules, input examples, and output responses. To guide the model in understanding and processing the input data, structured strings are defined for inserting variables, such as structured parameter entity types, relationship types, few-sample input examples, and few-sample output examples, as shown in Table 1. To ensure the quality and diversity of the examples as much as possible, seven entity types and ten types of entity-time relationships were selected to cover different scenarios, data sources, and business types when designing the entity type and relationship examples. Furthermore, considering the model's generalization ability and long-term stability, an incremental corpus example approach was used to design the example prompt word template.

[0089] Table 1. Triple templates for knowledge graph extraction based on few-shot hints using LLMs matching

[0090]

[0091]

[0092] S2.1.2. Large Model Fine-tuning; Large model fine-tuning refers to further training a pre-trained large language model using a specific dataset to adapt the model to a specific task or domain. The core goal of fine-tuning is to achieve refined knowledge infusion and precise matching of instruction systems. Through fine-tuning, the model can better adapt to the needs and characteristics of a specific domain, learn the knowledge and language patterns of that domain, and thus achieve better performance on specific tasks. This invention uses the large model fine-tuning method for pre-extraction of tourism knowledge graphs, employing the GLM4-9B-Chat model and using the LLaMA Factory framework for supervised fine-tuning (SFT) to improve the model's knowledge extraction capability in tourism graphs. The supervised training corpus is a semi-structured triple dataset with manual annotation. To extract pre-extracted triple data that conforms to tourism business, this invention proposes an extraction method based on the Chain of Thought (COT). The extraction process is guided by COT prompts, allowing the fine-tuned large model to complete the extraction step-by-step: first, entities in the text are identified; then, the semantic relationships between entities are analyzed; and finally, the identified entities and relationships are combined to form complete knowledge graph triples. This hierarchical extraction strategy improves the accuracy and completeness of knowledge graph construction. Table 2 provides examples of fine-tuning instructions during training.

[0093] Table 2. Examples of LLMs fine-tuning training instructions

[0094]

[0095] S2.1.3. Weight-based Fusion; In the knowledge extraction process, the advantage of Few-Shot Prompting lies in using a small amount of labeled data to help the model understand the task, improving model performance, reducing the workload of data preparation, and allowing the model to quickly adapt to new tasks without having to train from scratch, thus reducing training costs while meeting certain extraction breadth and accuracy requirements. However, Few-Shot Prompting also has some limitations. For example, it relies on the quality and diversity of the provided examples. If the quality of the input examples is low, the extraction accuracy will not be met. Furthermore, the insufficient generalization ability of LLM examples can lead to overfitting. Fine-tuning can reduce the generation of inaccurate or fictitious information by the model during knowledge extraction, improving the consistency and reliability of the output and reducing illusion problems. However, high-quality fine-tuning results depend on high-quality and massive amounts of labeled data, which may be difficult to obtain or costly. Additionally, higher accuracy can lead to a decrease in model recall. Therefore, this invention combines matching Few-Shot Prompting with large-scale model fine-tuning using limited labeled data, proposing the FSP_FT_Weighted_Fusion algorithm. This algorithm, while balancing model precision and recall, weights and fuses the knowledge extraction results from both methods to achieve the knowledge pre-extraction stage. The fusion principle is as follows: Figure 4 As shown.

[0096] Few-Shot Prompting extracts the entity and relation set as defined in the following way: The model voting weight corresponding to the pre-sampling error ε1 is ρ1 = 1 / ε1 2 Fine-tuning of a large model extracts a set of entities and relations, defined as follows: The pre-sampling error ε2 corresponds to the model voting weight ρ2 = 1 / ε2. 2 The result of the fusion of the two is That is, the extracted result Ω is the union of Ω1 and Ω2. The extraction results of each part are shown in the following formula. The function f(Ω) identifies the entity set nodes and relation set edges after fusion.

[0097]

[0098] exist Figure 4 In the space Ω1-Ω2 on the left, the weights of the Few-Shot Prompting model are ρ1, and the weights of the Fine-Tuning model are ρ2 = 0. Therefore, pre-extracted knowledge fusion mainly uses FSP. Figure 4In the right-hand Ω2-Ω1 space, the weights of the fine-tuning model are ρ2, and the weights of the few-shot prompting model are ρ1 = 0. Therefore, pre-extracted knowledge fusion primarily uses Fourier Transform (FT). Figure 4 In the intermediate Ω1∩Ω2 space, the weights of the Few-Shot Prompting model and the Fine-Tuning model are ρ1 and ρ2. In cases where entities are the same but of different types, or where relational entities have the same nodes but different relation types, the pre-extracted knowledge fusion uses a weighted voting method with weights max{ρ1, ρ2} = max{1 / ε1}. 2 ,1 / ε2 2}

[0099] S2.2. Named Entity Recognition; Named Entity Recognition (NER) is the foundation of information extraction in Natural Language Processing (NLP) and a prerequisite for attribute and relation extraction. Its goal is to identify entities with specific meanings from unstructured text and classify them into predefined categories. This invention employs a fusion method of matching-based Few-Shot Prompting and Fine-Tuning to extract defined entity types from tourism text data. To further optimize the illusion generated by the large-scale model LLMS during knowledge pre-extraction—that is, the inconsistency between the model-generated content and the input provided by facts or experiments—a large-scale model-based entity self-verification stage is introduced. The matching Few-Shot Prompting method provides different input-output examples for different types of tourism entities, and verification is performed through methods such as questioning and limiting response formats. Introducing entity self-verification can mitigate the potential for inaccurate or misleading model outputs due to the large model illusion phenomenon, thereby improving the model's credibility and usability. The matching-based Few-Shot Prompting self-verification method for tourism entity types is shown below (verification flowchart available). Figure 5 ):

[0100] Input: Tourism text corpus T{item i} i∈[1,N]

[0101] edges i { <e_left iω ,R iω ,e_right iω >| <e_left iω :e ω1 ,R iω :r ω ,e_right iω:e ω2 >;

[0102] Entity Nodes{nodes i}={nodes i |<Θ ij :θ j ,type ij :e j >,e j ∈entity_type,j∈[1,len(nodes i )]} i∈[1,N] ;

[0103] 1. Construct a collection of sample templates for verification types: Verify_set = {verify i |verify i =Ψ(e i ),i=1,2,3,…,n}, where e i For entity type, It is e i The text description function, where n is the number of entities;

[0104] 2. Construct the output response For entity type, ∈entity_type,Res i It is e i 3. Construct the prompt word template template{Verify_set,Response_set}; 4. for i init to Nmax do; 5. for j init to len(nodes) i )do; 6. Determine the nodes ij The actual entity type l; 7. Construct a matching template based on the entity type of l: template{verify l Res l ,item i}; 8. Call the pre-trained validation LLMs and parse the validation results; 9. End; 10. End; 11. Output: Model validation set in JSON format.

[0105] Before entity self-verification, prepare the input data: a corpus of tourism text T{item}. i} i∈[1,N] and the extracted entity type set Nodes{nodes i}, each text item in the corpus i A corresponding set of entity type nodesi Each group of nodes i Composed of several entity nodes <Θ ij :θ j ,type ij :e j >Composition, where θ j It is the entity name, e j For entity types, the entity types for tourism are shown in Table 3. First, a set of verification type example templates, `Verify_set`, is constructed. This set is used to match learning examples of different entity types, i.e., `verify`. i =Ψ(e i ), Ψ represents the entity type e i The text description function; constructs the LLMS output response set Response_set, which is used to respond to validation questions for different types of entities. ),Right now It is e i The text question function has the number of questions equal to the number of entity types, n. Next, the prompt word template is constructed using the Verify_set and Response_set from the previous two steps. During the large model validation phase, each text corpus item... i Each entity node pair of nodes ij Determine the specific value I of the entity type, and construct a matching template template{verify} based on the entity type of l. l Res l ,item i The template is passed to the training and validation LLMs, and the validation results are parsed. Finally, the validation results of the large model are stored as a model validation set in JSON format {Ver i} i∈[1,N] This set consists of entity node pairs nodes. ij and verification results Result ij The result should consist of {Yes,No} statements, and the actual number of verification results should be [number missing].

[0106] Table 3. Types of Tourism Entities

[0107]

[0108] S2.3. Relation Extraction; Relation extraction is a crucial step in information extraction. By identifying the relationships between entity pairs in text, semantic relationships between entities are extracted, thus supporting the construction and application of knowledge graphs. This invention utilizes a weighted fusion of large-scale model Few-Shot Prompting and fine-tuning techniques to pre-extract entity relationships from tourism corpora. The entities in the pre-extracted triple relationships undergo LLM self-verification, thus confirming that the pre-extracted triple relationships are verified entity relationships. To optimize the illusions generated by the large-scale model LLMS during relation pre-extraction, this invention first trains an MLP_Boost deep learning algorithm based on manually labeled corpora to correct the multivariate classification of some pre-extracted relationships. Then, Few-Shot Prompting technology is used to provide different input-output examples for different types of tourism entity relationships, and relationship verification is performed through methods such as questioning and limiting response formats.

[0109] S2.3.1. Multivariate Relation Classification Based on MLP_Boost Deep Learning Algorithm; Due to issues such as non-standard relation types, incorrect relation logic, and diverse relation representations in the knowledge pre-extraction stage of large models, the MLP_Boost deep learning algorithm is mainly used to train a multivariate relation classification model using manually annotated text corpora, thereby improving the classification of knowledge graph triples.<Entity,Relation,Entity> The accuracy and standardization of the algorithm are as follows. Figure 6 As shown.

[0110] The first step is data balancing, specifically balancing the multi-class classification dataset for machine learning. In tourism entity relationship classification, this invention mainly studies 10 types of entity relationships, including location, adjacency, popularity, and provision, as shown in Table 4. During the learning sample balancing process, a combination of undersampling and oversampling is used to prevent the lack of representativeness of the learning samples due to class imbalance. The multi-class classification dataset includes entities, entity types, relationships, and object entities. <e i1 ,t i1 ,r i ,e i2 ,t i2 The data consists of text such as >. In the data preprocessing stage, one-hot encoding and label encoding are mainly performed on entity type features and relation type targets. In the model training stage, supervised classification training is first performed using single-entity learners such as CART, GaussianNB, and MLP. Next, based on the training effect, an MLP_Boost deep learning method is constructed to learn the dataset S using a boosting combination approach. This involves training with CART and GaussianNB weak classifiers, and the resulting weak classifier recognition results are used as the model weights {ρ} for the samples.i The datasets are fused together (i = 1, 2, ..., n) into a dataset S, and finally, a multilayer perceptron (MLP) is used for corrective prediction. The improved combined model is evaluated using accuracy, precision, recall, and F1 score.

[0111] Table 4. Types of Tourism Entity Relationships

[0112] Subject entity object entity relation Subject entity object entity relation attractions City-District-County-Town-Township lie in City-District-County-Town-Township Traditional culture Inheritance attractions hotel There are nearby City-District-County-Town-Township festival Will celebrate attractions Traffic venues There are nearby City-District-County-Town-Township Local delicacies Include attractions Local delicacies You can taste City-District-County-Town-Township Traffic venues contain attractions Traditional culture Popularity hotel Local delicacies supply attractions festival Will celebrate hotel City-District-County-Town-Township lie in attractions attractions Adjacency hotel Traffic venues There are nearby

[0113] S2.3.2. Relationship Verification; Triples<Entity,Relation,Entity> After correcting the predictions using a multivariate relation classification model, the matching-based Few-Shot Prompting technique is primarily employed to provide different input-output examples for different types of tourism entity relations. Validation is performed through methods such as questioning and limiting the response format to reduce erroneous information caused by the large model illusion phenomenon and improve the accuracy of triple relations. The self-validation process (based on the matching-based Few-Shot Prompting tourism entity relation self-validation method) is shown below (see flowchart for details). Figure 7 ):

[0114] Input: Tourism text corpus T{item i} i∈[1,N] The node-edge dataset after relation classification correction {triple i} i∈[1,N] ={nodes i ,edges i} i∈[1,N] ;

[0115] 1. Construct a set of entity relationship validation example templates: Ver_set = {V i |V i =φ(e i1 ,r i ,e i2 ), i = 1, 2, 3, ..., K}, where e i1 e is the entity subject. i2 As a physical object, e i2 ∈Nodes{nodes i}, φ i yes <e i1 ,r i ,e i2 > The text description function, where K is the number of combinations of subject-object relations of different entities; 2. Construct the output response Res_set={Res i |Res i =τ(e i1 ,r i ,ei2 ),i=1,2,3,…,K},τ i yes <e i1 ,r i ,e i2 3. Construct the prompt word template template{Ver_set,Res_set}; 4. for i init to Nmax do; 5. for j init to len(edges) i 6. Determine the edges of each table. ij 7. Construct a matching template `template{V` based on the type of `L`, specifying the subject, object, and relation type `L`. L Res L ,item L}; 8. Call the pre-trained validation LLMs and parse the validation results; 9. End; 10. End; 11. Output: Model validation set in JSON format:

[0116]

[0117] This stage mainly utilizes the matching Few-Shot Prompting in the original corpus T{item i} i∈[1,N] Focusing on validating the node-edge dataset {nodes} after correction for multivariate relation classification. i ,edges i} i∈[1,N] The rationality of this is determined by first constructing a set of example templates for verifying entity relationships {V}. i =φ(e i1 ,r i ,e i2 This set is used to match learning examples of different entity relationship types. i1 e is the entity subject. i2 r is the entity object. i The subject-object relationship is defined, and φ is the text description function of the triple. Next, the LLMS output response set Res_set is constructed, which is used to respond to validation questions τ(e) of different entity relationship types. i1 ,r i ,e i2 ), where τ is the text question function of the triple, and the number of questions is K, which is the number of combinations of different entity subject-object relations; after completing the construction of the prompt word template, similar to entity verification, each text corpus item can be... i Corresponding edges ij Determine the relation type L under the subject-object entity constraint, and construct a matching template template{V} based on the relation type L.L Res L ,item L The template with examples is passed to the training and validation LLMs for validation. Finally, the validation results for each edge are stored in the following format:

[0118] And respond with YES and No.

[0119] S2.4. Attribute Extraction; The purpose of attribute extraction is to identify and extract attribute information related to a specific entity from unstructured or semi-structured text data. The main data sources for attribute extraction in this invention are semi-structured and structured data from popular science encyclopedias and tourism-related websites and software platforms. These platforms provide rich information on tourism entities and corresponding attribute descriptions, but their content is usually not presented in a structured form; therefore, attribute extraction technology is needed to structure and organize this information.

[0120] like Figure 8 As shown, the blue dashed box on the left displays the entity attribute types and their corresponding attribute values ​​extracted from unstructured or semi-structured text. The attribute extraction results are stored in the format ["attribute type", "attribute value"]. After extracting the attribute types and values, the attribute types and values ​​are mapped to specific entities by associating them with entity keywords, such as the marked scenic spot entity Potala Palace in the green dashed box. The final result of attribute extraction is stored in the form of triples ["entity", "attribute type", "attribute value"]. This triple format can be directly used to construct relational networks, facilitating further data mining and information retrieval.

[0121] S3. Knowledge Fusion; The entity fusion process aims to eliminate redundant information and correct erroneous data that may have been generated during the data extraction stage. The entity fusion of this invention mainly merges records that appear in different forms in different tourism scenario corpora but actually refer to the same entity, exploring the knowledge fusion forms of two tourism entities. First, using synonym matching, for entities such as scenic spots, culture, festivals, and food, synonyms for these four entities are extracted from authoritative data sources such as popular science encyclopedias, tourism websites, and software to form a synonym dictionary. Within the synonym dictionary, a standardized entity name is defined for each group of synonyms. Synonym matching and replacement are performed on named entities generated during the knowledge extraction process. Second, pattern matching rules are defined according to language habits. By mining the collected text data, the reduction patterns of words in entities are explored, such as "XXX city," which is usually expressed as "XXX." Therefore, for entities of types such as city-district-county-town-village, transportation locations, and hotels, pattern matching rules are defined to perform entity fusion, such as... Figure 9 As shown.

[0122] S4. Knowledge Evaluation; The evaluation of knowledge extraction mainly includes entity evaluation and triple relation evaluation. Since both the number of entity types and the number of relation types are greater than or equal to 2, it falls under multivariate evaluation. Therefore, this invention uses accuracy, precision, and recall as metrics. The evaluation formula is as follows: Where TP (True Positive) means that the model predicts the same class as the actual class; P is precision, R is recall, FP means that the model predicts other classes as the class to be identified; and FN means that the model predicts other classes as the class to be identified.

[0123] S5. Knowledge Storage; A knowledge graph is a structured semantic knowledge base used to describe concepts and their relationships in the physical world in symbolic form. The basic building blocks are triples such as [entity-relationship-entity] or [entity-attribute-attribute value]. Entities are linked together through relations, forming a network-like knowledge structure. Therefore, this invention uses the mainstream graph-based database Neo4j for knowledge storage. Neo4j is a high-performance, NoSQL graph database that stores structured data on a network rather than in tables. Neo4j can also be considered a high-performance graph engine with full transactional features and efficient retrieval performance. In the process of storing the tourism knowledge graph, nodes are first created to represent seven types of tourism-related entities, such as attractions, local specialties, and hotels. Next, edges are added to represent the relationships between subject and object entities, such as 10 types of relationships like "located in," "provided," and "popular." Finally, attributes are added to enrich the graph's semantics, i.e., attribute values ​​are added according to the attribute types defined for different entities.

[0124] The technical concept of this invention is as follows:

[0125] This invention describes the process of constructing a tourism knowledge graph based on a fusion method of large-scale model technology and deep learning models such as MLP_Boost. The knowledge extraction part introduces a pre-extraction stage, proposing a weighted fusion method based on large-scale model Few-Shot Prompting and model fine-tuning techniques. To improve the accuracy of large-scale model recognition, an MLP_Boost multivariate relation classification model based on a combination of machine learning and deep learning enhancements is constructed to correct and standardize the relation extraction results. To reduce the information extraction illusion of large-scale models, a matching Few-Shot Prompting technique is used for self-verification of entity and relation types.

[0126] This study constructs a knowledge graph using multi-source heterogeneous datasets and extracts information based on a fusion of LLMs and MLP_Boost deep learning small models. By introducing LLMs and fine-tuning the weighted fusion knowledge pre-extraction stage, it balances precision and recall. A few-shot learning technique using LLMs classification and matching is employed to self-validate named entity recognition and relation extraction results, reducing the illusion of information extraction. Compared to traditional knowledge graph networks that rely heavily on domain experts, this research proposes a construction method that offers greater flexibility and accuracy while significantly reducing the workload and human resource costs of manual annotation.

[0127] In one specific embodiment, a weighted fusion method using Few-Shot Prompting and model fine-tuning techniques is employed to generate a pre-extracted knowledge set. For named entity recognition, a large model is used for self-verification of entities and their types. In the relation extraction stage, a multivariate relation classification model based on machine learning and deep learning is constructed, and large-scale model verification of relation types is performed. The attribute extraction stage integrates structured and semi-structured attribute features, adding triplets of attributes. The knowledge fusion stage uses a thesaurus for entity fusion. During the experiments, the Few-Shot Prompting stage uses the QWen 14B model, and the fine-tuning stage uses the GLM4 model. Experiments show that the weighted fusion information extraction method FSP_FT_Weighted_Fusion proposed in this invention, after correction using the MLP_Boost multivariate relation classification model and large-scale model self-verification, exhibits high precision, recall, and F1 score. Finally, the Neo4j graph database is used to visualize and store the knowledge network. The algorithm implementation mainly relies on large model technology, adopting the Qwen2.5 14B model and using the matching Few-ShotPrompting method for knowledge extraction and verification; it adopts the GLM4-9B-Chat model and uses the LLaMA Factory framework for supervised fine-tuning (SFT).

[0128] The experimental data was primarily obtained from tourism-related websites using web crawling technology. After data cleaning and preprocessing, manual annotation was performed. The annotated text data volume is 500+, covering 7 types of tourism entities including scenic spots, food, and traditional culture, and 10 types of relations. The storage format is a JSON file containing the source text and triples of <entity subject: type, relation, entity object: type>.

[0129] The named entity recognition experiment mainly focused on two aspects: entity and type extraction and verification. Methods employed included Few-Shot Prompting (FSP) extraction, large-model fine-tuning extraction, and the weighted fusion extraction proposed in this invention. FSP emphasizes the breadth of entity recognition and is suitable for unlabeled samples; while large-model fine-tuning emphasizes the accuracy of entity recognition and is suitable for labeled samples. Therefore, this study proposed the FSP_FT_Weighted_Fusion algorithm by weighted fusion of the two extraction results and verified the extraction results. By comprehensively comparing different large-model algorithms and different few-sample prompt matching methods, the accuracy, precision, and recall of the experimental results were evaluated, as shown in Table 5. Table 5. Evaluation of the experimental results of tourism entity extraction using the Qwen model, ChatGPT model, and GLM Fineturning fusion model under the conditions of matched few-sample prompts and general-sample prompts.

[0130] Large model algorithm Precision Recall F1 score Qwen+matched Few-Shot Prompting 0.889 0.870 0.879 Qwen+common Few-Shot Prompting 0.887 0.810 0.847 ChatGPT+matched Few-Shot Prompting 0.938 0.931 0.934 ChatGPT+common Few-Shot Prompting 0.924 0.907 0.915 GLM4+Fine_turning 0.968 0.829 0.893 Qwen_FSP_GLM_FT_Weighted_Fusion 0.943 0.927 0.935

[0131] Table 6. Comparison of self-verified and unverified NER experimental results

[0132] Large model algorithm Precision Recall F1 score Qwen+matched Few-Shot Prompting 0.889 0.870 0.879 Qwen+matched Few-Shot Prompting+Verification 0.974 0.866 0.917 FSP_FT_Weighted_Fusion 0.943 0.927 0.935 Qwen_FSP_GLM_FT_Weighted_Fusion+Verification 0.980 0.923 0.951

[0133] In the entity extraction experiment, two large models using the Few-Shot Prompting method were employed: the free version QWen14B and the commercial version Chat GPT. The fine-tuned large model used GLM4. Comparative experiments were conducted by providing matched learning examples and general learning examples, as shown in Table 5. The two large models performed significantly better with the matched Few-Shot Prompting method than with the general Few-Shot Prompting method. The QWen large model based on matched Few-Shot Prompting achieved a recall of 87%, maintaining good breadth of recognition, with a precision of 88.9% and an F1 score of 87.9%. GLM4+Fine_turning, using supervised learning with labeled data, showed a significant advantage in recognition precision (96.8%), but a slightly lower recall of 82.9%. The weighted fusion model Qwen_FSP_GLM_FT_Weighted_Fusion proposed in this study balances accuracy and breadth in the knowledge extraction process, achieving an accuracy of 94.3%, a recall of 92.7%, and an F1 score of 93.5%, which is slightly higher than the overall recognition performance of Chat GPT.

[0134] To further optimize the illusion problem in the information extraction process of the large model, the Few-Shot Prompting method of entity type matching was adopted for self-validation of the large model. As shown in Table 6, the experimental results show that the recognition effect was improved overall under the premise of validation. Among them, the F1 score of the weighted fusion method FSP_FT_Weighted_Fusion reached 0.951.

[0135] The MLP_Boost deep learning algorithm for multivariate relation classification was tested. The main objective was to use machine learning and deep learning algorithms to train a multivariate relation classification model using manually labeled text corpora, thereby improving the performance of knowledge graph triples.<Entity,Relation,Entity> The accuracy and standardization of the data are ensured. The tourism entity relationship classification includes 10 types of entity relationships, such as location, adjacency, popularity, and provision. To prevent class imbalance caused by multi-class classification, the relationship types in the text data are first balanced based on undersampling and oversampling to ensure the representativeness of the samples. Next, the dataset... <e i1 ,t i1 ,r i ,e i2 ,t i2 Preprocessing is performed, with entity type features and relation type targets undergoing one-hot encoding and label encoding. The machine learning training process uses algorithms such as CART, GaussianNB, and MLP for supervised classification training, with training results as follows: Figure 10-1 , Figure 10-2 , Figure 10-3 , Figure 10-4 As shown in Table 7, the accuracy of the supervised learning model experiments is as follows.

[0136] Table 7. Accuracy of Experimental Results for Supervised Learning Models

[0137]

[0138]

[0139] The three types of single-agent learners showed significant differences in the recognition of categories 0, 4, 5, and 7. The experiment employed a boosting approach, combining the three single-agent learners and training them on dataset S. Specifically, CART and GaussianNB weak classifiers were first used for training, and the weak classifier recognition results {ρ_cart} were analyzed. i} 1≤i≤n ,{ρ_gnb i} 1≤i≤nThe model weights used as samples are added to the set S, and a multilayer perceptron (MLP) is used for correction and prediction. The accuracy of the improved model MLP_Boost (i.e., CART_GNB_MLP Boosting) is 0.978. The classification performance of each relation is shown in Table 8, which shows that the classification performance of multivariate relations has been further improved.

[0140] Table 8. Experimental results of the MLP_Boost deep learning algorithm for 10 classifications.

[0141] Precision Recall F1 score Precision Recall F1 score 0 1.00 0.88 0.94 7 0.83 0.67 0.74 1 0.83 1.00 0.91 8 1.00 1.00 1.00 2 1.00 1.00 1.00 9 1.00 1.00 1.00 3 1.00 1.00 1.00 Accuracy 0.98 4 1.00 1.00 1.00 Macro Avg 0.97 0.95 0.96 5 1.00 1.00 1.00 Weighted Avg 0.98 0.98 0.98 6 1.00 1.00 1.00

[0142] Relation Extraction Validation: After correction by the MLP_Boost multivariate classification model, the entity relationship combinations are self-validated using a large model in this stage to optimize the illusion in the LLMs relationship extraction process. To explore the recognition performance of the proposed weighted fusion model Qwen_FSP_GLM_FT_Weighted_Fusion, experiments were conducted comparing it with QWen14B and Chat GPT, and the large model was fine-tuned using GLM4, as shown in Table 9. It can be seen that after weighted fusion, FSP_FT_Weighted_Fusion has a better recognition performance, with an F1 score of 0.929. After self-validation by the large model, the accuracy reaches 0.941 and the F1 score is 0.932, as shown in Table 10.

[0143] Table 9. Evaluation of the experimental results of tourism relationship extraction using the Qwen model, ChatGPT model, and GLM Fineturning fusion model under conditions of few matching prompts and common matching prompts.

[0144]

[0145]

[0146] Table 10. Comparison of results from self-verified and unverified RE experiments

[0147] Large model algorithm Precision Recall F1 score Qwen_Few_Shot_Prompting+GLM4_Fine_turning 0.926 0.931 0.929 Qwen_Few_Shot_Prompting+GLM4_Fine_turning Verification 0.941 0.924 0.932

[0148] Knowledge Storage: Based on a large model with few example prompts and a fine-tuning fusion method, information was extracted from the text corpus through the above experiments, and a tourism knowledge graph was constructed. The extracted triples <entity, relation, entity> and the collected and processed <entity, attribute, attribute value> were stored using the Neo4j graph database. For example, the scenic spot entity XX Palace is represented by a dot, and the connecting line between the scenic spot entity subject XX Palace and the food and specialty product entity object represents the subject-object relationship.

[0149] This embodiment discloses a multi-dimensional tourism knowledge graph construction system based on a deep learning hybrid model, used to implement the multi-dimensional tourism knowledge graph construction method based on a deep learning hybrid model as described above. The multi-dimensional tourism knowledge graph construction system based on a deep learning hybrid model includes:

[0150] The data extraction module is used to collect tourism information, including structured data, semi-structured data, and unstructured data.

[0151] The knowledge extraction module is used to extract valuable information from structured, semi-structured, and unstructured data based on large language models and MLP_Boost deep learning models, and to convert it into a structured form, including entities, attributes, and relationships between entities.

[0152] The knowledge fusion module is used to perform entity fusion based on the results of knowledge extraction, so as to eliminate redundant information and correct erroneous data that may be generated in the data extraction stage.

[0153] The knowledge assessment module is used to evaluate entities and relationships based on the results of knowledge fusion, using precision, recall, and F1 score.

[0154] The knowledge storage module is used to save structured knowledge in the form of a graph based on the results of knowledge evaluation, thus obtaining a tourism knowledge graph.

[0155] The embodiments described above are for illustrative purposes only and are not intended to limit the invention. Therefore, any changes in numerical values ​​or substitutions of equivalent elements should still fall within the scope of this invention.

Claims

1. A method for constructing a multi-dimensional tourism knowledge graph using a deep learning hybrid model, characterized in that, include: S1. Data Extraction: Collect tourism information, including structured data, semi-structured data, and unstructured data; S2. Knowledge Extraction: Based on large-scale language models and MLP_Boost deep learning models, valuable information is extracted from structured, semi-structured, and unstructured data and converted into a structured form, including entities, attributes, and relationships between entities. S3. Knowledge Fusion: Based on the results of knowledge extraction in S2, entity fusion is performed to eliminate redundant information and correct erroneous data that may have been generated during the data extraction stage. S4. Knowledge Assessment: Based on the results of S3 knowledge fusion, entity assessment and relationship assessment are performed using precision, recall, and F1 score; S5. Knowledge Storage: Based on the results of the S4 knowledge assessment, the structured knowledge is stored in the form of a graph to obtain a tourism knowledge graph; In S1, unstructured data is systematically organized and transformed to form structured data, and entity types and relationship types are initially explored; During the tourism text data collection phase, text data is collected according to the entity types and relationship types initially explored. The collected text needs to cover every entity type and relationship type. Using data annotation software, the text data is initially annotated. The text data annotation is defined in JSON format, with each element being an object. Each object has text and list attributes, storing text data and triplet relationships. S2 includes: S2.

1. Knowledge Pre-extraction: Weighted fusion is performed using the matching Few-ShotPrompting method and fine-tuning techniques to generate a knowledge pre-extraction set; S2.

2. Named Entity Recognition: Based on a pre-extracted knowledge set, identify entities with specific meanings from unstructured text and classify them into predefined categories; S2.

3. Relation Extraction: Based on the knowledge pre-extraction set, semantic relationships between entities are extracted by identifying the relationships between entity pairs in the text; LLMs classification matching few-shot learning technology is used to self-verify the named entity recognition and relation extraction results; S2.

4. Attribute Extraction: Based on the knowledge pre-extraction set, identify and extract attribute information related to specific entities from unstructured or semi-structured text data; S2.1 includes: S2.1.

1. Prompt word construction: Using matching Few-Shot Prompting, we obtain accurate examples of matching for different entity types and different relationship types; S2.1.

2. Fine-tuning of the large model: Based on examples of accurate classification and matching for different entity types and different relationship types, the large language model is further trained; S2.1.

3. Weight-based fusion: The matching Few-Shot Prompting is combined with large-scale model fine-tuning based on limited labeled data. While considering both precision and recall, the knowledge extraction results from both are weighted and fused to obtain a pre-extracted knowledge set. The fusion principle is as follows: The entity and relation set extracted by Few-Shot Prompting is defined as... Pre-sampling error The corresponding model voting weights are Large model fine-tuning extracts the entity and relation set as defined Pre-sampling error The corresponding model voting weights are The result of the fusion of the two is That is, the extraction result of fusion. for and The union of the functions, and the extraction results of each part are shown in the following formula, function The merged entity set (nodes) and relation set (edges) are identified. ; exist In the space, the weights of the Few-Shot Prompting model are The weights of the large model are =0, therefore pre-extracted knowledge fusion to Mainly; in The space, the weights of the large model are The weights of the Few-Shot Prompting model are Therefore, pre-extracted knowledge fusion is used to Mainly; in In the spatial part, the weights of the Few-ShotPrompting model and the large model are: In cases where entities are identical but of different types, or where relational entities have the same node but different relation types, pre-extracted knowledge fusion employs a weighted voting method with weights of 1 / 2. ; S2.3 includes: S2.3.

1. Multivariate Relation Classification Based on MLP_Boost Deep Learning Algorithm: The MLP_Boost deep learning algorithm is used to train a multivariate relation classification model using manually annotated text corpus, thereby improving the accuracy and standardization of knowledge graph triples; S2.3.

2. Relationship Validation: The matching Few-Shot Prompting technique is used to provide different input and output examples for different types of tourism entity relationships, and validation is performed through questioning and limiting response formats; In S2.4, after extracting the attribute type and attribute value, the attribute type and attribute value information are mapped to the corresponding entity by associating them with entity keywords.

2. The method for multi-dimensional construction of tourism knowledge graph using a deep learning hybrid model according to claim 1, characterized in that, In S3, entity fusion is the merging of records that appear in different forms in different tourism scenario corpora but actually refer to the same entity.

3. The method for multi-dimensional construction of tourism knowledge graph using a deep learning hybrid model according to claim 1, characterized in that, In S4, the evaluation formula is: ; ; ; in P For accuracy, R For recall rate, TP This indicates that the model predicts the same category as the actual category. FP This indicates that the model predicts other categories as the category to be identified; FN This indicates that the model predicts the category to be identified as another category.

4. The method for multi-dimensional construction of tourism knowledge graph using a deep learning hybrid model according to claim 1, characterized in that, In S5, knowledge storage uses the graph-based database Neo4j.

5. A multi-dimensional tourism knowledge graph construction system based on a deep learning hybrid model, characterized in that... A method for constructing a multi-dimensional tourism knowledge graph using a deep learning hybrid model as described in any one of claims 1 to 4, wherein the multi-dimensional tourism knowledge graph construction system using the deep learning hybrid model comprises: The data extraction module is used to collect tourism information, including structured data, semi-structured data, and unstructured data. The knowledge extraction module is used to extract valuable information from structured, semi-structured, and unstructured data based on large language models and MLP_Boost deep learning models, and to convert it into a structured form, including entities, attributes, and relationships between entities. The knowledge fusion module is used to perform entity fusion based on the results of knowledge extraction, in order to eliminate redundant information and correct erroneous data that may have been generated during the data extraction stage. The knowledge assessment module is used to evaluate entities and relationships based on the results of knowledge fusion, using precision, recall, and F1 score. The knowledge storage module is used to save structured knowledge in the form of a graph based on the results of knowledge evaluation, thus obtaining a tourism knowledge graph.