A cross-border text travel route dynamic programming method and system

CN122887046APending Publication Date: 2026-10-09GUANGDONG COMM POLYTECHNIC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611031952.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-13
Publication Date
2026-10-09

AI Technical Summary

Technical Problem

[0009]针对上述不足,本发明提供了一种跨境文旅行程动态规划方法及系统,通过构建跨境专属约束模型与约束图路径规划算法,结合多语言语义解析、结构化文旅知识库、多源实时数据采集与分级动态重规划机制及个性化评分体系,解决传统跨境行程规划可行性不足、缺乏动态适配的问题,显著提升行程可执行性、容错能力与跨境用户出行体验

Benefits of technology

1、通过构建涵盖通关时效、交通换乘、支付方式、语言服务等跨境专属维度的约束规则库,融合多语言语义解析模块与结构化跨境文旅知识库,采用约束图剪枝与改进A搜索算法完成约束满足路径求解,实现适配跨境场景的文旅行程自动化生成,有效解决传统路线推荐系统未纳入跨境特殊约束导致方案可行性不足、用户需跨多平台反复核验信息的问题,打通景点、交通、通关、商家等多源数据壁垒,显著提升跨境行程规划的完整性、可执行性与一站式服务能力。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122887046A_ABST
    Figure CN122887046A_ABST
Patent Text Reader

Abstract

The application discloses a cross-border travel route dynamic planning method and system, and relates to the technical field of data processing. The system comprises a multilingual semantic analysis module, a user portrait construction module, a cross-border scene constraint modeling module, a constraint graph path planning module, a candidate route comprehensive scoring module and a route dynamic re-planning module. The multilingual semantic analysis module is used to obtain cross-border travel demand information of a user, identify an input language type, complete entity recognition, intent recognition and slot filling. The application solves the problems of insufficient feasibility and lack of dynamic adaptation of traditional cross-border route planning by constructing a cross-border exclusive constraint model and a constraint graph path planning algorithm, combining multilingual semantic analysis, a structured travel knowledge base, multi-source real-time data acquisition and a hierarchical dynamic re-planning mechanism and a personalized scoring system, and significantly improves the executable of the route, fault tolerance and cross-border user travel experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of data processing technology, and in particular to a method and system for dynamic planning of cross-border cultural and tourism itineraries. Background Technology

[0002] With the rapid development of cross-border independent travel and regional cultural tourism integration services, cross-border tourists need to obtain multi-dimensional information during the trip planning process, including sightseeing, customs clearance and transportation, accommodation and dining, payment methods, language guidance, and risk warnings. Currently, tourism platforms, map navigation, translation tools, content communities, and other applications operate independently, with significant differences in data structures and service objectives, making it difficult to form a unified dynamic cross-border trip planning capability. This has exposed many technical limitations in practical applications.

[0003] Specifically, conventional travel route recommendation systems rely on attraction popularity, user interests and spatial distance as core recommendation criteria, without fully considering the specific constraints of cross-border scenarios such as customs clearance time, cross-border transportation transfers, payment method compatibility, and language service coverage. This results in low feasibility of the generated itineraries in actual implementation, and users often need to repeatedly check and verify information across multiple platforms.

[0004] Existing map navigation applications can only solve the problem of route planning between two points. They lack the ability to comprehensively handle issues such as the order of sightseeing, the connection of cultural tour content, budget control, and the verification of opening time conflicts. They cannot directly generate complete cultural tour itineraries and still require users to manually perform a lot of secondary integration and adjustment work.

[0005] Translation tools and intelligent question-answering systems currently only complete basic language conversion functions. They fail to uniformly map entities such as place names, scenic spot names, business names, and cultural and tourism terms in multilingual environments to a structured knowledge base, resulting in issues such as inconsistent semantic understanding and entity recognition bias. The recognition results are difficult to directly use for subsequent route planning algorithm calculations.

[0006] Travel guide information on content community platforms is highly fragmented, with inconsistent update times, and is mainly presented in unstructured text format. It lacks standardized data interfaces that can be directly called and parsed by algorithms, making it impossible to support technologies such as automatic route generation, intelligent scoring of candidate itineraries, and real-time dynamic updates.

[0007] Traditional itinerary recommendation systems lack real-time feedback and dynamic replanning mechanisms. When users experience route deviations, overstaying, traffic delays, or changes in the operating status of attractions, they cannot promptly generate new itinerary plans that are adapted and adjusted, leading to itinerary interruptions or a decline in the user experience.

[0008] The aforementioned issues collectively constrain the level of intelligence in cross-border cultural and tourism services and the user travel experience, thus necessitating a cross-border cultural and tourism itinerary planning solution that can meet the special constraints of cross-border scenarios and support dynamic planning adjustments. Summary of the Invention

[0009] To address the aforementioned shortcomings, this invention provides a method and system for dynamic planning of cross-border cultural and tourism itineraries. By constructing a cross-border-specific constraint model and constraint graph path planning algorithm, combined with multilingual semantic parsing, a structured cultural and tourism knowledge base, multi-source real-time data collection and a hierarchical dynamic replanning mechanism, and a personalized scoring system, it solves the problems of insufficient feasibility and lack of dynamic adaptation in traditional cross-border itinerary planning, significantly improving itinerary executability, fault tolerance, and the travel experience of cross-border users.

[0010] In a first aspect, the present invention provides a cross-border cultural tourism itinerary dynamic planning system, the system comprising a multilingual semantic parsing module, a cross-border cultural tourism knowledge base module, a user profile construction module, a cross-border scenario constraint modeling module, a constraint graph path planning module, a candidate itinerary comprehensive scoring module, a multilingual itinerary output module, a real-time data acquisition module, and an itinerary dynamic replanning module; The multilingual semantic parsing module is used to obtain information on users' cross-border cultural and tourism needs, identify the input language type, and complete entity recognition, intent recognition, and slot filling. The cross-border cultural and tourism knowledge base module is used to store and manage several types of structured cultural and tourism data; The user profile building module is used to generate user profiles by combining user input information, historical behavior data, real-time location and structured demand tags; The cross-border scenario constraint modeling module is used to construct a cross-border scenario constraint model, calculate the matching degree between user feature vectors and resource feature vectors, and filter to obtain a set of candidate cultural and tourism resources. The constraint graph path planning module is used to construct a cross-border constraint graph based on candidate resources, abstract various cultural and tourism nodes and their connections into nodes and edges of the graph, calculate edge weights and perform constraint pruning to generate candidate itinerary schemes; The candidate itinerary comprehensive scoring module is used to calculate the comprehensive score of the candidate itineraries and sort them according to the score. The multilingual itinerary output module is used to select the itinerary with the highest rating as the recommended option; The real-time data acquisition module is used to continuously collect user feedback information and synchronously acquire real-time status data of traffic, ports, attractions, merchants, and weather. The trip dynamic replanning module recalculates the constraints when the following trigger conditions are met: route deviation, stay timeout, service status change, or user preference modification. It then regenerates and re-evaluates the remaining trip and outputs the updated trip plan.

[0011] Preferably, the multilingual semantic parsing module includes a multilingual input recognition unit, an entity recognition unit, an intent recognition unit, and a slot filling unit; The multilingual input recognition unit automatically identifies the language type of the user input through a language detection algorithm, which adopts a multi-classification model based on n-gram features. The entity recognition unit uses a pre-trained multilingual Transformer model as an encoder and decodes cultural and tourism entity labels through the conditional random field output layer. The intent recognition unit uses a multi-label classification network to map user input to several intent categories; the classification network uses BERT-base-multilingual as a feature extractor and the output layer is a multilayer perceptron. The slot filling unit maps the identified entities to predefined slot structures according to their type; the slot filling adopts a two-layer mechanism that combines rule-based verification and model-based prediction.

[0012] Preferably, the user profile construction module includes a feature extraction unit, a vector representation unit, and a profile update unit; The feature extraction unit extracts explicit features from user input information, including destination preference, travel time, budget range, number of travelers, accommodation preference, transportation preference, and dining preference; it extracts implicit features from historical behavior data, including browsing history, favorites, booking history, review history, and search keywords; and it extracts current location, trip stage, and movement speed from real-time location data. The vector representation unit maps the extracted multi-dimensional features to a unified feature vector space; the user profile is represented by a 128-dimensional feature vector, with each dimension corresponding to the interest preference dimension, budget level dimension, language ability dimension, transportation preference dimension, risk preference dimension, and time preference dimension; the feature vector is generated through a fully connected neural network, which contains 3 hidden layers with dimensions of 256, 128, and 64 respectively, and the activation function is ReLU; The profile update unit dynamically corrects the user profile by combining real-time feedback information; after the user completes the visit to the attraction, it collects the user's stay time, rating, and subsequent search feedback data to update the weight distribution of the interest and preference dimensions; when the user adjusts the budget or preference settings, the profile update process is triggered immediately to ensure that the user profile is consistent with the user's real-time needs.

[0013] Preferably, the cross-border scenario constraint modeling module includes a constraint rule definition unit, a user feature vector calculation unit, a resource feature vector calculation unit, and a matching degree filtering unit; The constraint rule definition unit establishes a constraint rule library specifically for cross-border scenarios, including a time constraint rule sub-library, a budget constraint rule sub-library, a customs clearance constraint rule sub-library, a transportation transfer constraint rule sub-library, an opening time constraint rule sub-library, a language service constraint rule sub-library, and a payment method constraint rule sub-library; each constraint rule is defined in the form of a triple: constraint type, constraint threshold, and constraint priority; The user feature vector calculation unit combines the 128-dimensional feature vector of the user profile with the structured demand label to generate a user demand vector. The user demand vector includes a destination vector, a time window vector, a budget vector, and a preference weight vector. Each component is mapped to a unified semantic space through an independent encoder, which adopts a Transformer architecture. The resource feature vector calculation unit maps various cultural and tourism resources in the knowledge base to the same semantic space as the user demand vector; and generates it using a pre-trained multilingual text encoder. The matching degree filtering unit calculates the cosine similarity between the user demand vector and the resource feature vector, and filters candidate resources with a similarity of not less than a preset threshold to enter the next stage of planning.

[0014] Preferably, the constraint graph path planning module includes a node construction unit, an edge weight calculation unit, a constraint pruning unit, and a path generation unit; The node construction unit maps the selected candidate cultural and tourism resources to nodes in the constraint graph; The edge weight calculation unit calculates the edge weight between adjacent nodes; the edge weight is calculated using a multi-dimensional weighted average, and the formula is as follows: ; In the formula, For nodes To the node The edge weights, For time cost, For transportation costs, For spatial distance, As a risk penalty factor; , , , These are weighting coefficients, ranging from 0 to 1, with the sum of all coefficients being 1; the weighting is dynamically adjusted based on the preference dimensions in the user profile. The constraint pruning unit performs pruning operations on the constraint graph according to the constraint rule base; the pruning strategies include time window pruning, budget limit pruning, opening time pruning, clearance time pruning, and continuity pruning; when the time window of a node is incompatible with the previous node, all incoming edges of the candidate node are pruned; when the cumulative cost exceeds 1.1 times the budget limit, candidate nodes whose cost exceeds the budget are pruned; when the opening time of a node does not match the user's accessible time window, the candidate node is pruned. The path generation unit uses an improved A The search algorithm finds candidate paths that satisfy the constraints in the pruned constraint graph; the heuristic function of the search algorithm comprehensively considers time cost, cost, and risk penalty; when the search space is larger than the standard space, a hierarchical search strategy is adopted, first planning the node sequence at the coarse-grained layer, and then optimizing resource selection at the fine-grained layer.

[0015] Preferably, the candidate itinerary comprehensive scoring module includes a multi-dimensional scoring unit, a weight configuration unit, and a sorting output unit; The multi-dimensional scoring unit scores each candidate itinerary from six dimensions: interest matching, transportation convenience, budget fit, cultural experience, customs clearance convenience, and risk penalty. The interest matching score is obtained by calculating the cosine similarity between the theme tags of each attraction in the itinerary and the user's interest vector. The transportation convenience score is obtained by calculating the average transfer time and number of transfers for each transportation segment in the itinerary. The budget fit score is obtained by calculating the ratio of the total cost of the itinerary to the user's budget. The cultural experience score is obtained by calculating the richness and diversity of cultural guided tour content in the itinerary. The customs clearance convenience score is obtained by calculating the average waiting time for cross-border customs clearance and the rationality of the distribution of customs clearance time slots. The risk penalty score is calculated based on the risk factors at each node of the itinerary. The weight configuration unit dynamically configures the weights of each rating dimension based on the user profile; the weight configuration formula is: ; In the formula, For the first The weights of each rating dimension, The first step in user profiling The preference intensity values ​​of each dimension; The sorting output unit sorts the candidate routes in descending order based on the weighted total score, using the following formula: ; In the formula, For the first The overall score of the candidate itineraries For the first The itinerary is in the first The scores are calculated for each rating dimension; after sorting, the trip with the highest total score is selected as the recommended option, while the top few trips with the highest scores are retained for users to choose from.

[0016] Secondly, the present invention also provides a method for dynamic planning of cross-border cultural and tourism itineraries, characterized in that it implements the dynamic planning system for cross-border cultural and tourism itineraries as described in any one of claims 1-6, the method comprising: During the demand collection phase, information on users' cross-border cultural tourism needs is obtained through the terminal, the input language type is identified, and entity recognition, intent recognition, and slot filling are completed. In the demand structuring stage, cultural and tourism entities such as place names, port names, scenic spot names, and business names identified in different languages ​​are matched and aligned with standard entities in the cross-border cultural and tourism knowledge base to generate unified semantic entities and output structured demand tags. During the user profile building phase, user profiles are generated by combining user input information, historical behavior data, real-time location and structured demand tags, including dimensions such as interest preferences, budget level, language ability, and transportation preferences. During the knowledge base retrieval phase, structured knowledge base data is retrieved based on structured requirement tags and user profiles; In the resource matching stage, a cross-border scenario constraint model is constructed, and the matching degree is calculated by using user feature vectors and resource feature vectors to filter and obtain a set of candidate cultural and tourism resources; During the route planning phase, a cross-border constraint graph is constructed based on candidate resources. Cultural and tourism nodes and their connections are abstracted as nodes and edges of the graph. Edge weights are calculated and constraint pruning is performed to generate candidate itinerary schemes. During the scoring and ranking phase, a comprehensive score is calculated for candidate itineraries based on factors such as interest matching, transportation convenience, budget fit, cultural experience, customs clearance convenience, and risk penalty. The itineraries are then ranked according to their scores. During the trip output phase, the trip with the highest rating is selected as the recommended option; During the real-time monitoring phase, user feedback information is continuously collected, and real-time status data of traffic, ports, attractions, businesses, and weather are obtained simultaneously. During the dynamic replanning phase, when conditions such as route deviation, timeout, service status change, or user preference modification are met, the constraints are recalculated, the remaining itinerary is regenerated and re-scored, and the updated itinerary plan is output.

[0017] Compared with the prior art, the present invention has the following advantages and beneficial effects: 1. By constructing a constraint rule base covering cross-border specific dimensions such as customs clearance timeliness, transportation transfers, payment methods, and language services, and integrating a multilingual semantic parsing module with a structured cross-border cultural tourism knowledge base, constraint graph pruning and improved A The search algorithm solves the constraint satisfaction path and realizes the automatic generation of cultural and tourism itineraries adapted to cross-border scenarios. It effectively solves the problems of insufficient feasibility of solutions caused by the lack of cross-border special constraints in traditional route recommendation systems and the need for users to repeatedly verify information across multiple platforms. It breaks down the data barriers of multiple sources such as attractions, transportation, customs clearance, and merchants, and significantly improves the completeness, feasibility and one-stop service capabilities of cross-border itinerary planning.

[0018] 2. By establishing a multi-source real-time data collection link for user behavior, location tracking, and external environment, a hierarchical dynamic replanning trigger mechanism for itinerary replanning is established. Differentiated strategies such as local adjustment, global replanning, and emergency avoidance are matched for scenarios such as route deviation, stay timeout, and service status changes. This enables adaptive dynamic adjustment throughout the entire itinerary execution cycle, effectively making up for the shortcomings of traditional itinerary systems that lack real-time feedback and emergency adaptability. It can proactively respond to emergencies such as traffic delays, attraction closures, and weather warnings, avoiding itinerary interruptions and significantly improving the fault tolerance of cross-border cultural tourism travel and the user travel experience.

[0019] 3. By establishing a standardized mapping knowledge base for multilingual cultural and tourism entities, and combining multi-dimensional vectorized representation of user profiles with a multi-dimensional comprehensive scoring model for candidate itineraries, the system dynamically configures scoring weights based on user preferences and outputs multilingual adapted structured itinerary solutions. This solves the problems of inconsistent semantic understanding of entities in multilingual environments and the inability of unstructured travel guide data to directly support algorithm calculations. It ensures the accuracy of cross-language entity mapping, achieves personalized and accurate matching of itinerary recommendations, and can flexibly adapt to the needs of cross-border users with different language abilities and interests. Attached Figure Description

[0020] Figure 1 This is a structural diagram of a dynamic programming system for cross-border cultural tourism.

[0021] Figure 2 This is a flowchart illustrating a dynamic programming method for cross-border cultural tourism itineraries. Detailed Implementation

[0022] The technical solution of the present invention will be clearly and completely described below with reference to the embodiments. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of the present invention. It should be noted that relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations.

[0023] Example 1 Please see Figures 1-2 This embodiment uses a typical cross-border tourism scenario of Chinese citizens traveling to Japan as an application scenario to elaborate on a dynamic planning method for cross-border cultural tourism itineraries proposed in this invention. The method is implemented based on a dynamic planning system for cross-border cultural tourism itineraries. The system includes a multilingual semantic parsing module, a cross-border cultural tourism knowledge base module, a user profile construction module, a cross-border scenario constraint modeling module, a constraint graph path planning module, a candidate itinerary comprehensive scoring module, a multilingual itinerary output module, a real-time data acquisition module, and an itinerary dynamic replanning module. The modules work together to complete the intelligent planning and dynamic adaptive adjustment of the entire cross-border itinerary process.

[0024] The multilingual semantic parsing module serves as the demand entry point, used to acquire users' cross-border cultural tourism demand information and complete semantic understanding; it includes a multilingual input recognition unit, an entity recognition unit, an intent recognition unit, and a slot filling unit. The multilingual input recognition unit automatically identifies the language type of user input through a language detection algorithm based on n-gram features, supporting no fewer than 20 commonly used cross-border languages, including Chinese, English, Japanese, Korean, Thai, Vietnamese, and Malay; the language detection model uses a Naive Bayes classifier; when user input contains mixed languages, the dominant language is identified first and the mixed segments are labeled. The entity recognition unit uses a pre-trained multilingual Transformer model as the encoder, with the model parameters set to the base version. It decodes cultural and tourism entity labels through a conditional random field output layer. Entity types include place names, port names, scenic spot names, business names, time expressions, number of people, budget ranges, etc. The model is fine-tuned on a multilingual NER dataset, achieving an entity recognition F1 score of no less than 0.85. The output format of entity recognition is a standardized entity object, including entity text, entity type, start position, end position, and confidence score. The intent recognition unit employs a multi-label classification network to map user input to at least 10 intent categories, including departure point setting, destination recommendation, itinerary planning, attraction search, transportation booking, accommodation booking, restaurant recommendation, shopping recommendation, and budget planning. The classification network uses BERT-base-multilingual as the feature extractor, with a three-layer multilayer perceptron output layer containing 256, 128, and [number of] intent categories, respectively. The network output uses a sigmoid activation function, supporting simultaneous recognition of multiple intents. The slot filling unit maps the identified entities to predefined slot structures according to their type, including departure slots, destination slots, travel date slots, travel days slots, number of people slots, budget slots, preference tag slots, etc. Slot filling adopts a two-layer mechanism that combines rule-based verification and model-based prediction. The first layer performs slot integrity verification based on rules, and the second layer predicts missing slots based on the filling model, thereby ensuring the integrity rate of slots.

[0025] The cross-border cultural tourism knowledge base module is the core data center, used to store and manage various types of structured cultural tourism data, such as scenic spots, cultural guides, transportation, customs ports, merchants, and multilingual terminology; including scenic spot knowledge base, cultural guide knowledge base, transportation knowledge base, customs port knowledge base, merchant knowledge base, and multilingual terminology knowledge base; The attraction knowledge base stores structured information on major cross-border tourist attractions worldwide. Each attraction record includes fields such as attraction ID, multilingual mapping of attraction name, geographical location, opening hours, ticket price, tour duration, suitable season, theme tags, carrying capacity, and real-time visitor flow data. The cultural guide knowledge base stores multilingual explanations of attractions, cultural background introductions, historical anecdotes, and suggested tour routes. Each guide record is associated with a corresponding attraction ID and supports four display formats: voice, text, images, and video. The cultural guide content supports automatic switching between no less than eight languages ​​and is maintained by a professional cultural tourism editing team. The transportation knowledge base stores spatial and timetable data on cross-border transportation modes, including flight information, train information, cross-border bus information, ferry information, travel time, ticket price, transfer nodes, etc.; the transportation data is kept synchronized with the real-time flight tracking system and the port clearance timetable system. The customs clearance knowledge base stores information such as the location, opening hours, historical data on customs clearance efficiency, visa policies, and number of border inspection channels of various countries or regions; the customs clearance data comes from official information released by the immigration management departments of various countries and historical customs clearance efficiency statistics. The merchant knowledge base stores information on restaurants, accommodations, shopping, entertainment, and other businesses in cross-border destinations. Each merchant record includes fields such as multilingual mapping of the merchant name, location coordinates, business hours, price range, payment methods, language service capabilities, and user rating scores. The multilingual terminology knowledge base stores multilingual mapping tables for cultural and tourism entities such as place names, scenic spot names, business names, and transportation station names. The mapping relationships are derived from the official translation database and the community error correction feedback mechanism to ensure that the accuracy of entity name mapping is no less than 99%. The terminology base supports bidirectional queries.

[0026] The user profile construction module is the core of demand understanding and is used to generate a multi-dimensional vector representation containing user features; it includes a feature extraction unit, a vector representation unit, and a profile update unit. The feature extraction unit extracts explicit features from user input information, including destination preferences (destination list and weights), travel time (date range), budget range (amount range and currency), number of travelers, accommodation preferences (star rating and type), transportation preferences (airplane, rail, road), and dining preferences (cuisine and price range); it extracts implicit features from historical behavior data, including browsing history, favorites, booking history, reviews, and search keywords; and it extracts dynamic features from real-time location data, such as current location, trip stage (not yet traveled, sightseeing, returning), and movement speed. The feature extraction cycle is real-time. The vector representation unit maps the extracted multi-dimensional features to a unified feature vector space. The user profile is represented by a 128-dimensional feature vector, with each dimension corresponding to the following dimensions: interest preference (32-dimensional), budget level (16-dimensional), language ability (16-dimensional), transportation preference (16-dimensional), risk preference (16-dimensional), time preference (16-dimensional), and other preference (16-dimensional). The feature vector is generated through a fully connected neural network containing three hidden layers with dimensions of 256, 128, and 64, respectively. The activation function is ReLU, and the output layer is a 128-dimensional feature vector. The network training adopts a contrastive learning strategy, with positive samples being actual user selections and negative samples being random sampling. The profile update unit dynamically corrects the user profile by combining real-time feedback information. After a user completes a visit to a scenic spot, the system collects feedback data such as the user's stay time, rating, and subsequent search behavior, and updates the weight distribution of the interest and preference dimensions. The weight update adopts an exponential decay strategy. When a user adjusts their budget or preference settings, the system immediately triggers the profile update process, adopting an incremental update strategy to ensure that the user profile remains consistent with the user's real-time needs.

[0027] The cross-border scenario constraint modeling module is a pre-planning step used to establish a cross-border specific constraint model and screen candidate resources; it includes a constraint rule definition unit, a user feature vector calculation unit, a resource feature vector calculation unit, and a matching degree screening unit. The constraint rule definition unit establishes a constraint rule library specifically for cross-border scenarios, including sub-libraries for time constraints, budget constraints, customs clearance constraints, transportation and transfer constraints, opening hours constraints, language services constraints, and payment methods constraints. Each constraint rule is defined in the form of a triple: constraint type, constraint threshold, and constraint priority. Time constraints limit daily tour duration to no more than 10 hours and single attraction stay to no more than 4 hours. Budget constraints limit total trip cost to no more than 1.2 times the user's budget limit. Customs clearance constraints require cross-border transportation arrival time to be at least 2 hours before port closing time. Transportation and transfer constraints limit consecutive transfer intervals to no more than 2 hours, with sufficient buffer time allowed. Opening hours constraints require itinerary nodes to be accessed during opening hours. Language services constraints require merchants to support the user's language. Payment methods constraints require the user's chosen payment method to be available at all merchants. The constraint rule library contains no fewer than 500 rules and supports dynamic expansion. The user feature vector calculation unit combines the 128-dimensional feature vector of the user profile with structured demand labels to generate a user demand vector. The user demand vector includes components such as destination vector (32-dimensional), time window vector (16-dimensional), budget vector (16-dimensional), and preference weight vector (64-dimensional). Each component is mapped to a unified semantic space through an independent encoder. The encoder adopts a Transformer architecture with a hidden layer dimension of 128 and a multi-head attention head of 4. The final dimension of the user demand vector is 128-dimensional. The resource feature vector calculation unit maps various cultural and tourism resources in the knowledge base to the same semantic space as the user demand vector. The scenic spot resource vector includes components such as location coordinates (2-dimensional), opening hours (8-dimensional), price (1-dimensional), theme tags (32-dimensional), and carrying capacity (1-dimensional), for a total of 44 dimensions. The transportation resource vector includes components such as origin and destination (4-dimensional), time window (8-dimensional), ticket price (1-dimensional), and comfort level (1-dimensional), for a total of 14 dimensions. The merchant resource vector includes components such as location coordinates (2-dimensional), business hours (8-dimensional), price range (1-dimensional), language service capabilities (8-dimensional), and payment support (4-dimensional), for a total of 23 dimensions. All resource vectors are uniformly mapped to a 128-dimensional semantic space through a multilingual text encoder. The matching degree filtering unit calculates the cosine similarity between the user demand vector and the resource feature vector, and filters candidate resources with a similarity not lower than a preset threshold to enter the next stage of planning; the matching degree calculation formula is: ; in, For user demand vectors, This is the resource feature vector; when the number of candidate resources exceeds the preset upper limit, the top N resources are truncated in descending order of similarity, with the default value of N being 500.

[0028] The constraint graph path planning module is the core of the planning process, used to generate candidate travel schemes that meet the constraints; it includes a node construction unit, an edge weight calculation unit, a constraint pruning unit, and a path generation unit. The node construction unit maps the selected candidate cultural and tourism resources to nodes in the constraint graph; the node types include scenic spot nodes, transportation nodes, port nodes, merchant nodes, catering nodes, accommodation nodes, etc.; each node's associated attributes include node ID (globally unique identifier), resource ID (corresponding knowledge base resource), arrival time window, departure time window, cost, experience value (0-100 points), etc.; node attributes are determined by resource feature vectors and time constraints. The edge weight calculation unit calculates the edge weight between adjacent nodes; the edge weight is calculated using a multi-dimensional weighted average, and the formula is as follows: ; in, For nodes To the node The edge weights, For time cost, For transportation costs, For spatial distance, As a risk penalty factor; , , , These are weighting coefficients, ranging from 0 to 1, with the sum of all coefficients being 1. The weighting is dynamically adjusted based on the preference dimensions in the user profile; for example, when the user prefers time efficiency... The value is 0.5. The value is 0.2. The value is 0.2. The value is 0.1; when the user prefers to save on budget, The value is 0.2. The value is 0.5. The value is 0.2. The value is 0.1; when the user prefers a cultural experience, The value is 0.3. The value is 0.2. The value is 0.3. The value is 0.2; the edge weight calculation result is stored in the adjacency matrix, and the matrix dimension is the number of nodes × the number of nodes; The constraint pruning unit performs pruning operations on the constraint graph according to the constraint rule base. The pruning strategies include time window pruning, budget limit pruning, opening time pruning, clearance time pruning, and continuity pruning. When the time window of a node is incompatible with the previous node (i.e., the arrival time plus the tour duration exceeds the start time of the next node's accessible time window), all incoming edges of that node are pruned. When the cumulative cost exceeds 1.1 times the budget limit, all candidate nodes whose costs exceed the budget are pruned. When the node's opening time does not match the user's accessible time window, the node is pruned. When the arrival time of cross-border transportation is less than 2 hours away from the port's closing time, the transportation node is pruned. When the transfer time between adjacent nodes exceeds 2 hours, the edge is pruned. The pruning operation adopts a recursive pruning strategy to ensure that the graph remains connected after pruning. The path generation unit uses an improved A The search algorithm finds candidate paths that satisfy all constraints in the pruned constraint graph; the heuristic function of the search algorithm comprehensively considers time cost, expense cost, and risk penalty, and is defined as follows: ; In the formula, To estimate the time cost from the current node to the destination, To estimate costs, To estimate risk penalties, , and The weighting factors are used for each item. When the search space is too large (the number of nodes exceeds 10,000), a hierarchical search strategy is adopted. First, the node sequence is planned at the coarse-grained layer (only scenic spot nodes are considered), and then the specific resource selection (transportation, merchants, etc.) is optimized at the fine-grained layer. Each planning generates no less than 5 candidate itinerary schemes and no more than 20.

[0029] The candidate itinerary comprehensive scoring module is the solution screening stage, used to score and rank candidate itineraries from multiple dimensions; it includes a multi-dimensional scoring unit, a weight configuration unit, and a ranking output unit. The multi-dimensional scoring unit scores each candidate itinerary based on six dimensions: interest matching, transportation convenience, budget fit, cultural experience, customs clearance convenience, and risk penalty. The interest matching score is obtained by calculating the cosine similarity between the theme tags of each attraction in the itinerary and the user's interest vector, with a score range of 0 to 100. The calculation formula is as follows: ; in, This refers to the number of attractions in the itinerary. User interest vector, For the first The feature vector of each attraction; the transportation convenience score is obtained by calculating the average transfer time and number of transfers for each transportation segment in the trip. The shorter the transfer time and the fewer the number of transfers, the higher the score. The score ranges from 0 to 100 points, and the calculation formula is: ; in, This represents the average transfer time. Number of transfers This is the maximum transfer time. This represents the maximum number of transfers; the budget fit score is obtained by calculating the ratio of the total trip cost to the user's budget, with a score range of 0 to 100. The calculation formula is as follows: ; in, The total cost of the trip. The score is calculated based on the user's budget. The cultural experience score is obtained by calculating the richness and diversity of cultural tour content during the trip; the higher the score, the more diverse themes the tour covers, such as history, art, and folklore. The score ranges from 0 to 100. The customs clearance convenience score is obtained by calculating the average waiting time and the reasonableness of the customs clearance time distribution; the shorter the waiting time and the more reasonable the customs clearance time, the higher the score. The score ranges from 0 to 100. The risk penalty score is calculated based on risk factors at each stage of the trip, including weather risk, traffic delay risk, and business operation risk. The higher the risk, the greater the penalty score. The score ranges from -50 to 0. The calculation formula is as follows: ; in, For the first Risk weight of each node For the first Risk value of each node; The weight configuration unit dynamically configures the weights of each rating dimension based on the user profile; the weight configuration formula is: ; in, For the first The weights of each rating dimension The first step in user profiling The preference intensity values ​​for each dimension range from -2 to 2; after normalization, the sum of the weights for each dimension is 1; when the user does not explicitly express their preferences, the default weight configuration is used: interest matching degree 0.25, transportation convenience 0.15, budget fit 0.20, cultural experience degree 0.20, clearance convenience 0.10, and risk penalty 0.10. The sorting output unit sorts the candidate routes in descending order based on the weighted total score, using the following formula: ; in, For the first The overall score of the candidate itineraries For the first The itinerary is in the first The scores are calculated for each rating dimension; after sorting, the itinerary with the highest total score is selected as the recommended option, while the top 3 itineraries with the highest scores are retained for users to choose from.

[0030] The multilingual itinerary output module is the result presentation stage, used to display the recommended itinerary in the user's preferred language; it includes a language adaptation unit, a content generation unit, and a display format control unit; The language adaptation unit determines the language type of the itinerary display based on the user's set output language preference; it supports output in no less than 10 languages, including Chinese, English, Japanese, Korean, Thai, and Vietnamese; the language adaptation unit calls a multilingual terminology knowledge base to uniformly replace entities such as attraction names, business names, and transportation station names in the itinerary with their corresponding translations in the target language; when the corresponding translation in the target language does not exist, it automatically reverts to the English translation and marks the original language name. The content generation unit converts the structured data of the recommended itinerary into natural language descriptions. Text description templates are dynamically selected based on itinerary type and user preferences, including compact itinerary templates (≥5 attractions per day), leisure itinerary templates (≤3 attractions per day), culturally in-depth itinerary templates (≥60% cultural attractions), and family-friendly itinerary templates (≥50% family-friendly attractions). Each template type has fixed content slots, including an itinerary overview (total number of days, total cost, cities involved), daily schedule (timeline, attractions, transportation transfers), cost details (categorized summary of tickets, meals, accommodation, and transportation), and precautions (checkpoint reminders, language prompts, payment reminders). Node card content includes attraction images (with URL links), opening hours (text descriptions), address information (local language + English), and guide links (jumping to the cultural guide knowledge base). The display format control unit determines the output format based on the terminal device type and user settings. On mobile devices, a map route overlay format is prioritized, with the map displayed using interactive layers, including attraction markers (custom icons, different types and colors), transportation routes (different line types for different modes of transportation), and a timeline control (drag-and-drop date switching). The map engine uses either Amap or Google Maps SDK, and the map data source is officially authorized data. On wearable devices, a concise voice guide format is prioritized, with the voice content compressed and the voice synthesis using TTS technology. When detailed information is required, users can switch to a node card format or a full text format.

[0031] The real-time data acquisition module is a dynamic sensing component used to collect various types of data during the trip execution process; it includes a user behavior acquisition unit, a location tracking unit, and an environmental data acquisition unit. The user behavior collection unit collects user operation behavior data through terminal application tracking, including trip viewing counts (PV statistics), trip selection operations (user's final selected plan ID), attraction detail browsing time (stay time in seconds), favorite operations (favorite timestamp), sharing operations (sharing channels), rating operations (ratings and text), preference modification operations (comparison before and after modification), etc. The collected data is stored in event log format, including fields such as user ID (anonymized), timestamp (milliseconds), event type (enumeration value), event content (JSON format), and context information (current trip node, page path). The log data is uploaded to the cloud processing platform in real time. Data storage uses a distributed Kafka message queue, and consumption processing uses the Flink stream computing framework. The location tracking unit acquires the user's real-time location through multi-mode positioning systems such as GPS, BeiDou, and GLONASS; the location data sampling frequency is no less than 1Hz, and the positioning accuracy is no less than 10m; when satellite signals cannot be obtained in indoor scenes, it automatically switches to Wi-Fi positioning or Bluetooth beacon positioning mode, with an indoor positioning accuracy of no less than 3m; the location data is used to determine whether the user has deviated from the planned route (the deviation distance is calculated using the Haversine formula), whether they have arrived at or left the scenic spot (entry radius 50m, departure radius 100m), and the current moving speed (calculated using continuous position differential), etc.; the local cache period for location data is 1 minute, and it is automatically cleared after the timeout. The environmental data acquisition unit obtains external environmental data related to the trip through third-party data interfaces; the transportation data interface connects to global flight tracking systems (such as FlightAware) and railway timetable systems (such as the international version of 12306) to obtain real-time information such as flight delays and train cancellations; the port data interface connects to real-time customs clearance data released by border inspection departments of various countries to obtain queuing time, customs clearance channel opening status, etc.; the scenic spot data interface connects to scenic spot management platforms (such as the scenic spot's official API) to obtain real-time visitor flow (person count), temporary park closures, event arrangements, etc.; the merchant data interface connects to merchant management systems (such as the international version of Dianping) to obtain changes in business status, temporary closures, etc.; the weather data interface connects to meteorological services (such as WeatherAPI) to obtain the weather forecast for the next 24 hours, including information such as temperature, precipitation, and wind speed; the polling frequency of each data interface is dynamically adjusted according to the data type.

[0032] The trip dynamic replanning module is an adaptive adjustment mechanism used to automatically adjust the trip plan based on triggering conditions during trip execution; it includes a triggering condition detection unit, a replanning decision unit, a constraint update unit, and a plan output unit. The trigger condition detection unit continuously monitors replanning trigger conditions. Trigger condition types include route deviation triggers (user's current location deviates from the planned route by more than 500m or deviation time exceeds 15 minutes), stay timeout triggers (user's stay at a scenic spot exceeds the planned time by more than 30 minutes), service status change triggers (transportation cancellations or delays exceeding 30 minutes, temporary closure of scenic spots, business closures, weather warnings, etc.), user preference modification triggers (users adjust budget ranges, add or remove scenic spots, change travel times, etc.), and emergency event triggers (earthquake warnings, typhoon warnings, epidemic notifications, political unrest, etc.). The trigger condition detection employs a mechanism combining continuous polling and event-driven mechanisms. The replanning decision unit determines the replanning strategy based on the trigger condition type. When the trigger condition is route deviation or timeout with a deviation of less than 20%, a local adjustment strategy is adopted, replanning only the affected nodes in the remaining trip while retaining the nodes of the completed trip unchanged. When the trigger condition is a service status change or a deviation exceeding 20%, a global replanning strategy is adopted, recalculating the complete path from the current location to the trip's end. When the trigger condition is a user preference modification, a requirement refactoring strategy is adopted, re-executing the user profile construction and requirement structuring process. When the trigger condition is an emergency event, an emergency avoidance strategy is adopted, prioritizing the exclusion of all nodes within the affected area. The constraint update unit updates constraints based on replanning decisions. Updates include shifting time window constraints backward (shift amount = actual time - original planned time), reallocating budget constraints (remaining budget = original budget - consumed budget), and adding constraints to exclude unavailable resources (marking unavailable resource IDs). After constraint updates, a process of re-filtering candidate resources (recalculating similarity and truncating the top N) and reconstructing the constraint graph (rebuilding nodes and edges) is automatically triggered. Constraint update messages are distributed via the Redis publish-subscribe mechanism. The solution output unit pushes the replanned new itinerary to the user terminal; the push format includes push notification (system notification bar), pop-up prompt (in-application pop-up), voice broadcast (TTS voice), etc.; when the user is in a moving state (moving speed > 5km / h), the voice broadcast format is automatically selected to output key change information; when the user is in a stationary state (moving speed ≤ 5km / h), the complete new itinerary can be displayed in the form of a notification; during the replanning process, a copy of the original plan is retained (stored in the local database) to facilitate user comparison and selection, and the comparison function supports one-click switching between the old and new plans.

[0033] After completing the system architecture, the following describes in detail the workflow of the method of the present invention in a typical cross-border tourism scenario. The workflow covers the entire process from demand collection to the end of the trip, and also demonstrates the collaborative work between the modules.

[0034] During the demand collection phase, users input cross-border cultural tourism demand information through the terminal application. The demand information is input in the form of voice or text. In this embodiment, the user input is "I plan to travel from Shenzhen to Tokyo and Osaka, Japan for 5 days in 3 days, with a budget of 20,000 yuan. I like historical and cultural attractions." The input language is Chinese. The multilingual semantic parsing module first detects that the input language is Chinese through the multilingual input recognition unit (confidence level 0.98). Then, the entity recognition unit identifies the entities: Shenzhen (departure point), Japan (destination), Tokyo (destination city), Osaka (destination city), 3 days later (travel date), 5 days (travel days), 20,000 yuan (budget), and historical and cultural (preference tag). The intent recognition unit identifies the user's intent as itinerary planning (confidence level 0.92). The slot filling unit maps the identified entities to predefined slots and generates structured demand tags. The slot completeness rate is 100%.

[0035] During the demand structuring phase, the multilingual semantic parsing module matches and aligns the identified cultural and tourism entities with the standard entities in the cross-border cultural and tourism knowledge base. Entity matching employs a fuzzy matching strategy, supporting matching of variants such as aliases, abbreviations, and colloquial names. Matching results: Shenzhen → Shenzhen (City ID: CN440300), Tokyo → Tokyo (City ID: JP130100), Osaka → Osaka (City ID: JP270200). For multilingual entities, a multilingual terminology knowledge base is invoked for mapping to ensure cross-language consistency. A unified semantic entity list is output, including entity ID, entity type, standard name, and a list of multilingual names.

[0036] In the user profile building phase, the user profile building module combines user input information, historical behavior data (if any), real-time location, and structured demand tags to generate a user profile; the feature extraction unit extracts explicit features from the input information: destination preference is Tokyo + Osaka (weight 0.8), budget level is 20,000 yuan (medium), number of travelers is 1 (default), and preference tag is history and culture; it extracts implicit features from historical behavior data (in this embodiment, it is assumed to be a new user with no historical data, and the feature is a zero vector); it extracts the current location as Shenzhen from the real-time location data; the vector representation unit maps the extracted features to a 128-dimensional feature vector and outputs a user profile vector, where the interest preference dimension is encoded as [0.2, 0.8, 0.1, ...] (the dimension value corresponding to the history and culture theme tag is 0.8), and the budget level dimension is encoded as [0.5, 0.3, 0.2] (corresponding to a budget of 20,000 yuan).

[0037] During the knowledge base retrieval phase, the system retrieves relevant data from the cross-border cultural tourism knowledge base based on structured requirement tags and user profiles; the scenic spot knowledge base returns a list of historical and cultural scenic spots in Tokyo and Osaka, including 50 scenic spots such as Kiyomizu-dera Temple, Senso-ji Temple, Kinkaku-ji Temple, and Ginza, with complete attribute fields included in the scenic spot data; the transportation knowledge base returns flight information from Shenzhen to Tokyo (direct flights + stopovers), Shinkansen information from Tokyo to Osaka, and transportation information from Kansai Airport to Osaka; the customs clearance knowledge base returns information on Japanese entry ports (Narita Airport, Kansai Airport, etc.); the merchant knowledge base returns information on restaurants, hotels, and shopping merchants in Tokyo and Osaka; and the multilingual terminology knowledge base returns the translation mappings of relevant entities in different languages.

[0038] In the resource matching phase, the cross-border scenario constraint modeling module establishes a cross-border scenario constraint model and filters candidate resources; the constraint rule definition unit loads time constraint rules, budget constraint rules, customs clearance constraint rules, transportation transfer constraint rules, opening time constraint rules, language service constraint rules, and payment method constraint rules; the user feature vector calculation unit combines the 128-dimensional feature vector of the user profile with structured demand tags to generate a 128-dimensional user demand vector; the resource feature vector calculation unit maps resources such as attractions, transportation, and merchants to a 128-dimensional resource feature vector; the matching degree filtering unit calculates the cosine similarity between the user demand vector and each resource feature vector, and filters candidate resources with a similarity of not less than 0.6. In this embodiment, 120 attraction resources, 30 transportation resources, and 150 merchant resources are selected to enter the next stage of planning.

[0039] During the route planning phase, the constraint graph route planning module constructs a cross-border constraint graph based on candidate resources and generates candidate itinerary schemes; the node construction unit maps candidate resources to constraint graph nodes, including 120 scenic spot nodes, 30 transportation nodes, and 150 merchant nodes, for a total of 300 nodes; the edge weight calculation unit calculates the edge weights between adjacent nodes, and the weights are configured according to the preference dimension (time efficiency preference) in the user profile. , β 0.2 γ =0.2、 δ =0.1; The constraint pruning unit performs pruning operations on the constraint graph according to the constraint rule base, reducing the number of nodes to 180 after pruning; The path generation unit adopts an improved A... The search algorithm finds candidate paths that satisfy all constraints. In this embodiment, 10 candidate itinerary plans are generated, each of which includes complete daily itinerary arrangements, transportation transfers, accommodation reservations and other information.

[0040] During the scoring and ranking phase, the candidate itinerary comprehensive scoring module scores and ranks the 10 candidate itineraries across multiple dimensions. The multi-dimensional scoring unit calculates six dimensions for each candidate itinerary: interest matching (match between attraction theme and user preferences), transportation convenience (transfer time and number of transfers), budget fit (cost to budget ratio), cultural experience (richness of guided tour content), customs clearance convenience (customs clearance waiting time), and risk penalty (weather and traffic risks). The weight configuration unit configures the weights for each dimension based on the user profile. Since users clearly prefer history and culture, the weights are configured as follows: interest matching 0.35, transportation convenience 0.10, budget fit 0.15, cultural experience 0.30, customs clearance convenience 0.05, and risk penalty 0.05. The ranking output unit calculates the weighted total score and sorts the itineraries in descending order, with the recommended itinerary ranked first, while retaining the top 3 itineraries for users to choose from.

[0041] During the itinerary output phase, the multilingual itinerary output module displays the recommended itinerary in the user's preferred language. If the user sets the output language to Chinese, the language adaptation unit calls the multilingual terminology knowledge base to replace the entities in the itinerary with their Chinese translations. The content generation unit selects a cultural depth itinerary template to generate a natural language description, including an itinerary overview, daily schedule, cost details, and precautions. The display format control unit detects that the user's terminal is a mobile device and prioritizes displaying a map route overlay format, with the location of each attraction, transportation routes, and timeline controls marked on the map. Users can view the complete itinerary plan within the application or switch to a node card format to view detailed information about individual attractions.

[0042] During the real-time monitoring phase, the real-time data acquisition module continuously collects various data during the trip execution process; the user behavior acquisition unit collects user behavior data such as trip viewing, attraction browsing, and favorites through application tracking points; the location tracking unit obtains the user's real-time location through GPS to determine whether the user has arrived at each attraction as planned; the environmental data acquisition unit polls to obtain real-time status data such as traffic, attractions, merchants, and weather; this embodiment assumes that the user is traveling from Tokyo to Osaka on the second day of the trip, and the real-time monitoring shows that the Shinkansen is running on time and the weather forecast shows that the Osaka area is cloudy, which is suitable for sightseeing.

[0043] During the dynamic replanning phase, the itinerary dynamic replanning module automatically adjusts the itinerary plan based on triggering conditions. In this embodiment, the real-time data acquisition module detects that the user's stay at a certain attraction exceeds the planned time by 40 minutes (timeout trigger). The triggering condition detection unit identifies it as a timeout trigger with a timeout rate of 40 minutes / 30 minutes = 133% (exceeding 20%). The replanning decision unit determines to adopt a global replanning strategy. The constraint update unit updates the time window constraints of subsequent itineraries, with a shift of 40 minutes. The constraint graph path planning module regenerates candidate itinerary plans. The candidate itinerary comprehensive scoring module recalculates the score and sorts them. The plan output unit pushes the updated itinerary plan to the user's terminal via push notification. After clicking the notification, the user can view the new itinerary arrangement, and a copy of the original plan is saved for comparison.

[0044] Example 2 This embodiment is based on the system architecture described in Embodiment 1 and is used to verify the effectiveness of the trip dynamic replanning mechanism in this invention. The focus is on testing the replanning function under three triggering conditions: route deviation, dwell timeout, and service status change.

[0045] The test scenario was set as follows: the user had completed their trip to the Tokyo area and was en route from Tokyo to Osaka; the system had already generated a complete 5-day itinerary. During the test, the following three trigger conditions were manually introduced to verify the system's responsiveness and adjustment capabilities.

[0046] Test 1: Verification of route deviation trigger conditions; The system first generates a planned itinerary from Tokyo to Osaka, including transportation nodes (Tokyo Shinkansen Station → Shin-Osaka Station) and accommodation nodes (hotels near the Osaka Loop Line). When the user's actual location deviates from the planned route by more than 500 meters, the location tracking unit of the real-time data acquisition module detects the deviation event and records the deviation distance. The trigger condition detection unit of the trip dynamic replanning module identifies it as a route deviation trigger, with a deviation degree of 800 meters / 500 meters = 160% (exceeding 20%). The replanning decision unit determines to adopt a global replanning strategy. The constraint update unit updates the time window constraints and location constraints. The constraint graph path planning module regenerates candidate routes from the current location (deviation point) to the trip destination (Osaka). The candidate trip comprehensive scoring module recalculates the score. The solution output unit pushes the new itinerary to the user via voice broadcast, with the broadcast content being "Route deviation detected. A new route from your current location to your hotel in Osaka has been replanned. The estimated arrival time is delayed by 15 minutes."

[0047] Test 2: Verification of the timeout trigger condition; The user's stay at Senso-ji Temple in Tokyo was 1.5 times the planned duration (planned 90 minutes, actual 135 minutes). The location tracking unit of the real-time data acquisition module detected the user's lingering at the attraction. The trigger condition detection unit of the itinerary dynamic replanning module identified it as a stay exceeding the time limit, with an exceedance rate of 135 minutes / 90 minutes = 150% (exceeding 20%). The replanning decision unit determined to adopt a global replanning strategy. The constraint update unit updated the time window constraints for subsequent itineraries, with a delay of 45 minutes. The constraint graph path planning module regenerated candidate routes from Senso-ji Temple to the next attraction (Kiyomizu-dera Temple). Due to the time delay, the opening time constraints needed to be re-verified. The candidate itinerary comprehensive scoring module found that some subsequent attractions in the original plan were pruned due to time window incompatibility and needed to be replaced with alternative attractions. The plan output unit pushed the updated itinerary plan to the user via push notification. In the new plan, the afternoon itinerary was reduced from 3 attractions to 2 attractions, and the visit time for each attraction was adjusted accordingly.

[0048] Test 3: Verification of service status change trigger conditions; The real-time data acquisition module's environmental data acquisition unit detected that the user's planned Shinkansen train was canceled due to an accident (delayed by more than 30 minutes and with no alternative train); the trip dynamic replanning module's trigger condition detection unit identified it as a service status change trigger (transportation cancellation); the replanning decision unit determined to adopt a global replanning strategy; the constraint update unit marked unavailable transportation resources as unavailable and removed them from the candidate resource set; the constraint graph route planning module regenerated the transportation plan and searched for alternative transportation methods (in this case, the alternative flight was selected: landing at Kansai Airport and taking the airport bus to Osaka); the candidate trip comprehensive scoring module recalculated the score of the new plan. Although the new plan was slightly more expensive (due to the increased airport bus fare), the overall score still met the recommendation requirements; the plan output unit displayed the change instructions and alternative plans to the user through a pop-up prompt, which took effect after user confirmation.

[0049] This embodiment verifies the effectiveness of the dynamic replanning mechanism of the present invention, showing that the mechanism can respond promptly and automatically adjust the itinerary plan under three typical triggering conditions: route deviation, stay timeout, and service status change, providing users with continuous and reliable itinerary services and significantly improving the user experience and emergency response capabilities of cross-border cultural tourism services.

[0050] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Although the present invention has been disclosed above with reference to preferred embodiments, it is not intended to limit the present invention. Any person skilled in the art can make some modifications or alterations to the above-disclosed technical content to create equivalent embodiments without departing from the scope of the present invention. Any simple modifications, equivalent changes, and alterations made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the scope of the present invention.

Claims

1. A dynamic planning system for cross-border cultural tourism itineraries, characterized in that, The system includes a multilingual semantic parsing module, a cross-border cultural tourism knowledge base module, a user profile construction module, a cross-border scenario constraint modeling module, a constraint graph path planning module, a candidate itinerary comprehensive scoring module, a multilingual itinerary output module, a real-time data acquisition module, and an itinerary dynamic replanning module. The multilingual semantic parsing module is used to obtain information on users' cross-border cultural and tourism needs, identify the input language type, and complete entity recognition, intent recognition, and slot filling. The cross-border cultural and tourism knowledge base module is used to store and manage several types of structured cultural and tourism data; The user profile building module is used to generate user profiles by combining user input information, historical behavior data, real-time location and structured demand tags; The cross-border scenario constraint modeling module is used to construct a cross-border scenario constraint model, calculate the matching degree between user feature vectors and resource feature vectors, and filter to obtain a set of candidate cultural and tourism resources. The constraint graph path planning module is used to construct a cross-border constraint graph based on candidate resources, abstract various cultural and tourism nodes and their connections into nodes and edges of the graph, calculate edge weights and perform constraint pruning to generate candidate itinerary schemes; The candidate itinerary comprehensive scoring module is used to calculate the comprehensive score of the candidate itineraries and sort them according to the score. The multilingual itinerary output module is used to select the itinerary with the highest rating as the recommended option; The real-time data acquisition module is used to continuously collect user feedback information and synchronously acquire real-time status data of traffic, ports, attractions, merchants, and weather. The trip dynamic replanning module recalculates the constraints when the following trigger conditions are met: route deviation, stay timeout, service status change, or user preference modification. It then regenerates and re-evaluates the remaining trip and outputs the updated trip plan.

2. The cross-border cultural tourism itinerary dynamic planning system according to claim 1, characterized in that, The multilingual semantic parsing module includes a multilingual input recognition unit, an entity recognition unit, an intent recognition unit, and a slot filling unit; The multilingual input recognition unit automatically identifies the language type of the user input through a language detection algorithm, which adopts a multi-classification model based on n-gram features. The entity recognition unit uses a pre-trained multilingual Transformer model as an encoder and decodes cultural and tourism entity labels through the conditional random field output layer. The intent recognition unit uses a multi-label classification network to map user input to several intent categories; the classification network uses BERT-base-multilingual as a feature extractor and the output layer is a multilayer perceptron. The slot filling unit maps the identified entities to predefined slot structures according to their type; the slot filling adopts a two-layer mechanism that combines rule-based verification and model-based prediction.

3. The cross-border cultural tourism itinerary dynamic planning system according to claim 2, characterized in that, The user profile construction module includes a feature extraction unit, a vector representation unit, and a profile update unit; The feature extraction unit extracts explicit features from user input information, including destination preference, travel time, budget range, number of travelers, accommodation preference, transportation preference, and dining preference; it extracts implicit features from historical behavior data, including browsing history, favorites, booking history, review history, and search keywords; and it extracts current location, trip stage, and movement speed from real-time location data. The vector representation unit maps the extracted multi-dimensional features to a unified feature vector space; User profiles are represented by 128-dimensional feature vectors, with each dimension corresponding to the dimensions of interest preference, budget level, language ability, transportation preference, risk preference, and time preference. The feature vectors are generated through a fully connected neural network containing three hidden layers with dimensions of 256, 128, and 64, respectively, and ReLU is used as the activation function. The profile update unit dynamically corrects the user profile by combining real-time feedback information; after the user completes the visit to the attraction, it collects the user's stay time, rating, and subsequent search feedback data to update the weight distribution of the interest and preference dimensions; when the user adjusts the budget or preference settings, the profile update process is triggered immediately to ensure that the user profile is consistent with the user's real-time needs.

4. The cross-border cultural tourism itinerary dynamic planning system according to claim 3, characterized in that, The cross-border scenario constraint modeling module includes a constraint rule definition unit, a user feature vector calculation unit, a resource feature vector calculation unit, and a matching degree filtering unit; The constraint rule definition unit establishes a constraint rule library specifically for cross-border scenarios, including a time constraint rule sub-library, a budget constraint rule sub-library, a customs clearance constraint rule sub-library, a transportation transfer constraint rule sub-library, an opening time constraint rule sub-library, a language service constraint rule sub-library, and a payment method constraint rule sub-library; each constraint rule is defined in the form of a triple: constraint type, constraint threshold, and constraint priority; The user feature vector calculation unit combines the 128-dimensional feature vector of the user profile with the structured demand label to generate a user demand vector. The user demand vector includes a destination vector, a time window vector, a budget vector, and a preference weight vector. Each component is mapped to a unified semantic space through an independent encoder, which adopts a Transformer architecture. The resource feature vector calculation unit maps various cultural and tourism resources in the knowledge base to the same semantic space as the user demand vector; and generates it using a pre-trained multilingual text encoder. The matching degree filtering unit calculates the cosine similarity between the user demand vector and the resource feature vector, and filters candidate resources with a similarity of not less than a preset threshold to enter the next stage of planning.

5. The cross-border cultural tourism itinerary dynamic planning system according to claim 4, characterized in that, The constraint graph path planning module includes a node construction unit, an edge weight calculation unit, a constraint pruning unit, and a path generation unit; The node construction unit maps the selected candidate cultural and tourism resources to nodes in the constraint graph; The edge weight calculation unit calculates the edge weight between adjacent nodes; the edge weight is calculated using a multi-dimensional weighted average, and the formula is as follows: ; In the formula, For nodes To the node The edge weights, For time cost, For transportation costs, For spatial distance, As a risk penalty factor; , , , These are weighting coefficients, ranging from 0 to 1, with the sum of all coefficients being 1. Weighting is dynamically adjusted based on the preference dimensions in the user profile; The constraint pruning unit performs pruning operations on the constraint graph according to the constraint rule base; the pruning strategies include time window pruning, budget limit pruning, opening time pruning, clearance time pruning, and continuity pruning; when the time window of a node is incompatible with the previous node, all incoming edges of the candidate node are pruned; when the cumulative cost exceeds 1.1 times the budget limit, candidate nodes whose cost exceeds the budget are pruned; when the opening time of a node does not match the user's accessible time window, the candidate node is pruned. The path generation unit uses an improved A The search algorithm finds candidate paths that satisfy the constraints in the pruned constraint graph; the heuristic function of the search algorithm comprehensively considers time cost, cost, and risk penalty; when the search space is larger than the standard space, a hierarchical search strategy is adopted, first planning the node sequence at the coarse-grained layer, and then optimizing resource selection at the fine-grained layer.

6. The cross-border cultural tourism itinerary dynamic planning system according to claim 5, characterized in that, The candidate itinerary comprehensive scoring module includes a multi-dimensional scoring unit, a weight configuration unit, and a sorting output unit; The multi-dimensional scoring unit scores each candidate itinerary from six dimensions: interest matching, transportation convenience, budget fit, cultural experience, customs clearance convenience, and risk penalty. The interest matching score is obtained by calculating the cosine similarity between the theme tags of each attraction in the itinerary and the user's interest vector. The transportation convenience score is obtained by calculating the average transfer time and number of transfers for each transportation segment in the itinerary. The budget fit score is obtained by calculating the ratio of the total cost of the itinerary to the user's budget. The cultural experience score is obtained by calculating the richness and diversity of cultural guided tour content in the itinerary. The customs clearance convenience score is obtained by calculating the average waiting time for cross-border customs clearance and the rationality of the distribution of customs clearance time slots. The risk penalty score is calculated based on the risk factors at each node of the itinerary. The weight configuration unit dynamically configures the weights of each rating dimension based on the user profile; the weight configuration formula is: ; In the formula, For the first The weights of each rating dimension, The first step in user profiling The preference intensity values ​​of each dimension; The sorting output unit sorts the candidate routes in descending order based on the weighted total score, using the following formula: ; In the formula, For the first The overall score of the candidate itineraries For the first The itinerary is in the first The scores are calculated for each rating dimension; after sorting, the trip with the highest total score is selected as the recommended option, while the top few trips with the highest scores are retained for users to choose from.

7. A dynamic programming method for cross-border cultural tourism itineraries, characterized in that, The method of implementing the cross-border cultural tourism itinerary dynamic planning system as described in any one of claims 1-6 includes: During the demand collection phase, information on users' cross-border cultural tourism needs is obtained through the terminal, the input language type is identified, and entity recognition, intent recognition, and slot filling are completed. In the demand structuring stage, cultural and tourism entities such as place names, port names, scenic spot names, and business names identified in different languages ​​are matched and aligned with standard entities in the cross-border cultural and tourism knowledge base to generate unified semantic entities and output structured demand tags. During the user profile building phase, user profiles are generated by combining user input information, historical behavior data, real-time location and structured demand tags, including dimensions such as interest preferences, budget level, language ability, and transportation preferences. During the knowledge base retrieval phase, structured knowledge base data is retrieved based on structured requirement tags and user profiles; In the resource matching stage, a cross-border scenario constraint model is constructed, and the matching degree is calculated by using user feature vectors and resource feature vectors to filter and obtain a set of candidate cultural and tourism resources; During the route planning phase, a cross-border constraint graph is constructed based on candidate resources. Cultural and tourism nodes and their connections are abstracted into nodes and edges of the graph. Edge weights are calculated and constraint pruning is performed to generate candidate itinerary schemes. During the scoring and ranking phase, a comprehensive score is calculated for candidate itineraries based on factors such as interest matching, transportation convenience, budget fit, cultural experience, customs clearance convenience, and risk penalty. The itineraries are then ranked according to their scores. During the trip output phase, the trip with the highest rating is selected as the recommended option; During the real-time monitoring phase, user feedback information is continuously collected, and real-time status data of traffic, ports, attractions, businesses, and weather are obtained simultaneously. During the dynamic replanning phase, when conditions such as route deviation, timeout, service status change, or user preference modification are met, the constraints are recalculated, the remaining itinerary is regenerated and re-scored, and the updated itinerary plan is output.