A travel guide planning generation method and system based on artificial intelligence

By using AI-based entity constraint semantic extraction and multi-objective optimization techniques, personalized and actionable travel guides were generated, solving the problem of insufficient understanding of user needs in traditional methods and improving the intelligence and practicality of travel planning.

CN122240942APending Publication Date: 2026-06-19KYUSHU HAOLI (SHANDONG) E-COMMERCE TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
KYUSHU HAOLI (SHANDONG) E-COMMERCE TECH CO LTD
Filing Date
2026-02-28
Publication Date
2026-06-19

AI Technical Summary

Technical Problem

Traditional travel planning methods lack a deep understanding of individual user needs and struggle to balance the selection of multiple types of resources and multi-dimensional constraints within a limited timeframe, resulting in incomplete, unreasonable, and unenforceable travel guides.

Method used

Using an artificial intelligence-based approach, user needs are accurately identified through a semantic extraction model with entity constraints. A weighted graph of tourism resources is constructed and multi-objective optimization is performed. A genetic algorithm is used to solve for the optimal route, and a natural language generation model is combined to convert it into an executable travel guide.

Benefits of technology

It achieves accurate semantic modeling of user needs, improves the intelligence and practicality of travel guides, ensures that routes are highly aligned with user needs, optimizes time utilization and budget control, and generates scientific and actionable guides.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122240942A_ABST
    Figure CN122240942A_ABST
Patent Text Reader

Abstract

This invention relates to the technical field of travel itinerary planning, and discloses an artificial intelligence-based method and system for generating travel itinerary plans. The method includes: extracting tourism semantic features from tourism needs using an entity-constrained semantic extraction model; matching tourism semantic features with tourism resource features using semantic similarity matching, and selecting successfully matched tourism resources; constructing a weighted tourism resource graph using the selected tourism resources as nodes, and constructing a multi-objective optimization function for the travel route based on the weighted tourism resource graph; solving the multi-objective optimization function for the travel route using a genetic algorithm to obtain the optimal travel route; and converting the optimal travel route into a complete travel itinerary using a natural language generation model. This invention achieves automatic matching and intelligent optimization of user travel needs to tourism resources, solving the problems of insufficient personalization and difficulty in comprehensively considering constraints in traditional travel itinerary planning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of travel itinerary planning, and more particularly to a method and system for generating travel itinerary plans based on artificial intelligence. Background Technology

[0002] With the rapid development of the tourism industry and the continuous upgrading of tourism consumption patterns, users are no longer satisfied with traditional fixed routes or standardized group tours. Instead, they increasingly prefer personalized travel experiences that match their interests, budgets, and time constraints. Traditional travel itinerary planning methods, which rely on human experience or travel agency-designed guides, are often based on rules of experience or single-dimensional recommendations, lacking a deep understanding of individual user needs. When faced with complex and diverse travel demands, these methods often struggle to balance the selection of various resources such as tourist attractions, food, and accommodation within a limited timeframe. They also fail to adequately match users' constraints in terms of budget control, travel methods, travel duration, accessibility, and interests, resulting in incomplete, unreasonable, or even unfeasible travel itineraries.

[0003] Therefore, how to effectively utilize artificial intelligence technology to accurately analyze users' natural language tourism needs, automatically filter resources that highly match user needs from tourism big data, and on this basis, combine multi-dimensional constraints to construct an optimizable tourism route model, and further generate complete and directly usable travel guides, has become a core issue and an important development direction in smart tourism research and practice.

[0004] In existing research, some scholars and enterprises have attempted to use recommendation systems and big data analysis methods to push travel guides. For example, patent CN114510651B proposes a method and system for pushing travel guides based on local regional characteristics. This method obtains the browsing content of the first user, determines whether the user has a travel intention, and further analyzes the browsing content to extract travel-related information. Based on this, it filters preset travel information related to the user's region from the database, infers a keyword set, and matches the keyword set with travel-related information to generate multiple travel guides, which are then pushed to other related users, achieving regionalization and a certain degree of personalization of travel information. However, this method mainly relies on user browsing content for intent recognition and keyword inference, which is prone to inaccurate interpretation of travel intent due to incomplete or ambiguous user descriptions. The generated travel guides are essentially a collection of recommended travel information, lacking a process of weighted graph modeling and multi-objective optimization of travel resources, making it difficult to form continuous and directly executable travel routes.

[0005] To address this issue, this invention proposes an AI-based method for generating travel itineraries. By introducing AI technology for semantic matching, it helps users analyze a large amount of travel resource information in a short time and generate personalized travel itineraries based on their needs and preferences, thereby improving the accuracy and practicality of travel itinerary planning. Summary of the Invention

[0006] This invention provides an AI-based method and system for generating travel guides. It utilizes an entity-constrained semantic extraction model to accurately identify users' explicit and implicit needs in areas such as location, budget, travel mode, and interests, solving the problems of incomplete and ambiguous demand analysis under traditional manual rules. Through semantic matching of tourism semantic features and tourism resource features, it ensures that the selected tourism resources highly match the user's travel needs, overcoming the shortcomings of existing methods that rely solely on keyword matching, leading to insufficient relevance in recommendation results. It constructs a weighted graph of tourism resources and simultaneously considers multiple dimensions such as opening hours, travel time, visit duration, budget price, and semantic preferences in a multi-objective optimization function, effectively solving the problems of complex constraints and difficulty in balancing conflicting objectives in travel route planning. It uses a genetic algorithm to solve the multi-objective optimization function, efficiently finding the optimal solution in a large-scale solution space. Combined with a natural language generation model, it transforms the optimal route into a highly readable and complete travel guide containing daily itineraries and precautions, thus addressing the shortcomings of existing methods where travel route results are difficult to apply directly and lack executability. This significantly improves the intelligence and practicality of the travel guide generation process.

[0007] To achieve the above objectives, the technical solution adopted by the present invention is as follows: On the one hand, an AI-based method for generating travel itinerary plans is provided, including the following steps: S1: Obtain users' travel needs and use an entity-constrained semantic extraction model to extract travel semantic features from the travel needs; S2: Construct a tourism resource database and extract the tourism resource features of each group of tourism resources. Use semantic similarity matching to match the tourism semantic features with the tourism resource features, and select the tourism resources that are successfully matched. S3: Using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted graph of tourism resources is constructed. Based on the weighted graph of tourism resources, a multi-objective optimization function for tourism routes is constructed. S4: Use a genetic algorithm to solve the multi-objective optimization function of the travel route to obtain the optimal travel route, and call a natural language generation model to convert the optimal travel route into a complete travel guide.

[0008] As a further improvement of the present invention: Furthermore, a semantic extraction model based on entity constraints is used to extract tourism semantic features from tourism demand, including: Users input their travel needs through the client, and the semantic features of travel needs are extracted using a semantic extraction model based on entity constraints. The entity-constraint-based semantic extraction model includes an input layer, an encoding layer, an entity recognition layer, a semantic constraint layer, and a semantic feature extraction layer. The input layer is used to receive travel requests and perform word segmentation on the travel requests, dividing them into several travel request fields. The encoding layer uses a pre-trained language model to perform contextual encoding on the tourism demand field, thereby obtaining the word vectors corresponding to the tourism demand field. The entity recognition layer adopts a BiLSTM-CRF structure to identify the bidirectional hidden state of word vectors and the corresponding entities. The bidirectional hidden state of word vectors is the concatenation result of the forward hidden state and the backward hidden state of word vectors captured by the two LSTM structures of BiLSTM. The entities include tourist destination entities, tourist time entities, budget range entities, number of travelers entities, travel mode entities, interest preference entities, accommodation preference entities, dietary requirements entities, and special needs entities. The semantic constraint layer sets entities for which no word vectors were identified to be unrestricted based on the entity recognition results; The semantic feature extraction layer extracts the tourism demand fields corresponding to the word vectors of entities such as tourist destination, tourist time, budget range, number of travelers, and mode of travel, and concatenates them as basic tourism features. It also extracts the bidirectional hidden states of the word vectors of entities such as interest preference, accommodation preference, dietary requirements, and special needs, and concatenates them as extended tourism features. Finally, it concatenates the extracted basic tourism features and extended tourism features as tourism semantic features.

[0009] Furthermore, a tourism resource database is constructed, and the tourism resource characteristics of each group of tourism resources are extracted, including: The tourism resource database contains multiple sets of tourism resources, including tourist attractions, local cuisine, and hotels. Each set of tourism resources includes basic information and type information. The basic information includes location, type of tourism resource, opening hours, and average price per person. The type information for tourist attractions includes recommended visit duration, attraction type, and interest tags. The type information for local cuisine includes restaurant type, main cuisine, and interest tags. The type information for hotels includes accommodation type tags, star rating, and interest tags. The basic information of tourism resources is concatenated to form a basic information vector of tourism resources. The type information is then transformed into a word vector to obtain a type information vector of tourism resources. The basic information vector and the type information vector are concatenated to form the tourism resource features of tourism resources.

[0010] Furthermore, semantic similarity matching is used to match tourism semantic features with tourism resource features, and successfully matched tourism resources are selected, including: The semantic similarity matching formula is:

[0011] ; ; ; in, The semantic feature of tourism F and the tourism resource features of the nth group of tourism resources are represented. The semantic similarity between them, where N represents the number of groups of tourism resources in the tourism resource database. Representing the semantic features of tourism and the features of tourism resources Positional similarity between them Representing the semantic features of tourism and the features of tourism resources Temporal similarity between them Representing the semantic features of tourism and the features of tourism resources Price similarity between them Representing the semantic features of tourism and the features of tourism resources Similarity of interests between them Indicates interest-price ratio factor; This represents the tourism demand field corresponding to the tourism destination entity in the tourism semantic feature F. Indicate the characteristics of tourism resources The location in Indicate the characteristics of tourism resources Opening hours This represents the tourism demand field corresponding to the tourism time entity in the tourism semantic feature F. This indicates that the nth group of tourism resources is open within the time frame of the tourism time entity in tourism demand. If , it means that the location of the nth group of tourism resources is consistent with the actual tourism location; Indicate the characteristics of tourism resources The average price per person in the middle, This represents the tourism demand field corresponding to the budget range entity in the tourism semantic feature F. This represents the type of tourism resource corresponding to the nth group of tourism resource characteristics. Indicates the type of tourism resources Price consumption ratio Indicates the types of tourism resources that can be used. Average daily budget per person This indicates a reward slope that prioritizes lower prices, and is used when the average daily budget per person is not lower than the average price per person. This indicates the degree of over-budget depreciation, and is used when the average price per person is higher than the average daily budget per person. Represents an exponential function with the natural constant as its base; The calculation method is based on tourism resource characteristics. Cosine similarity between the type information vector and the tourism extended features in the tourism semantic feature F; Based on the travel demand field corresponding to the travel time entity, the user's travel duration (Len, in days) is calculated, and the number of alternative travel resources for different types of travel resources is also calculated. Specifically, the number of alternative travel resources for tourist attractions, local cuisine, and hotels are 3Len, 4Len, and 4Len, respectively. , Indicates rounding up; Select the 3Len tourism resources with the highest semantic similarity that are tourism attractions from the tourism resource database; Four tourism resources with the highest semantic similarity and the type of local cuisine were selected from the tourism resource database. From the tourism resource database, select tourism resources that are hotels and have the highest semantic similarity. One tourism resource.

[0012] Furthermore, by using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted tourism resource graph is constructed, including: The tourism resource weighted map takes the following form: ; Wherein, G represents the weighted graph of tourism resources, E represents the set of nodes, and V represents the set of edge weights between nodes. The transportation information between tourism resources is the travel time between tourism resources based on the tourism demand field corresponding to the travel mode entity in tourism demand.

[0013] Furthermore, a multi-objective optimization function for the tourism route is constructed based on the weighted graph of tourism resources, including: ; in, This represents a multi-objective optimization function for a tourism route. The multi-objective function takes the tourism route as input and outputs the value of the multi-objective optimization function that maximizes the tourism route. This represents a travel route, which consists of a sequence of nodes visited each day. E represents the set of nodes in the weighted graph of tourism resources. , where e represents any node in node E. Indicates travel routes A binary variable indicating whether node e is visited at position q on day d. , A value of 0 indicates a tour route. Node e is not visited at position q on day d. 1 represents a tourist route Node e is visited at position q on day d, meaning node e is part of the travel route. The q-th node in the sequence of nodes visited on day d. This represents the maximum number of nodes visited on day d. Indicates the semantic similarity of node e; Indicates travel routes Items exceeding the budget, Indicates travel routes Time cost item This represents the budget control coefficient. Indicates the time control factor; Indicates travel routes Violation of constraints, tourist routes The more constraints are violated, the larger the value of the violated constraint. The constraints of the multi-objective optimization function for the tourism route include: The number of nodes in the tourism route for tourist attractions, local cuisine, and hotels are 2 Len, 3 Len, and 3 Len respectively. ; The daily travel time shall not exceed 12 hours, and the travel time includes the sum of the time spent at each node and the sum of the travel time. The tourism resource type of the last access node at the end of each day is a hotel. The first access node at the beginning of each day is the last access node of the previous day by default, but it is not reflected in the travel route. The same tourist attractions and local delicacies will only appear once in the travel route.

[0014] Furthermore, a genetic algorithm is used to solve the multi-objective optimization function of the tourism route to obtain the optimal tourism route, including: Initialize and generate R groups of individuals, each group consisting of a sequence of nodes visited each day, and treat each group of individuals as a travel route; Each group of individuals is used as the input value of the multi-objective optimization function of the tourism route. The value of the multi-objective optimization function of the tourism route is used as the fitness of the individual. The R groups of individuals are iterated with the goal of selecting the individual with the highest fitness until the preset maximum number of iterations Max is reached. The fitness of each group of individuals after reaching the preset maximum number of iterations is calculated, and the individual with the highest fitness is selected as the optimal tourism route. The process for each iteration includes: retaining the M individuals with the highest fitness that do not participate in the iteration; calculating the roulette probability of the individuals not retained based on their fitness; selecting individuals from the individuals not retained as parents based on the roulette probability; performing a mutation operation on the selected parents to generate new offspring; and replacing the individual with the lowest fitness among the individuals not retained with the offspring generated by the parents.

[0015] Furthermore, a natural language generation model is invoked to convert the optimal travel route into a complete travel guide, including: The optimal travel route is input into a natural language generation model. Based on the daily node sequence and the corresponding tourism resources of each node in the optimal travel route, the natural language generation model generates a complete travel guide text, which includes daily itinerary, transportation instructions, accommodation arrangements, dining information, attraction introductions, and personalized tips.

[0016] On the other hand, this invention also proposes an artificial intelligence-based travel guide planning and generation system, including a feature extraction device, a travel route planning module, and a travel guide generation device: The feature extraction device is used to obtain users' travel needs, extract travel semantic features from travel needs using an entity-constrained semantic extraction model, construct a travel resource database, extract travel resource features for each group of travel resources, and use semantic similarity matching to match travel semantic features with travel resource features, and select successfully matched travel resources. The tourism route planning module is used to construct a tourism resource weighted graph by taking the selected tourism resources as nodes and the traffic information between the selected tourism resources as edge weights. Based on the tourism resource weighted graph, a multi-objective optimization function for the tourism route is constructed. The genetic algorithm is used to solve the multi-objective optimization function for the tourism route to obtain the optimal tourism route. The travel guide generation device is used to call a natural language generation model to convert the optimal travel route into a complete travel guide. This achieves the aforementioned method for generating travel itinerary plans based on artificial intelligence.

[0017] Compared with existing technologies, this invention proposes a method and system for generating travel itinerary plans based on artificial intelligence, which has the following beneficial effects: First, the entity-constrained semantic extraction model proposed in this invention achieves accurate semantic modeling of users' travel needs by introducing a multi-layered structured design. Specifically, it uses a pre-trained language model (such as BERT) as the encoding layer, which can fully utilize contextual information and overcome the shortcomings of traditional static word vector representation in capturing context, thereby improving semantic representation capabilities. Furthermore, it utilizes a BiLSTM-CRF structure for entity recognition, which not only extracts forward and backward dependencies of words but also introduces entity sequence constraints through the CRF layer and the Viterbi algorithm, ensuring the accurate identification of core entities such as travel destinations, times, and budgets. The accuracy of entity recognition and the rationality of entity sequences are improved. The semantic constraint layer avoids interference from missing features in subsequent modeling by completing unrecognized entities into zero vectors, while also enhancing robustness in the face of incomplete input. By extracting and concatenating basic tourism features and extended tourism features in a hierarchical manner, it can simultaneously take into account users' hard needs (such as time, budget, and travel mode) and flexible preferences (such as dietary requirements and interest tags), providing a structured, complete, and high-dimensional semantic feature representation for subsequent tourism resource matching and route optimization, thereby significantly improving the overall intelligence level and personalized recommendation effect of tourism guide generation.

[0018] Meanwhile, in the construction of the multi-objective optimization function for tourism routes, nodes in the tourism routes are controlled based on semantic similarity, favoring nodes with higher semantic similarity to be added to the routes. This effectively improves the suitability of the generated tourism routes to users' personalized needs, avoiding the "mechanical routes" caused by traditional methods that rely solely on distance or sequence planning. By incorporating tourism time costs into the optimization objective, the transportation modes, transfer times, and visit times between different nodes are quantitatively calculated, thereby avoiding invalid paths, reducing unnecessary traffic redundancy, and improving users' time utilization. Budget control is achieved through cost constraints, and a "budget overrun penalty" is used to penalize solutions that exceed the budget, thus maximizing the tourism experience while avoiding overspending and ensuring the actual feasibility of the solution. The multi-objective optimization function for tourism routes also introduces penalty terms for constraint violations, transforming constraints such as node access limits into quantified penalty points to ensure that the optimization results meet real-world constraints and avoid generating unexecutable itineraries. Overall, the multi-objective optimization function for tourism routes, through the reasonable design of weighting factors and penalty mechanisms, achieves a unity of maximizing tourism value, optimizing itinerary efficiency, and controlling budget constraints, significantly improving the scientific nature, robustness, and user satisfaction of tourism route planning. Attached Figure Description

[0019] Figure 1This is a flowchart illustrating a method for generating travel itinerary plans based on artificial intelligence, provided in an embodiment of the present invention. Figure 2 This is a flowchart illustrating the complete travel guide generation process according to an embodiment of the present invention.

[0020] The realization of the objective, functional features and advantages of the present invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation

[0021] The realization of the objectives, functional characteristics, and advantages of this invention will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.

[0022] This invention provides a method and system for generating travel itinerary plans based on artificial intelligence. The executing entity of this AI-based travel itinerary planning method includes, but is not limited to, at least one of the following electronic devices that can be configured to execute the method provided in this invention: a server, a terminal, etc. In other words, the AI-based travel itinerary planning method can be executed by software or hardware installed on a terminal device or a server device, and the software can be a blockchain platform. The server includes, but is not limited to, a single server, a server cluster, a cloud server, or a cloud server cluster.

[0023] Reference Figure 1 as well as Figure 2 As shown, Embodiment 1 of the present invention is as follows: A method for generating travel itinerary plans based on artificial intelligence includes the following steps: S1: Obtain users' travel needs and use an entity-constrained semantic extraction model to extract travel semantic features from the travel needs.

[0024] A semantic extraction model based on entity constraints is used to extract tourism semantic features from tourism demand, including: Users input their travel needs through clients (APP, web), and the semantic extraction model based on entity constraints is used to extract the semantic features of travel needs. The entity-constraint-based semantic extraction model includes an input layer, an encoding layer, an entity recognition layer, a semantic constraint layer, and a semantic feature extraction layer. The input layer is used to receive travel requests and perform word segmentation on the travel requests, dividing them into several travel request fields. The encoding layer uses a pre-trained language model (such as the BERT model) to perform contextual encoding on the tourism demand field, thereby obtaining the word vectors corresponding to the tourism demand field; The entity recognition layer adopts a BiLSTM-CRF structure to identify the bidirectional hidden state of word vectors and the corresponding entities. The bidirectional hidden state of word vectors is the concatenation result of the forward hidden state and the backward hidden state of word vectors captured by the two LSTM structures of BiLSTM. The entities include tourist destination entities, tourist time entities, budget range entities, number of travelers entities, travel mode entities, interest preference entities, accommodation preference entities, dietary requirements entities, and special needs entities. Specifically, the BiLSTM-CRF structure includes a BiLSTM layer and a CRF layer. The BiLSTM layer is used to perform forward and backward scanning on each word vector to obtain the bidirectional hidden state of each word vector. The CRF layer is used to map the bidirectional hidden state of each word vector to the probability score of each entity. The higher the probability score of an entity, the higher the probability that the word vector is that entity. The Viterbi algorithm is used to obtain the entity recognition result of each word vector while ensuring the continuity of entities (for example, the entity of travel time is generally not followed by the entity of food requirements, and the entities of travel location and travel time generally appear consecutively). The semantic constraint layer sets entities for which no word vectors were identified to be unrestricted based on the entity recognition results; Specifically, for entities without restrictions, the word vectors and bidirectional hidden states of the entity are completed; The semantic feature extraction layer is used to extract the tourism demand field corresponding to the word vectors of entities such as tourism destination, tourism time, budget range, number of travelers, and mode of travel, and concatenate them as basic tourism features. It also extracts the bidirectional hidden state of the word vectors of entities such as interest preference, accommodation preference, dietary requirements, and special needs, and concatenates them as extended tourism features. Finally, the extracted basic tourism features and extended tourism features are concatenated as tourism semantic features. As a preferred embodiment of the present invention, for word vectors identified as travel time entity, budget range entity and number of travelers entity, firstly, based on the content of the travel demand field of the word vector, the total number of travelers is identified as the travel demand field corresponding to the number of travelers entity, and the budget range entity is converted into the daily average budget based on the total number of travelers and travel duration, as the travel demand field corresponding to the budget range entity. Specifically, the tourism demand field under the tourism destination entity can be Beijing, Yunnan, Shanghai, etc.; the tourism demand field under the tourism time entity can be October 1st to 8th, 2025; the tourism demand field under the budget range entity can be 5,000 yuan / person or a total budget of 10,000 yuan; the tourism demand field under the mode of travel entity can be self-driving, public transportation, etc.; the tourism demand field under the interest preference entity can be natural landscapes, history and culture, food and shopping, outdoor adventure, family activities, etc.; the tourism demand field under the accommodation preference entity can be high-end hotels, budget hotels, homestays, and convenient transportation; the tourism demand field under the dietary requirements entity can be vegetarian food, local specialties, etc.; and the tourism demand field under the special needs entity can be barrier-free facilities, elderly and child-friendly facilities, and pet-friendly facilities. As a specific embodiment of the present invention, regarding travel needs: I plan to travel to Beijing with my spouse from October 10th to 15th, 2025, with a budget of 5,000 yuan per person. I prefer historical culture and natural landscapes, and hope to stay in a four-star hotel in the city center. We will travel by car. The travel needs field under the travel destination entity is Beijing, the travel needs field under the travel time entity is October 10th to 15th, 2025, the travel needs field under the budget range entity is 5,000 yuan per person, the travel needs field under the number of travelers entity is "me" and "my spouse", and this travel needs field is converted to 2 people, the travel needs field under the mode of travel entity is "self-driving", the travel needs field under the interest preference entity is "historical culture and natural landscapes", and the travel needs field under the accommodation preference entity is "four-star hotel in the city center".

[0025] S2: Construct a tourism resource database and extract the tourism resource features of each group of tourism resources. Use semantic similarity matching to match the tourism semantic features with the tourism resource features, and select the tourism resources that are successfully matched.

[0026] Construct a tourism resource database and extract the tourism resource characteristics of each group of tourism resources, including: The tourism resource database contains multiple groups of tourism resources, including tourist attractions, local cuisine, and hotels. Each group of tourism resources includes basic information and type information. The basic information includes location (specific to the city), type of tourism resource, opening hours, and average price per person. The type information for tourist attractions includes recommended visit duration, attraction type (e.g., historical and cultural, natural landscape, food, shopping, entertainment, family-friendly, etc.), and interest tags (e.g., royal palaces, world cultural heritage sites, museums, etc.). The type information for local cuisine includes restaurant type (e.g., Chinese, Western, fast food, hot pot, barbecue, vegetarian, etc.), main cuisine, and interest tags (e.g., family-friendly, business banquets, popular spots, nearby attractions, etc.). The type information for hotels includes accommodation type tags (e.g., high-end hotels, budget hotels, guesthouses, boutique inns, etc.), star rating, and interest tags (e.g., family-friendly, business-friendly, near scenic spots, etc.). The basic information of tourism resources is concatenated to form a basic information vector of tourism resources. The type information is then transformed into a word vector to obtain a type information vector of tourism resources. The basic information vector and the type information vector are concatenated to form the tourism resource features of tourism resources.

[0027] It should be noted that the type information of tourism resources is encoded using the encoding layer in the entity-constrained semantic extraction model to obtain the word vector of type information. The word vectors of all type information are then concatenated to form the type information vector of tourism resources.

[0028] Semantic similarity matching is used to match tourism semantic features with tourism resource features, and successfully matched tourism resources are selected, including: The semantic similarity matching formula is:

[0029] ; ; ; in, The semantic feature of tourism F and the tourism resource features of the nth group of tourism resources are represented. The semantic similarity between them, where N represents the number of groups of tourism resources in the tourism resource database. Representing the semantic features of tourism and the features of tourism resources Positional similarity between them Representing the semantic features of tourism and the features of tourism resources Temporal similarity between them Representing the semantic features of tourism and the features of tourism resources Price similarity between them Representing the semantic features of tourism and the features of tourism resources Similarity of interests between them This represents the interest-price ratio factor (a scalar between 0 and 1, for example, set to 0.5). This represents the tourism demand field corresponding to the tourism destination entity in the tourism semantic feature F. Indicate the characteristics of tourism resources The location in Indicate the characteristics of tourism resources Opening hours This represents the tourism demand field corresponding to the tourism time entity in the tourism semantic feature F. This indicates that the nth group of tourism resources is open within the time frame of the tourism time entity in tourism demand. If , it means that the location of the nth group of tourism resources is consistent with the actual tourism location; Indicate the characteristics of tourism resources The average price per person in the middle, This represents the tourism demand field corresponding to the budget range entity in the tourism semantic feature F. This represents the type of tourism resource corresponding to the nth group of tourism resource characteristics. Indicates the type of tourism resources The price-to-consumption ratios (e.g., setting the price-to-consumption ratios for tourist attractions, local cuisine, and hotel accommodations at 0.4, 0.2, and 0.4 respectively) Indicates the types of tourism resources that can be used. Average daily budget per person This indicates a reward slope that prioritizes lower prices, and is used when the average daily budget per person is not lower than the average price per person. This indicates the degree of over-budget depreciation, and is used when the average price per person is higher than the average daily budget per person. Represents an exponential function with the natural constant as its base; The calculation method is based on tourism resource characteristics. Cosine similarity between the type information vector and the tourism extended features in the tourism semantic feature F; Optionally, the cosine similarity between the bidirectional hidden state in the type information vector and any word vector in the tourism extended features is calculated, and the maximum cosine similarity is selected as the similarity between the bidirectional hidden state in the type information vector and the tourism extended features. The mean similarity between all bidirectional hidden states in the type information vector and the tourism extended features is calculated and used as the tourism resource feature. The cosine similarity between the type information vector and the tourism extended features in the tourism semantic feature F avoids the problem that the two cannot be directly calculated due to the inconsistency in length between the type information vector and the tourism extended features. The higher the cosine similarity between the bidirectional hidden state and the word vector in the tourism extended features, the higher the matching degree between tourism resources and the interest preference entity, accommodation preference entity, dietary requirement entity and special need entity in tourism demand. It should be noted that price similarity is modeled using a piecewise function: when the average price per person does not exceed the budget, a linear reward mechanism emphasizes the benefit of the cheaper option, allowing candidate tourism resources to further optimize their cost-effectiveness while meeting the basic budget; when the average price per person exceeds the budget, an exponential penalty factor combining the degree of over-budget attenuation is introduced to achieve non-linear rapid attenuation of the over-budget portion, thereby effectively suppressing unreasonable recommendations and preventing overpriced tourism resources from affecting the overall travel plan. Simultaneously, this invention constructs type information vectors containing three categories of resources: tourist attractions, restaurants, and hotels. Combined with semantic extension features of interest preference entities, accommodation preference entities, dietary requirements entities, and special needs entities, the bidirectional hidden states of word vectors are extracted and concatenated using BiLSTM-CRF to construct the user's extended tourism features. Based on this, cosine similarity is used to calculate the matching degree between resource type information and user extended features, achieving accurate alignment of fine-grained attributes (such as recommended visit duration for attractions, main cuisine of restaurants, hotel comfort and interest tags) in different resource categories. This semantic similarity matching method can not only ensure strict control of user budget, but also provide a higher personalized recommendation effect at the interest matching level. The resulting travel guide is significantly better than existing technologies in terms of rationality, practicality and user satisfaction. Based on the travel demand field corresponding to the travel time entity, the user's travel duration (Len, in days) is calculated, and the number of alternative travel resources for different types of travel resources is also calculated. Specifically, the number of alternative travel resources for tourist attractions, local cuisine, and hotels are 3Len, 4Len, and 4Len, respectively. , Indicates rounding up; Select the 3Len tourism resources with the highest semantic similarity that are tourism attractions from the tourism resource database; Four tourism resources with the highest semantic similarity and the type of local cuisine were selected from the tourism resource database. From the tourism resource database, select tourism resources that are hotels and have the highest semantic similarity. One tourism resource.

[0030] S3: Using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted graph of tourism resources is constructed. Based on the weighted graph of tourism resources, a multi-objective optimization function for tourism routes is constructed.

[0031] By using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted tourism resource graph is constructed, including: The tourism resource weighted map takes the following form: ; Wherein, G represents the weighted graph of tourism resources, E represents the set of nodes, and V represents the set of edge weights between nodes. The transportation information between tourism resources is the travel time between tourism resources based on the tourism demand field corresponding to the travel mode entity in tourism demand.

[0032] Specifically, if the tourism demand field corresponding to the travel mode entity is not identified, the tourism demand field corresponding to the travel mode entity is assumed to be public transportation; the travel time between tourism resources under the corresponding travel mode entity is generated by connecting to navigation software (such as Gaode Map).

[0033] Based on the weighted graph of tourism resources, a multi-objective optimization function for tourism routes is constructed, including: ; ; ; in, This represents a multi-objective optimization function for a tourism route. The multi-objective function takes the tourism route as input and outputs the value of the multi-objective optimization function that maximizes the tourism route. This represents a travel route, which consists of a sequence of nodes visited each day. E represents the set of nodes in the weighted graph of tourism resources. , where e represents any node in node E. Indicates travel routes A binary variable indicating whether node e is visited at position q on day d. , A value of 0 indicates a tour route. Node e is not visited at position q on day d. 1 represents a tourist route Node e is visited at position q on day d, meaning node e is part of the travel route. The q-th node in the sequence of nodes visited on day d. This represents the maximum number of nodes visited on day d. Indicates the semantic similarity of node e; In one embodiment of the present invention, the initial maximum number of nodes accessed per day is set to 4, which can be adjusted in real time based on user feedback. Indicates travel routes The over-budget items were used to quantify the tour routes. The cost was higher than the budgeted value. Indicates travel routes The higher the time cost, the more unreasonable the transportation itinerary of the travel route. We encourage the generation of travel routes with shorter total travel time, smoother traffic, and more reasonable schedules. This represents the budget control factor (set to 0.3). This represents the time control factor (set to 0.4). Specifically, Indicates travel routes Does there exist a binary variable where the q-th node visited on day d is 'a' and the (q+1)-th node is 'b'? , Indicates travel routes There exists a node q visited on day d, which is named 'a', and a node b (the (q+1)th node) that is also visited on day d. Indicates travel routes There is no node a visited on day d that is node q and node b visited on day q+1. Let represent the edge weight from node a to node b. This represents the recommended visit duration for node a. If the tourism resource type for node a is local cuisine, then set... It takes 1 hour; This represents the total budget per capita. This represents the average price per person at node e. Indicates selection The minimum value in the range; the total budget per person is the daily budget per person multiplied by the length of travel Len; Indicates travel routes Violation of constraints, tourist routes The more constraints are violated, the larger the value of the violated constraint term; optionally, the value of the violated constraint term is the travel route. The number of constraints violated; The constraints of the multi-objective optimization function for the tourism route include: The number of nodes in the tourism route for tourist attractions, local cuisine, and hotels are 2 Len, 3 Len, and 3 Len respectively. ; The daily travel time shall not exceed 12 hours, and the travel time includes the sum of the time spent at each node and the sum of the travel time. The tourism resource type of the last access node at the end of each day is a hotel. The first access node at the beginning of each day is the last access node of the previous day by default, but it is not reflected in the travel route. The same tourist attractions and local delicacies will only appear once in the travel route.

[0034] S4: Use a genetic algorithm to solve the multi-objective optimization function of the travel route to obtain the optimal travel route, and call a natural language generation model to convert the optimal travel route into a complete travel guide.

[0035] A genetic algorithm is used to solve the multi-objective optimization function of the tourism route to obtain the optimal tourism route, including: Initialize and generate R groups of individuals, each group consisting of a sequence of nodes visited each day, and treat each group of individuals as a travel route; Each group of individuals is used as the input value of the multi-objective optimization function of the tourism route. The value of the multi-objective optimization function of the tourism route is used as the fitness of the individual. The R groups of individuals are iterated with the goal of selecting the individual with the highest fitness until the preset maximum number of iterations Max (set to 50) is reached. The fitness of each group of individuals after reaching the preset maximum number of iterations is calculated, and the individual with the highest fitness is selected as the optimal tourism route. The process for each iteration includes: retaining the M individuals with the highest fitness that do not participate in the iteration; calculating the roulette probability of the individuals not retained based on their fitness; selecting an individual from the unretained individuals as a parent based on the roulette probability; performing a mutation operation on the selected parent to generate new offspring; and replacing the individual with the lowest fitness among the unretained individuals with the offspring generated by the parent. Optionally, R is set to 20 and M to 5. Optionally, the formula for calculating the roulette wheel probability is: fitness / sum of the fitness of all remaining unretained individuals; As an embodiment of the present invention, the mutation operation is as follows: Randomly select two nodes from non-hotel accommodations on different days to exchange; Randomly select two non-hotel nodes that are visited consecutively on the same day and swap their node order.

[0036] It should be noted that the designed mutation operations, including cross-day node swapping and intra-day consecutive node order adjustment, effectively prevent individuals from getting trapped in local optima, thus improving the feasibility and rationality of the route. For example, cross-day swapping can break the fixed itinerary distribution and balance the number of attractions on different days; intra-day node order adjustment optimizes the access path and reduces redundant movement.

[0037] The optimal travel route is converted into a complete travel guide using a natural language generation model, including: The optimal travel route is input into a natural language generation model. Based on the daily node sequence and the corresponding tourism resources of each node in the optimal travel route, the natural language generation model generates a complete travel guide text, which includes daily itinerary, transportation instructions, accommodation arrangements, dining information, attraction introductions, and personalized tips.

[0038] The natural language generation model is a large-scale pre-trained language model, including GPT, DeepSeek, or other language models with contextual semantic generation capabilities.

[0039] In one embodiment of the present invention, the optimal travel route is as follows: Day 1: Forbidden City, Beijing → Wangfujing Food Street → Beijing Hotel Day 2: Summer Palace → Haidilao Hot Pot (Wudaokou Branch) → Beijing International Youth Hostel Day 3: Temple of Heaven Park → Nanluoguxiang → Beijing South Railway Station (return trip) When calling a natural language generation model (such as GPT or DeepSeek), the input prompt includes: Tourism resources corresponding to nodes: Each group of tourism resources includes basic information and type information. The basic information includes location, type of tourism resource, opening hours, and average price per person. The type of tourism resource is tourist attraction, which includes recommended visit duration, attraction type, and interest tags. The type of tourism resource is local cuisine, which includes restaurant type, main cuisine, and interest tags. The type of tourism resource is accommodation, which includes accommodation type tags, star rating, and interest tags. User demand constraints: tourism demand; Output format requirements: A complete travel guide must be generated, including daily itinerary, transportation recommendations, time management suggestions, accommodation tips, food recommendations, and background information on attractions. The generated complete travel guide will take the following form: Day 1 Itinerary: At 9:00 AM, depart for the Forbidden City in Beijing. The visit is expected to last 3 hours; a visit to the Central Axis and the Clock Museum is recommended. Lunch can be enjoyed at Wangfujing Food Street, sampling Beijing snacks (approximately 80 RMB per person). Overnight stay at the Beijing Hotel, a conveniently located hotel with easy access to transportation. Day 2 Itinerary: In the morning, visit the Summer Palace (8:00-17:00), estimated visit time 4 hours. Taking Metro Line 4 is recommended. Lunch will be at Haidilao Hot Pot (Wudaokou branch), a set meal suitable for multiple people is recommended. Overnight stay at Beijing International Youth Hostel, economical and suitable for young travelers. Day 3 Itinerary: In the morning, visit the Temple of Heaven Park, including the Hall of Prayer for Good Harvests. After lunch, you can visit Nanluoguxiang to experience the hutong culture and unique shops. After the tour, proceed to Beijing South Railway Station; it is recommended to allow 1 hour for travel time. The complete travel guide is presented in document form or mobile itinerary card form, which users can use directly. Users can also adjust their travel needs based on the presented complete travel guide and regenerate a complete travel guide based on their travel needs.

[0040] Reference Figure 2 The diagram shown is a complete flowchart for generating travel guides according to an embodiment of the present invention.

[0041] Example 2: An AI-based travel itinerary planning and generation system includes a feature extraction device, a travel route planning module, and a travel itinerary generation device. The feature extraction device is used to obtain users' travel needs, extract travel semantic features from travel needs using an entity-constrained semantic extraction model, construct a travel resource database, extract travel resource features for each group of travel resources, and use semantic similarity matching to match travel semantic features with travel resource features, and select successfully matched travel resources. The tourism route planning module is used to construct a tourism resource weighted graph by taking the selected tourism resources as nodes and the traffic information between the selected tourism resources as edge weights. Based on the tourism resource weighted graph, a multi-objective optimization function for the tourism route is constructed. The genetic algorithm is used to solve the multi-objective optimization function for the tourism route to obtain the optimal tourism route. The travel guide generation device is used to call a natural language generation model to convert the optimal travel route into a complete travel guide. This achieves a travel itinerary planning generation method based on artificial intelligence, as described in Example 1.

[0042] It should be understood that the embodiments described are for illustrative purposes only and are not limited to this structure in the scope of the patent application.

[0043] It should be noted that the sequence numbers of the above embodiments of the present invention are merely for descriptive purposes and do not represent the superiority or inferiority of the embodiments. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, apparatus, article, or method. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, apparatus, article, or method that includes that element.

[0044] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of the present invention.

[0045] The above are merely preferred embodiments of the present invention and do not limit the scope of the patent. Any equivalent structural or procedural transformations made based on the description and drawings of the present invention, or direct or indirect applications in other related technical fields, are similarly included within the scope of patent protection of the present invention.

Claims

1. A method for generating travel itinerary plans based on artificial intelligence, characterized in that, The method includes: S1: Obtain users' travel needs and use an entity-constrained semantic extraction model to extract travel semantic features from the travel needs; S2: Construct a tourism resource database and extract the tourism resource features of each group of tourism resources. Use semantic similarity matching to match the tourism semantic features with the tourism resource features, and select the tourism resources that are successfully matched. S3: Using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted graph of tourism resources is constructed. Based on the weighted graph of tourism resources, a multi-objective optimization function for tourism routes is constructed. S4: Use a genetic algorithm to solve the multi-objective optimization function of the travel route to obtain the optimal travel route, and call a natural language generation model to convert the optimal travel route into a complete travel guide.

2. The method for generating travel itinerary plans based on artificial intelligence as described in claim 1, characterized in that, A semantic extraction model based on entity constraints is used to extract tourism semantic features from tourism demand, including: Users input their travel needs through the client, and the semantic features of travel needs are extracted using a semantic extraction model based on entity constraints. The entity-constraint-based semantic extraction model includes an input layer, an encoding layer, an entity recognition layer, a semantic constraint layer, and a semantic feature extraction layer. The input layer is used to receive travel requests and perform word segmentation on the travel requests, dividing them into several travel request fields. The encoding layer uses a pre-trained language model to perform contextual encoding on the tourism demand field, thereby obtaining the word vectors corresponding to the tourism demand field. The entity recognition layer adopts a BiLSTM-CRF structure to identify the bidirectional hidden state of word vectors and the corresponding entities. The bidirectional hidden state of word vectors is the concatenation result of the forward hidden state and the backward hidden state of word vectors captured by the two LSTM structures of BiLSTM. The entities include tourist destination entities, tourist time entities, budget range entities, number of travelers entities, travel mode entities, interest preference entities, accommodation preference entities, dietary requirements entities, and special needs entities. The semantic constraint layer sets entities for which no word vectors were identified to be unrestricted based on the entity recognition results; The semantic feature extraction layer extracts the tourism demand fields corresponding to the word vectors of entities such as tourist destination, tourist time, budget range, number of travelers, and mode of travel, and concatenates them as basic tourism features. It also extracts the bidirectional hidden states of the word vectors of entities such as interest preference, accommodation preference, dietary requirements, and special needs, and concatenates them as extended tourism features. Finally, it concatenates the extracted basic tourism features and extended tourism features as tourism semantic features.

3. The method for generating travel itinerary plans based on artificial intelligence as described in claim 1, characterized in that, Construct a tourism resource database and extract the tourism resource characteristics of each group of tourism resources, including: The tourism resource database contains multiple sets of tourism resources, including tourist attractions, local cuisine, and hotels. Each set of tourism resources includes basic information and type information. The basic information includes location, type of tourism resource, opening hours, and average price per person. The type information for tourist attractions includes recommended visit duration, attraction type, and interest tags. The type information for local cuisine includes restaurant type, main cuisine, and interest tags. The type information for hotels includes accommodation type tags, star rating, and interest tags. The basic information of tourism resources is concatenated to form a basic information vector of tourism resources. The type information is then transformed into a word vector to obtain a type information vector of tourism resources. The basic information vector and the type information vector are concatenated to form the tourism resource features of tourism resources.

4. The method for generating travel itinerary plans based on artificial intelligence as described in claim 3, characterized in that, Semantic similarity matching is used to match tourism semantic features with tourism resource features, and successfully matched tourism resources are selected, including: The semantic similarity matching formula is: ; ; ; ; in, The semantic feature of tourism F and the tourism resource features of the nth group of tourism resources are represented. The semantic similarity between them, where N represents the number of groups of tourism resources in the tourism resource database. Representing the semantic features of tourism and the features of tourism resources Positional similarity between them Representing the semantic features of tourism and the features of tourism resources Temporal similarity between them Representing the semantic features of tourism and the features of tourism resources Price similarity between them Representing the semantic features of tourism and the features of tourism resources Similarity of interests between them Indicates interest-price ratio factor; This represents the tourism demand field corresponding to the tourism destination entity in the tourism semantic feature F. Indicate the characteristics of tourism resources The location in Indicate the characteristics of tourism resources Opening hours This represents the tourism demand field corresponding to the tourism time entity in the tourism semantic feature F. This indicates that the nth group of tourism resources is open within the time frame of the tourism time entity in tourism demand. If , it means that the location of the nth group of tourism resources is consistent with the actual tourism location; Indicate the characteristics of tourism resources The average price per person in the middle, This represents the tourism demand field corresponding to the budget range entity in the tourism semantic feature F. This represents the type of tourism resource corresponding to the nth group of tourism resource characteristics. Indicates the type of tourism resources Price consumption ratio Indicates the types of tourism resources that can be used. Average daily budget per person This indicates a reward slope that prioritizes lower prices, and is used when the average daily budget per person is not lower than the average price per person. This indicates the degree of over-budget depreciation, and is used when the average price per person is higher than the average daily budget per person. Represents an exponential function with the natural constant as its base; The calculation method is based on tourism resource characteristics. Cosine similarity between the type information vector and the tourism extended features in the tourism semantic feature F; Based on the travel demand field corresponding to the travel time entity, the user's travel duration (Len, in days) is calculated, and the number of alternative travel resources for different types of travel resources is also calculated. Specifically, the number of alternative travel resources for tourist attractions, local cuisine, and hotels are 3Len, 4Len, and 4Len, respectively. , Indicates rounding up; Select the 3Len tourism resources with the highest semantic similarity that are tourism attractions from the tourism resource database; Four tourism resources with the highest semantic similarity and the type of local cuisine were selected from the tourism resource database. From the tourism resource database, select tourism resources that are hotels and have the highest semantic similarity. One tourism resource.

5. The method for generating travel itinerary plans based on artificial intelligence as described in claim 4, characterized in that, By using the selected tourism resources as nodes and the transportation information between the selected tourism resources as edge weights, a weighted tourism resource graph is constructed, including: The tourism resource weighted map takes the following form: ; Wherein, G represents the weighted graph of tourism resources, E represents the set of nodes, and V represents the set of edge weights between nodes. The transportation information between tourism resources is the travel time between tourism resources based on the tourism demand field corresponding to the travel mode entity in tourism demand.

6. The method for generating travel itinerary plans based on artificial intelligence as described in claim 5, characterized in that, Based on the weighted graph of tourism resources, a multi-objective optimization function for tourism routes is constructed, including: ; in, This represents a multi-objective optimization function for a tourism route. The multi-objective function takes the tourism route as input and outputs the value of the multi-objective optimization function that maximizes the tourism route. This represents a travel route, which consists of a sequence of nodes visited each day. E represents the set of nodes in the weighted graph of tourism resources. , where e represents any node in node E. Indicates travel route A binary variable indicating whether node e is visited at position q on day d. , A value of 0 indicates a tour route. Node e is not visited at position q on day d. 1 represents a tourist route Node e is visited at position q on day d, meaning node e is part of the travel route. The q-th node in the sequence of nodes visited on day d. This represents the maximum number of nodes visited on day d. Indicates the semantic similarity of node e; Indicates travel route Items exceeding the budget, Indicates travel route Time cost item This represents the budget control coefficient. Indicates the time control factor; Indicates travel route Violation of constraints, tourist routes The more constraints are violated, the larger the value of the violated constraint. The constraints of the multi-objective optimization function for the tourism route include: The number of nodes in the tourism route for tourist attractions, local cuisine, and hotels are 2 Len, 3 Len, and 3 Len respectively. ; The daily travel time shall not exceed 12 hours, and the travel time includes the sum of the time spent at each node and the sum of the travel time. The tourism resource type of the last access node at the end of each day is a hotel. The first access node at the beginning of each day is the last access node of the previous day by default, but it is not reflected in the travel route. The same tourist attractions and local delicacies will only appear once in the travel route.

7. The method for generating travel itinerary plans based on artificial intelligence as described in claim 6, characterized in that, A genetic algorithm is used to solve the multi-objective optimization function of the tourism route to obtain the optimal tourism route, including: Initialize and generate R groups of individuals, each group consisting of a sequence of nodes visited each day, and treat each group of individuals as a travel route; Each group of individuals is used as the input value of the multi-objective optimization function of the tourism route. The value of the multi-objective optimization function of the tourism route is used as the fitness of the individual. The R groups of individuals are iterated with the goal of selecting the individual with the highest fitness until the preset maximum number of iterations Max is reached. The fitness of each group of individuals after reaching the preset maximum number of iterations is calculated, and the individual with the highest fitness is selected as the optimal tourism route. The process for each iteration includes: retaining the M individuals with the highest fitness that do not participate in the iteration; calculating the roulette probability of the individuals not retained based on their fitness; selecting individuals from the individuals not retained as parents based on the roulette probability; performing a mutation operation on the selected parents to generate new offspring; and replacing the individual with the lowest fitness among the individuals not retained with the offspring generated by the parents.

8. The method for generating travel itinerary plans based on artificial intelligence as described in claim 7, characterized in that, The optimal travel route is converted into a complete travel guide using a natural language generation model, including: The optimal travel route is input into a natural language generation model. Based on the daily node sequence and the corresponding tourism resources of each node in the optimal travel route, the natural language generation model generates a complete travel guide text, which includes daily itinerary, transportation instructions, accommodation arrangements, dining information, attraction introductions, and personalized tips.

9. A travel itinerary planning and generation system based on artificial intelligence, characterized in that, The AI-based travel itinerary planning and generation system includes a feature extraction device, a travel route planning module, and a travel itinerary generation device. The feature extraction device is used to obtain users' travel needs, extract travel semantic features from travel needs using an entity-constrained semantic extraction model, construct a travel resource database, extract travel resource features for each group of travel resources, and use semantic similarity matching to match travel semantic features with travel resource features, and select successfully matched travel resources. The tourism route planning module is used to construct a tourism resource weighted graph by taking the selected tourism resources as nodes and the traffic information between the selected tourism resources as edge weights. Based on the tourism resource weighted graph, a multi-objective optimization function for the tourism route is constructed. The genetic algorithm is used to solve the multi-objective optimization function for the tourism route to obtain the optimal tourism route. The travel guide generation device is used to call a natural language generation model to convert the optimal travel route into a complete travel guide. To achieve the method for generating travel itinerary plans based on artificial intelligence as described in any one of claims 1-8.