A transit trip planning method and computer device

By employing a bidirectional reasoning model and dynamic buffer duration calculation based on an LLM-based artificial intelligence service program, combined with a graph database, the problem of existing technologies being unable to simultaneously meet diverse user travel demands and inaccurate transfer predictions has been solved, achieving efficient and intelligent transfer itinerary planning.

CN122155066APending Publication Date: 2026-06-05ZHEJIANG ALI BUSINESS TRAVEL AGENCY CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ZHEJIANG ALI BUSINESS TRAVEL AGENCY CO LTD
Filing Date
2026-05-08
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing travel planning solutions cannot effectively respond to users' opposing travel demands of "arriving earliest" and "departing latest" at the same time, and the methods for estimating transfer times are relatively crude, resulting in inaccurate or inefficient planning results.

Method used

It adopts an AI service program built on LLM, supports bidirectional reasoning mode (forward and backward reasoning) and dynamic buffer duration calculation, and combines graph database to plan transit routes, identify user intent and accurately match travel needs.

Benefits of technology

It simultaneously satisfies users' diverse travel intentions, improves the intelligence and accuracy of trip planning, reduces user operation complexity and time waste, and enhances user experience and the credibility of planning results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122155066A_ABST
    Figure CN122155066A_ABST
Patent Text Reader

Abstract

The application discloses a transfer trip planning method, which is applied to an artificial intelligence service program based on a large language model deployed on a travel service platform and comprises the following steps: obtaining travel demand information input by a user and performing intention recognition to determine the travel intention of the user; determining a target reasoning mode from multiple reasoning modes based on the travel intention; if the target reasoning mode is a first reasoning mode, taking the arrival time of a sub-trip meeting the travel intention as a starting point, reasoning a next sub-trip in a forward direction along a time axis, and sequentially reasoning until at least one transfer trip is planned; and if the target reasoning mode is a second reasoning mode, taking the departure time of a sub-trip meeting the travel intention as a starting point, reasoning a previous sub-trip in a reverse direction along the time axis, and sequentially reasoning until at least one transfer trip is planned. The application can adaptively select a forward or reverse reasoning mode according to the user intention, and simultaneously meet the travel demand of the user for "the earliest arrival" and "the latest departure".
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments in this specification relate to the field of artificial intelligence technology, and in particular to a transit itinerary planning method and computer equipment. Background Technology

[0002] With the continuous improvement of transportation infrastructure, users have increasingly more travel options. Various modes of transportation, such as airplanes, high-speed trains, and long-distance buses, are interconnected, forming a complex integrated transportation network. However, in many travel scenarios, users often face situations where there is no direct transportation route between their departure point and destination. In such cases, users need to transfer through one or more transit stations, i.e., planning a transit itinerary.

[0003] Existing travel planning solutions typically involve travel service platforms searching for available transportation options in a transportation database based on the user's input of departure and destination points, as well as departure or arrival times, and then displaying several candidate connecting routes. This approach provides basically usable results for simple and straightforward travel needs.

[0004] However, in practical applications, existing technical solutions have the following technical pain points: First, it is poorly adaptable to users' travel intentions.

[0005] When planning transit trips, users have diverse core needs.

[0006] For example, some users want to arrive at their destination as early as possible, so they are concerned with "when is the earliest I can arrive after a given departure time"; while other users want to depart as late as possible to make full use of the time at their departure point, so they are concerned with "when is the latest I can depart before the required arrival time". Existing trip planning solutions typically only support a single calculation logic, such as searching for feasible routes based solely on the user's input departure time, making it difficult to effectively respond to both of these opposing core user needs: "earliest arrival" and "latest departure". If users want to find the "latest departure" option, they often need to repeatedly adjust their departure time and perform multiple queries, which is cumbersome and inefficient.

[0007] Second, the method for estimating transfer time is rather crude and out of touch with the actual scenario.

[0008] The feasibility assessment of transfer routes hinges on the accurate estimation of transfer time. Existing technologies typically use a fixed buffer time when determining whether two segments of a journey can be connected, such as assuming all transfers require 2 hours. However, real-world transfer scenarios are far more complex: the time consumption for transfers within the same station differs significantly from that for transfers between different stations; the exit and entry times at different transportation hubs (such as large airports and small train stations) vary; whether a journey from the airport to the train station is required during the transfer, and the choice of ground transportation (subway, taxi), all affect transfer time.

[0009] In addition, whether the travel time falls during morning or evening rush hours, and whether the transfer time coincides with mealtimes, are also important factors affecting whether users can complete the transfer smoothly. Using a fixed buffer time will either result in an estimated time that is too short, making it difficult for users to catch subsequent trains during the actual transfer and causing travel disruptions; or the estimated time will be too long, recommending inefficient routes that are too lenient and waste time.

[0010] Therefore, how to provide a transit itinerary planning solution that can better adapt to users' diverse travel intentions and accurately predict the feasibility of transfers has become a technical problem that urgently needs to be solved in this field. Summary of the Invention

[0011] In view of the above, one or more embodiments of this specification provide the following technical solutions: According to a first aspect of one or more embodiments of this specification, a transit itinerary planning method is proposed, applied to an AI service program based on LLM deployed on a travel service platform; wherein the AI ​​service program supports multiple inference modes to plan transit itineraries for users; the transit itinerary includes multiple sub-trips using different modes of transportation; the multiple inference modes include a first inference mode that infers the next sub-trip that satisfies the user's travel intention from the arrival time of the sub-trip that satisfies the user's travel intention along the positive direction of the time axis; and a second inference mode that infers the previous sub-trip that satisfies the user's travel intention from the departure time of the sub-trip that satisfies the user's travel intention along the negative direction of the time axis; the method includes: Obtain travel demand information input by the user, and perform intent recognition on the travel demand information to determine the user's travel intent; Based on the user's travel intention, a target reasoning pattern is determined from the multiple reasoning patterns to plan the transit itinerary for the user; If the target reasoning mode is the first reasoning mode, query the trip database for sub-trips that satisfy the user's travel intention, and starting from the arrival time of the sub-trip, reason out the next sub-trip that satisfies the user's travel intention along the positive direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user. If the target reasoning mode is the second reasoning mode, query the user's travel intention sub-trip from the trip database, and starting from the departure time of the sub-trip, reason out the previous sub-trip that satisfies the user's travel intention along the reverse direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user.

[0012] Optionally, the user's travel intention includes a first travel intention in which the user indicates a departure time and a second travel intention in which the user indicates an arrival time; Based on the user's travel intention, a target inference pattern is determined from the multiple inference patterns to plan a transit itinerary for the user, including: Identify the type of the user's travel intention; If the user's travel intention is the first travel intention, the first reasoning mode is determined as the target reasoning mode for planning the transit itinerary for the user; If the user's travel intention is the second travel intention, the second reasoning mode is determined as the target reasoning mode for planning the user's transit itinerary.

[0013] Optionally, the travel demand information includes the user-specified departure point and destination; The method further includes: After determining the target reasoning pattern for planning transit routes for the user from the multiple reasoning patterns, a graph search is performed in the graph database to query transit paths from the user's specified departure point to the destination; wherein, nodes in the graph data represent stations; edges in the graph data represent transit relationships between stations; the transit path includes a starting station corresponding to the departure point, at least one transit station, and a destination station corresponding to the destination.

[0014] Optionally, if the target reasoning mode is the first reasoning mode, sub-trips that satisfy the user's travel intentions are queried from the trip database, and starting from the arrival time of the sub-trip, the next sub-trip that satisfies the user's travel intentions is reasoned out along the positive direction of the time axis, and so on, until a transit trip that satisfies the user's travel intentions is planned, including: If the target reasoning mode is the first reasoning mode, query the first travel flight with a departure time after the user-indicated departure time from the travel flight information corresponding to the starting station stored in the travel database. Generate a first sub-trip based on the first travel flight. Starting from the arrival time of the first sub-trip, calculate in real time the first buffer time from the starting station to the next transfer station on the transfer path. Query the second travel flight with a departure time after the target time obtained by delaying the arrival time of the first sub-trip by the first buffer time from the travel flight information corresponding to the next transfer station stored in the travel database. Generate a second sub-trip based on the second travel flight. Continue this process until a transfer trip that satisfies the user's travel intentions is planned. If the target reasoning mode is the second reasoning mode, the system queries the trip information corresponding to the destination station stored in the trip database for the first trip whose arrival time is before the arrival time indicated by the user. Based on the first trip, a first sub-trip is generated. Starting from the departure time of the first sub-trip, the system calculates in real time the first buffer time from the destination station to the destination station from the previous transfer node on the transfer path. The system also queries the trip information corresponding to the previous transfer station stored in the trip database for the second trip whose arrival time is before the target time obtained by delaying the departure time of the first sub-trip forward by the first buffer time. Based on the second trip, a second sub-trip is generated. This process continues until a transfer trip that meets the user's travel intentions is planned.

[0015] Optionally, the buffer time from any target station on the transit path to the next transit station on the transit path is calculated in real time, including: Identify the transit type from any target station on the transit path to the next transit station on the transit path; wherein, the transit type includes same-station transit and different-station transit; If the transit type is same-station transit, the pre-configured same-station transit reservation time from the target station to the next transit station is obtained in real time and used as a buffer time from the target station to the next transit station; If the transit type is inter-station transit, the pre-configured outbound reserved time corresponding to the target station and the inbound reserved time corresponding to the next transit station are obtained in real time, and the travel time from the target station to the next transit station is calculated in real time. The outbound reserved time, the inbound reserved time and the travel time are added together to obtain the buffer time from the target station to the next transit station.

[0016] Optionally, if the transit type is intra-station transit, the pre-configured intra-station transit reservation time from the target station to the next transit station is obtained in real time as a buffer time from the target station to the next transit station, including: If the transit type is same-station transit, the pre-configured same-station transit reserved time from the target station to the next transit station is obtained in real time, and it is determined whether the travel time from the target station to the next transit station is a preset time period; wherein, the preset time period is bound to an additional reserved time period; If the travel time from the target station to the next transit station is a preset time period, the reserved transit time at the same station and the additional reserved time period bound to the preset time period are added together to obtain the buffer time from the target station to the next transit station.

[0017] Optionally, if the transfer type is an inter-station transfer, the pre-configured outbound reservation time corresponding to the target station and the inbound reservation time corresponding to the next transfer station are obtained in real time, and the travel time from the target station to the next transfer station is calculated in real time. The outbound reservation time, the inbound reservation time, and the travel time are accumulated to obtain the buffer time from the target station to the next transfer station, including: If the transit type is inter-station transit, the pre-configured outbound reserved time corresponding to the target station and the inbound reserved time corresponding to the next transit station are obtained in real time, and the travel time from the target station to the next transit station is calculated in real time, and it is determined whether the travel time from the target station to the next transit station is a preset time period; wherein, the preset time period is bound to an additional reserved time period; If the travel time from the target station to the next transit station is a preset time period, the exit reservation time, the entry reservation time, the travel time, and the additional reservation time bound to the preset time period are added together to obtain the buffer time from the target station to the next transit station.

[0018] Optionally, the at least one transit itinerary includes multiple transit itineraries planned in parallel for the user based on the first reasoning mode or the second reasoning mode to meet the user's travel intentions; The method further includes: Identify a target transit itinerary that includes sub-transfer types of same-station transfers among the multiple transit itineraries; If the multiple transit trips include a target transit trip with a transit type of same-station transit, the target transit trip will be output and displayed to the user.

[0019] Optionally, the method further includes: If none of the multiple transit itineraries contain a sub-itin with a transit type of same-station transit, calculate the suitability score corresponding to each of the multiple transit itineraries; wherein, the suitability score represents the degree of suitability with the user's travel intention; The user will be presented with at least one target transit trip that has the highest fit rating.

[0020] Optionally, the LLM-based artificial intelligence service program includes an LLM-based intelligent agent.

[0021] According to a second aspect of one or more embodiments of this specification, a computer device is also provided, comprising: a processor; a memory for storing processor-executable instructions; wherein the processor performs the executable instructions to implement the steps of the method as described in any of the first aspects above.

[0022] According to one or more embodiments of this specification, a computer-readable storage medium is also provided that stores computer instructions thereon, which, when executed by a processor, implement the steps of the method as described in any of the first aspects above.

[0023] According to a fourth aspect of one or more embodiments of this specification, a computer program product is also provided, comprising a computer program / instructions that, when executed by a processor, implement the steps of the method as described in any of the first aspects above.

[0024] Compared with existing technologies, the technical solution provided in this specification has the following beneficial effects: First, it supports dual inference modes to accurately match user intent.

[0025] In the above technical solution, two reasoning modes are set up: a first reasoning mode (forward reasoning) and a second reasoning mode (backward reasoning). By recognizing the user's input travel demand information, the appropriate target reasoning mode can be automatically determined. When the user's intent is "earliest arrival," the forward reasoning mode is used, starting from the arrival time of the first sub-trip and reasoning backward. When the user's intent is "latest departure," the backward reasoning mode is used, starting from the departure time of the second sub-trip and reasoning backward.

[0026] In this way, not only can the two core travel needs of users, "arriving early" and "leaving late", be met at the same time, but the automatic mapping from "user intent" to "computation mode" can also be achieved without the need for users to make complicated condition settings, which significantly improves the intelligence level of trip planning and user experience.

[0027] Second, a dynamic buffer period is introduced to improve the accuracy of transfer feasibility prediction.

[0028] This application calculates the buffer time from the target station to the next transfer station in real time during the planning of transfer routes. The calculation of this buffer time is not a fixed value, but is dynamically calculated based on multiple dimensions of parameters, such as transfer type (same-station transfer or different-station transfer), station characteristics (exit time, entry time), travel time (local transportation time), and whether the travel time is within a preset time period (such as mealtime).

[0029] By quantifying and incorporating various real-world factors that may affect time consumption in transfer scenarios into the calculation model, the estimated transfer time becomes closer to the actual situation. This effectively avoids the risks of missing trains or flights due to inaccurate time estimates, or the waste of user time caused by ineffective waiting, significantly improving the feasibility of trip planning and user trust in the planning results.

[0030] Third, a tiered screening mechanism has been introduced to prioritize the output of high-quality transit itineraries.

[0031] After planning multiple transit routes that meet the user's travel intentions, this application can further filter and sort the route results. Specifically, it can prioritize identifying and output target transit routes that include same-station transfer sub-routes. Since same-station transfers do not require switching between different stations, the user experience is better and the risk of transfer failure is lower. Therefore, prioritizing the display of such options to the user allows for more efficient recommendation of the optimal choice. When no same-station transfer option exists, the system calculates the suitability score between each transit route and the user's travel intentions, and displays the option with the highest suitability to the user. This hierarchical filtering mechanism considers both user experience and ensures the relevance and high quality of the final output results.

[0032] Fourth, the combination of parallel search and graph databases improves planning efficiency.

[0033] After determining the target reasoning pattern, this application utilizes a graph database to perform graph search to query transit paths from the origin to the destination. Graph databases can efficiently store and query the topological relationships between stations, transforming the path search problem into a pathfinding problem in graph theory, thus significantly improving search efficiency in complex networks. Attached Figure Description

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

[0035] Figure 1 This is a schematic diagram of the architecture of a transit itinerary planning system shown in one embodiment of this specification; Figure 2 This is a flowchart illustrating a transit itinerary planning method in one embodiment of this specification; Figure 3 This is a schematic structural diagram of an electronic device shown in one embodiment of this specification; Figure 4 This is a block diagram of a transfer route planning device shown in one embodiment of this specification. Detailed Implementation

[0036] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with one or more embodiments of this specification. Rather, they are merely examples of apparatuses and methods consistent with some aspects of one or more embodiments of this specification as detailed in the appended claims.

[0037] It should be noted that the steps of the corresponding methods are not necessarily performed in the order shown and described in this specification in other embodiments. In some other embodiments, the methods may include more or fewer steps than described in this specification. Furthermore, a single step described in this specification may be broken down into multiple steps in other embodiments; and multiple steps described in this specification may be combined into a single step in other embodiments.

[0038] The user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this manual are all information and data authorized by the user or fully authorized by all parties. The collection, use and processing of related data shall comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation portals shall be provided for users to choose to authorize or refuse.

[0039] With the increasing development of transportation networks, users' travel needs are becoming more complex. When there is no direct transportation between the origin and destination, users need to transfer through one or more intermediate stations, i.e., plan a connecting journey. Traditional connecting journey planning schemes usually adopt a single calculation model, for example, searching for subsequent connectable journeys in the forward direction of the time axis based on the user's specified departure time.

[0040] However, in practical applications, the above-mentioned traditional solutions have obvious technical limitations.

[0041] On the one hand, users' travel intentions are diverse. For example, some users want to arrive at their destination as early as possible, while others want to depart as late as possible to make the most of the daytime. The existing single forward search model cannot simultaneously satisfy these two diametrically opposed needs. When users are concerned with "what is the latest departure time to arrive on time", traditional forward search solutions cannot provide a direct answer. Users often need to repeatedly try different departure times, which is cumbersome and inefficient.

[0042] On the other hand, existing technologies typically use fixed, static transfer buffer times when calculating transfer feasibility. This approach ignores the complexity of transfer scenarios; For example, there are differences in the time required for transfers within the same station versus transfers between different stations, differences in entry and exit times at different stations (such as airports and train stations), the impact of travel times (such as morning and evening rush hours) on ground transportation, and even the impact of meal times on transfer arrangements. Using a fixed buffer time can either lead to overly tight estimated times, making it difficult for users to actually complete the transfer, or overly generous estimated times, resulting in wasted user time and reduced accuracy and practicality of route planning.

[0043] Based on this, this specification proposes a technical solution that deploys an artificial intelligence service program supporting multiple inference modes in a travel service platform, identifies the user's travel intention, adaptively determines the target inference mode from the multiple supported inference modes based on the user's travel intention, and then plans a transfer itinerary for the user that includes multiple sub-trips using different modes of transportation based on the target inference mode.

[0044] In this technical solution, the various reasoning modes supported by the aforementioned artificial intelligence service program can specifically include a first reasoning mode that starts from the arrival time of the sub-trip that satisfies the user's travel intention and reasons along the positive direction of the time axis to deduce the next sub-trip that satisfies the user's travel intention; and a second reasoning mode that starts from the departure time of the sub-trip that satisfies the user's travel intention and reasons along the negative direction of the time axis to deduce the previous sub-trip that satisfies the user's travel intention.

[0045] In the process of planning transit itineraries for users, the aforementioned artificial intelligence service program can obtain the travel demand information input by the user and perform intent recognition on the travel demand information to determine the user's travel intent. Then, based on the user's travel intention, a target reasoning pattern is determined from the multiple reasoning patterns to plan the transit itinerary for the user; Once the target reasoning pattern is determined, on the one hand, if the target reasoning pattern is the first reasoning pattern, the sub-trips that satisfy the user's travel intentions are queried from the trip database, and the next sub-trip that satisfies the user's travel intentions is inferred from the arrival time of the sub-trips along the positive direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intentions is planned for the user. On the other hand, if the target reasoning mode is the second reasoning mode, the user's travel intention sub-trip is queried from the trip database, and the previous sub-trip that satisfies the user's travel intention is reasoned out along the reverse direction of the time axis, starting from the departure time of the sub-trip. This process is repeated until at least one transit trip that satisfies the user's travel intention is planned for the user.

[0046] In the above technical solution, two reasoning modes are set up: a first reasoning mode (forward reasoning) and a second reasoning mode (backward reasoning). By recognizing the user's input travel demand information, the appropriate target reasoning mode can be automatically determined. When the user's intent is "earliest arrival," the forward reasoning mode is used, starting from the arrival time of the first sub-trip and reasoning backward. When the user's intent is "latest departure," the backward reasoning mode is used, starting from the departure time of the second sub-trip and reasoning backward.

[0047] In this way, not only can the two core travel needs of users, "arriving early" and "leaving late", be met at the same time, but the automatic mapping from "user intent" to "computation mode" can also be achieved without the need for users to make complicated condition settings, which significantly improves the intelligence level of trip planning and user experience.

[0048] Figure 1 This is a schematic diagram of the architecture of a transit itinerary planning system provided in an exemplary embodiment.

[0049] like Figure 1 As shown, the transit itinerary planning system may include a travel service platform, an artificial intelligence service program based on a large language model (LLM) deployed on the travel service platform, and one or more terminal devices on the user side.

[0050] The travel service platform can be deployed on a physical server containing an independent host, or on a virtual server hosted in a host cluster. During operation, the travel service platform carries the backend logic for transit itinerary planning and provides data access interfaces to external systems. The artificial intelligence service program runs on the travel service platform and can specifically take the form of an intelligent agent built based on a large language model. This intelligent agent possesses capabilities such as natural language understanding, intent recognition, task planning, and tool invocation, and is used to execute the core computational logic for transit itinerary planning.

[0051] The terminal device can be any type of electronic device used by the user, including but not limited to personal computers, laptops, smartphones, tablets, PDAs, or wearable devices. During operation, the terminal device runs a client program corresponding to the travel service platform. This client program can be a native application installed on the terminal device, a mini-program, a quick app, or a webpage displayed through a browser.

[0052] The terminal device establishes a communication connection with the travel service platform via a wired or wireless network.

[0053] During system operation, users can input travel demand information through a client program running on the terminal device. The terminal device sends the travel demand information to the travel service platform via the network. After receiving the travel demand information, the travel service platform transmits it to the artificial intelligence service program. The artificial intelligence service program performs intent recognition on the travel demand information to determine the user's travel intention, and based on the travel intention, plans at least one transit itinerary for the user, including multiple sub-trips using different modes of transportation, and displays the at least one transit itinerary to the user through the client program.

[0054] The technical solution of this specification will be described in detail below with reference to the accompanying drawings.

[0055] Please see Figure 2 , Figure 2 This document presents a flowchart of a transit itinerary planning method, applied to an LLM-based artificial intelligence service program deployed on a travel service platform; it includes the following execution process: Step 202: Obtain the travel demand information input by the user, and perform intent recognition on the travel demand information to determine the user's travel intent; The entity that executes the above method may specifically include an artificial intelligence service program built on LLM.

[0056] In some embodiments, the aforementioned AI service program can be an intelligent agent built on an LLM (Limited Management Model). In this case, the service model can specifically be an AI assistant for business travel management built on an LLM.

[0057] This intelligent agent not only possesses the ability to understand natural language and recognize intent, but can also make dynamic decisions based on the user's historical behavior and real-time contextual information (such as weather and road conditions).

[0058] In its implementation, the intelligent agent can include one or more large language models, a task planning module, and a tool invocation module. The large language model is responsible for understanding user input and generating natural language responses; the task planning module breaks down the user's travel needs into multiple sub-tasks; and the tool invocation module calls external tools, such as trip database query interfaces, map service APIs, and graph database query interfaces, to execute these sub-tasks. Through the collaborative work of the intelligent agent, the entire trip planning process becomes more intelligent and automated.

[0059] In practical applications, this artificial intelligence service program can include a server program and a client program. The server program and the client program work together to provide users with user services related to transit itinerary planning.

[0060] For example, in some embodiments, the execution of the above method process can be either the server program of the above artificial intelligence service program or the client program of the above artificial intelligence service program; or, some steps in the above method can run on the server program and some steps can run on the client program, and the process corresponding to the above method can be executed together through the mutual cooperation of the server program and the client program.

[0061] The services provided to users by the aforementioned artificial intelligence service program can specifically include any form of travel planning-related service that can be implemented on the Internet, and will not be specifically limited in this specification. For example, in some embodiments, the services provided to users by the aforementioned artificial intelligence service program can specifically include transit travel planning services in business travel services.

[0062] In some embodiments, the aforementioned travel service platform can provide comprehensive services across multiple service domains; the travel service platform can manage multiple service models corresponding one-to-one with the aforementioned multiple service domains as domain expert models; the aforementioned service models can specifically be service models built based on LLM. For example, in some embodiments, the aforementioned travel service platform can specifically be an enterprise-level business travel service platform, and the aforementioned multiple service domains can specifically include business travel-related service domains such as itinerary planning services, flight booking services, hotel booking services, train ticket booking services, car rental services, business travel data analysis services, and business travel policy inquiry services, etc.

[0063] Correspondingly, the travel service platform manages multiple service models based on LLM, each corresponding to one of the aforementioned service areas. These models may include a first service model for executing transit itinerary planning services, a second service model for executing flight booking services, and a third service model for executing hotel booking services. The technical solution described in this application can be specifically executed by the aforementioned first service model (i.e., the service model for executing transit itinerary planning services).

[0064] It should be noted that the service model built on LLM can specifically include any form of service model that uses LLM as the core computing engine, with the LLM responsible for providing natural language understanding, generation, reasoning, and decision-making capabilities. In some embodiments, the aforementioned service model built on LLM can specifically include an artificial intelligence service program built on LLM; for example, it can include an intelligent agent built on LLM. In this case, the aforementioned service model can specifically be a business travel AI assistant built on LLM, which can understand user needs through natural language interaction and automatically complete a series of operations such as transit itinerary planning, ticket inquiry, and booking.

[0065] In some embodiments, in addition to managing multiple service models corresponding one-to-one with the aforementioned service domains, the external knowledge base accessed by the travel service platform may also include multiple sub-knowledge bases corresponding one-to-one with the service domains, since these service domains may involve highly specialized structured knowledge. These sub-knowledge bases can specifically store specialized structured knowledge related to the relevant service domains.

[0066] For example, in the business travel service sector, it might be necessary to use data such as the company's internal business travel management policies, travel standards, list of contracted hotels, and list of contracted airlines as structured knowledge. In this scenario, this data can be processed into structured knowledge and stored in sub-knowledge bases corresponding to each service area. Subsequently, LLM can use the structured knowledge stored in these sub-knowledge bases as reasoning context to accurately provide business travel services to users according to the company's business travel management policies.

[0067] In some embodiments, the aforementioned artificial intelligence service program can support planning transit itineraries for users using multiple reasoning models. These transit itineraries may include multiple sub-trips using different modes of transportation (e.g., airplanes, high-speed trains, long-distance buses, ferries, etc.).

[0068] These multiple reasoning modes can specifically include a first reasoning mode and a second reasoning mode.

[0069] The first reasoning mode is a forward reasoning mode. In this mode, starting from the arrival time of the sub-trip that satisfies the user's travel intention, the next sub-trip that satisfies the user's travel intention can be deduced along the forward direction of the timeline. In practical applications, this reasoning mode is suitable for scenarios where the user knows or cares about the departure time of the first trip and wants to know the connection scheme of the subsequent trip and reach the destination as soon as possible.

[0070] The second reasoning mode is a reverse reasoning mode. In this mode, starting from the departure time of the sub-trip that satisfies the user's travel intention, the previous sub-trip that satisfies the user's travel intention can be deduced by moving backward along the timeline. In practical applications, this reasoning mode is suitable for scenarios where the user knows or cares about the arrival time of the last leg of the trip and wants to know the latest possible departure time while meeting that time requirement.

[0071] In some embodiments, when a user needs to plan a connecting trip, they can input travel request information through the user interface (e.g., a search box in a mobile application, a dialog box in a web browser, or a smart voice assistant) provided by the aforementioned AI service program. This travel request information may at least include the departure point and destination. Of course, if the user's input travel request information does not include the departure point and destination, the aforementioned AI service program can prompt the user to output these information through multiple rounds of interaction.

[0072] In some embodiments, the travel demand information may also include a user-specified departure time or a user-specified arrival time. For example, a user may enter: "From Beijing to Shanghai, departing at 8:00 AM tomorrow." Alternatively, a user may enter: "From Beijing to Shanghai, arriving before 5:00 PM tomorrow."

[0073] Once the aforementioned AI service program receives a user's travel request information, it can perform intent recognition on that travel request information.

[0074] It should be noted that this AI service program can be a trained service program with natural language understanding capabilities. When recognizing the intent behind the travel request information, it can extract key elements from the user's input, such as "departure point," "destination," and "time constraints." Then, based on these key elements, it can determine the user's travel intent.

[0075] In some embodiments, a user's travel intention may specifically include a first travel intention in which the user indicates a departure time and a second travel intention in which the user indicates an arrival time; the aforementioned artificial intelligence service program may determine the user's travel intention based on the time constraints extracted from travel demand information as a key element.

[0076] For example, it can be determined whether the time constraint is a departure time constraint or an arrival time constraint. If the user provides a departure time constraint, the user's travel intention is determined to be the first travel intention (i.e., the user cares about "when to depart"); if the user provides an arrival time constraint, the user's travel intention is determined to be the second travel intention (i.e., the user cares about "when to arrive").

[0077] Step 204: Based on the user's travel intention, determine the target reasoning pattern from the multiple reasoning patterns to plan the transit itinerary for the user; After determining the user's travel intention, the aforementioned AI service program can further determine the target reasoning pattern for planning the user's transit itinerary from a variety of supported reasoning patterns based on the user's travel intention.

[0078] In some embodiments, on the one hand, if the user's travel intention is the first travel intention mentioned above (i.e., the user has specified a departure time), the first reasoning mode (forward reasoning) mentioned above can be determined as the target reasoning mode for planning the transfer itinerary for the user; this is because when the user knows the departure time, their core demand is usually "how to arrive as quickly and smoothly as possible after departing at that time", which corresponds to the logic of forward reasoning.

[0079] On the other hand, if the user's travel intention is the second travel intention mentioned above (i.e., the user has specified an arrival time), the second reasoning pattern (reverse reasoning) can be identified as the target reasoning pattern for planning the user's transit itinerary. This is because when the user knows the target arrival time, their core demand is usually "what is the latest time they can leave to catch up," which corresponds to the logic of reverse reasoning.

[0080] Through the above steps, the AI ​​service program can automatically and intelligently select the most suitable reasoning mode based on the user's input travel needs, without requiring the user to make a manual selection, thus significantly improving the intelligence level and ease of operation of trip planning.

[0081] Of course, in practical applications, for complex travel demand information input by users that includes both the first and second travel intentions mentioned above, the aforementioned artificial intelligence service program can break down the travel intention described by the travel demand information into multiple sub-tasks for execution separately.

[0082] Step 206: If the target reasoning mode is the first reasoning mode, query the trip database for sub-trips that satisfy the user's travel intention, and starting from the arrival time of the sub-trip, reason out the next sub-trip that satisfies the user's travel intention along the positive direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user.

[0083] In some embodiments, after the AI ​​service program determines a target reasoning pattern for planning transit routes for the user from a variety of supported reasoning patterns based on the user's travel intention, it can use a graph database to perform a graph search to query all transit routes from the user's specified departure point to the destination.

[0084] The aforementioned transit route may include an originating station corresponding to the aforementioned departure point, at least one transit station, and a destination station corresponding to the aforementioned destination.

[0085] The aforementioned graph database is a database system that stores and queries data using a graph structure (nodes and edges). In the specification, nodes in the graph database can represent transportation stations (such as "Beijing South Station," "Shanghai Hongqiao Station," and "Nanjing South Station"), and edges can represent transfer relationships between stations. For example, if there exists a high-speed rail line from Beijing South Station to Nanjing South Station, a directed edge is established between the Beijing South Station node and the Nanjing South Station node. This edge can carry attribute information such as line type (high-speed rail) and average travel time.

[0086] By performing a graph search in the graph database, the system can quickly find all possible paths from the origin node to the destination node. Each path includes a starting station, one or more transit stations, and a destination station.

[0087] The graph search algorithm used for graph searches in graph databases is not specifically limited in this specification. For example, in practical applications, graph search algorithms such as breadth-first search can be used.

[0088] Once the aforementioned AI service program uses graph search to retrieve all transit routes from the user's specified departure point to the destination, it can start from the initial station on the transit route and perform reasoning calculations based on the aforementioned target reasoning pattern to plan all sub-trips that satisfy the user's travel intentions.

[0089] If the target reasoning mode is the first reasoning mode, the AI ​​service program can query the trip database for sub-trips that satisfy the user's travel intentions. Starting from the arrival time of the sub-trip, it can reason out the next sub-trip that satisfies the user's travel intentions along the positive direction of the time axis. This process can be repeated iteratively until the AI ​​program plans at least one transit trip that satisfies the user's travel intentions.

[0090] In some embodiments, if the target reasoning mode is the first reasoning mode, the first travel flight whose departure time is after the departure time indicated by the user can be queried from the travel flight information corresponding to the starting station in the transit trip stored in the trip database, and a first sub-trip can be generated based on the first travel flight.

[0091] Furthermore, starting from the arrival time of the first sub-trip, the first buffer time from the starting station to the next transfer station on the transfer path can be calculated in real time. Then, from the trip information corresponding to the next transfer station stored in the trip database, the second trip whose departure time is after the target time obtained by delaying the arrival time of the first sub-trip by the first buffer time can be queried. Then, the second sub-trip can be generated based on the second trip.

[0092] Similarly, the aforementioned AI service program can iteratively execute the above process until it plans a transit itinerary that meets the user's travel intentions.

[0093] For example, suppose a user enters their travel request information as: "From Beijing to Shanghai, departing at 8 am tomorrow".

[0094] At this point, after receiving the user's travel demand information, the AI ​​service program determines the user's travel intention as the primary travel intention through intent recognition and identifies the primary reasoning mode as the target reasoning mode.

[0095] First, the AI ​​service program can obtain transit route information from the graph database.

[0096] In this example, assume that the transit path returned by the graph database search is: Beijing South Station (originating station) → Nanjing South Station (transit station) → Shanghai Hongqiao Station (destination station).

[0097] Based on this transit route, the AI ​​service program determines that two transfers are required. First, it needs to query the first sub-trip from Beijing South Station to Nanjing South Station, and then query the second sub-trip from Nanjing South Station to Shanghai Hongqiao Station.

[0098] The AI ​​service program can access the travel database to query travel information for trains departing from the originating station "Beijing South Railway Station" with departure times after "8:00 AM tomorrow".

[0099] Suppose the travel database stores the following high-speed train schedules from Beijing South Station to Nanjing South Station:

[0100] All of the above departure times meet the time constraint of "after 8:00 AM tomorrow", and therefore are included in the first set of candidate sub-trips.

[0101] The aforementioned AI service program can process each candidate first sub-journey sequentially. Taking the G101 high-speed train as an example, its arrival time at Nanjing South Station is 11:00. To determine whether passengers can successfully transfer to the second sub-journey from Nanjing South Station to Shanghai Hongqiao Station, the AI ​​service program needs to calculate the buffer time for the transfer from Nanjing South Station.

[0102] Based on the above calculation results, the artificial intelligence service program can determine the earliest feasible departure time of the second sub-trip as: the arrival time of the first sub-trip plus the dynamic buffer time, i.e., 11:00 + 20 minutes = 11:20.

[0103] The AI ​​service program can continue to access the travel database to query travel information for trains departing from Nanjing South Station to Shanghai Hongqiao Station with departure times after 11:20.

[0104] Suppose the travel database stores the following high-speed train schedules from Nanjing South Station to Shanghai Hongqiao Station:

[0105] Of the aforementioned train services, those departing after 11:20 include G201 (11:30), G203 (12:00), and G205 (13:00), all of which have been included in the candidate second sub-trip set.

[0106] For the candidate first sub-journey, high-speed train G101, the connectable second sub-journeys include trains G201, G203, and G205. The AI ​​service program combines the first sub-journey with each candidate second sub-journey to form multiple candidate transfer itineraries: Option 1: G101 (departs from Beijing South Station at 08:00 and arrives at Nanjing South Station at 11:00) + G201 (departs from Nanjing South Station at 11:30 and arrives at Shanghai Hongqiao Station at 12:30). Option 2: G101 + G203 (departing from Nanjing South Station at 12:00 and arriving at Shanghai Hongqiao Station at 13:00). Option 3: G101 + G205 (departing from Nanjing South Station at 13:00 and arriving at Shanghai Hongqiao Station at 14:00). Similarly, the AI ​​service program sequentially processes other candidate first sub-trips (G103, G105, G107), filters out second sub-trips that meet the departure time constraints for each first sub-trip, and generates corresponding candidate transfer trips.

[0107] After generating all candidate transit itineraries, the AI ​​service program can filter and sort the results. Based on the optimization objective of the forward reasoning model (i.e., "fastest arrival"), the AI ​​service program arranges the candidate itineraries in ascending order according to their final arrival time. In this example, candidate itinerary one has a final arrival time of 12:30, which is the earliest among all candidate itineraries.

[0108] Therefore, the AI ​​service program can determine candidate itinerary one (G101 connecting to G201) as the user's optimal transfer itinerary and return this itinerary information to the user's terminal device via the travel service platform for display. The displayed information may include: the first leg's train number and departure and arrival times, transfer stations and transfer times (including dynamic buffer time), the second leg's train number and departure and arrival times, and the total travel time, etc.

[0109] Through the above forward reasoning process, the AI ​​service program can deduce the subsequent itinerary segment by segment along the timeline, starting from the departure time specified by the user, and combine dynamic buffer time calculation to ensure the feasibility of transfers, and finally plan the fastest route for the user from Beijing to Shanghai Hongqiao Station via Nanjing South Station.

[0110] Specifically, the buffer time mentioned above refers to the maximum time reserved for users to travel from one site to the next. By setting this buffer time, it can be ensured that users have sufficient time to travel from one site to the next.

[0111] In some embodiments, the aforementioned artificial intelligence service program calculates in real time the buffer time from any target station on the transit path to the next transit station on the transit path, which may include the following sub-steps: First, the aforementioned artificial intelligence service program can identify the transit type from the target station to the next transit station.

[0112] It should be noted that this transfer type can specifically include same-station transfers and different-station transfers. If the destination station and the next transfer station are the same station (for example, transferring within the same train station), the transfer type is same-station transfer; if the destination station and the next transfer station are different stations (for example, transferring from the airport to the train station), the transfer type is different-station transfer.

[0113] On the one hand, if the transfer type from the target station to the next transit station is a same-station transfer, the aforementioned AI service program can obtain the pre-configured same-station transfer reservation time from the target station to the next transit station in real time, using this as a buffer time. This same-station transfer reservation time can be an empirical value pre-stored in the configuration center of the aforementioned travel service platform for a specific station. For example, for large hub stations, the same-station transfer reservation time can be set to 20 minutes; for smaller stations, it can be set to 10 minutes.

[0114] In some embodiments, the aforementioned AI service program may further consider the impact of travel time on transfer time. Specifically, the AI ​​service program may also determine whether the travel time from the target station to the next transfer station falls within a preset time period (e.g., morning peak 7:30-9:00, lunchtime 11:30-13:00, evening peak 17:30-19:00). These preset time periods can each be bound to an additional reserved time; for example, a 20-minute reservation time can be bound for lunchtime, and a 10-minute reservation time can be bound for peak hours due to congestion.

[0115] If the above travel period is determined to be the preset period, the AI ​​service program can add up the reserved time for transfers at the same station and the additional reserved time bound to the above preset period to obtain the final buffer time.

[0116] For example, if a transfer occurs at Beijing South Railway Station (with a 20-minute buffer for transfers within the same station), and the transfer time happens to fall during the 12:00-13:00 lunch break (with an additional 20-minute buffer), then the final buffer time will be 20 + 20 = 30 minutes. This approach fully considers the essential need for "eating" in real-world scenarios, making the planning results more humane and feasible.

[0117] On the other hand, if the transfer type from the aforementioned target station to the next transfer station is an inter-station transfer, the calculation of the buffer time is more complex, requiring the integration of multiple time segments such as exiting the station, traffic, and entering the station.

[0118] In this scenario, the AI ​​service program system can first obtain in real time the pre-configured outbound reservation time corresponding to the target station, and the inbound reservation time corresponding to the next transit station.

[0119] The exit time and arrival time refer to the average time required for passengers to disembark from their mode of transport and arrive at external transportation hubs (such as taxi waiting areas or subway station entrances). These times can be configured based on the station's size, layout, and historical data; for example, the exit time at Beijing Daxing International Airport can be configured as 25 minutes, and the arrival time at Shanghai Hongqiao Railway Station can be configured as 15 minutes.

[0120] Secondly, the AI ​​service program can also calculate the travel time from the target station to the next transit station in real time.

[0121] The travel time refers to the time required for a passenger to move from one station to another using urban ground transportation (such as subway, taxi, ride-hailing service, or walking). In practical applications, this time can be obtained in real time by calling a third-party map service API (Application Programming Interface). This API can return a dynamic and relatively accurate estimated time based on factors such as current road conditions, mode of transportation, and distance. For example, when traveling from Beijing Daxing Airport to Beijing South Railway Station using a combination of subway and taxi, the estimated travel time returned by the API might be 55 minutes during off-peak hours, while during evening peak hours, the estimated travel time might be 85 minutes.

[0122] Then, the AI ​​service program can sum up the aforementioned exit time, travel time, and entry time to obtain the initial transfer buffer time between stations. Based on this, the AI ​​service program can further determine whether the travel time of the transfer is within a preset time period (such as mealtimes). If so, it will continue to accumulate the corresponding additional reserve time.

[0123] Therefore, the complete formula for calculating the inter-station transit buffer time can be expressed as: Buffer time = Departure allowance + Travel time + Arrival allowance + Additional allowance (if applicable) For example, if you transfer from Beijing Daxing Airport (allow 25 minutes to exit) to Beijing South Railway Station (allow 15 minutes to enter), and choose the subway + taxi combination, under the conditions of evening rush hour (travel time 85 minutes) and it happens to be mealtime (additional 20 minutes), the final buffer time will be 25 + 85 + 15 + 20 = 145 minutes.

[0124] Step 208: If the target reasoning mode is the second reasoning mode, query the user's travel intention sub-trip from the trip database, and starting from the departure time of the sub-trip, reason out the previous sub-trip that satisfies the user's travel intention along the reverse direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user.

[0125] In some embodiments, if the target reasoning mode is the second reasoning mode, the first trip with an arrival time before the user-indicated arrival time can be queried from the trip information corresponding to the destination station stored in the trip database, and a first sub-trip can be generated based on the first trip.

[0126] Furthermore, starting from the departure time of the first sub-trip, the first buffer time from the destination station to the destination station via the previous transfer node on the transfer path can be calculated in real time. Then, from the trip information corresponding to the previous transfer station stored in the trip database, the arrival time of the second trip can be queried, which is earlier than the target time obtained by delaying the departure time of the first sub-trip forward by the first buffer time. Then, the second sub-trip can be generated based on the second trip.

[0127] Similarly, the aforementioned AI service program can iteratively execute the above process until it plans a transit itinerary that meets the user's travel intentions.

[0128] For example, suppose a user enters the following travel request information: "From Beijing to Shanghai, arriving before 5 pm tomorrow".

[0129] At this point, after receiving the user's travel demand information, the AI ​​service program determines the user's travel intention as the second travel intention through intent recognition, and identifies the second reasoning mode as the target reasoning mode.

[0130] First, the AI ​​service program can obtain transit route information from the graph database.

[0131] In this example, we assume that the transit path returned by the graph database search is still: Beijing South Station (originating station) → Nanjing South Station (transit station) → Shanghai Hongqiao Station (destination station).

[0132] Based on this path, the AI ​​service program determines that two transfers are required, and the reverse reasoning should start from the last segment of the journey. That is, it first needs to query the last segment of the journey from Nanjing South Station to Shanghai Hongqiao Station, and then query the previous segment of the journey from Beijing South Station to Nanjing South Station.

[0133] First, the AI ​​service program accesses the travel database to query train schedules arriving at "Shanghai Hongqiao Station" before 5 PM tomorrow. Assume the travel database stores the following high-speed rail schedules from Nanjing South Station to Shanghai Hongqiao Station:

[0134] Of the aforementioned train services, those arriving before 5 PM tomorrow include G201 (2:00 PM), G203 (3:00 PM), G205 (4:00 PM), and G207 (5:00 PM), all of which have been included in the candidate last segment of the itinerary set. Among these, G207, although arriving at exactly 5 PM, still meets the constraint of "before 5 PM" and is therefore retained.

[0135] The AI ​​service program processes each candidate last segment of the journey sequentially. Taking the G207 high-speed train as an example, its departure time from Nanjing South Station is 16:00. In order to determine whether passengers can successfully transfer from the previous segment to this station, the AI ​​service program needs to calculate the buffer time for the transfer from Nanjing South Station.

[0136] The AI ​​service program identifies this transfer type as a same-station transfer (Nanjing South Station is both the arrival station of the previous sub-trip and the departure station of this sub-trip), and obtains the reserved transfer time for same-station transfers at Nanjing South Station based on the station feature database. At the same time, it dynamically calculates the buffer time by combining factors such as travel time and catering needs. The specific calculation process of the buffer time will not be elaborated here.

[0137] Assuming that the buffer time required for transferring at Nanjing South Railway Station is 20 minutes according to dynamic calculation, the latest feasible arrival time of the previous sub-trip determined by the artificial intelligence service program is: the departure time of this sub-trip minus the dynamic buffer time, i.e., 16:00 - 20 minutes = 15:30.

[0138] The AI ​​service program accesses the travel database to query travel information for trains departing from Beijing South Railway Station to Nanjing South Railway Station with an arrival time before 15:30.

[0139] Suppose the travel database stores the following high-speed train schedules from Beijing South Station to Nanjing South Station:

[0140] Of the aforementioned train services, those arriving before 15:30 include G101 (11:00), G103 (12:00), G105 (13:00), G107 (14:00), and G109 (15:00). G111, arriving at 16:00, is later than 15:30 and is therefore excluded.

[0141] For the candidate final sub-journey G207, the preceding sub-journeys that can connect with it include G101, G103, G105, G107, and G109.

[0142] The AI ​​service program combines each candidate previous segment of the journey with G207 to form multiple candidate transfer journeys: Option 1: G101 (departs from Beijing South Station at 08:00 and arrives at Nanjing South Station at 11:00) + G207 (departs from Nanjing South Station at 16:00 and arrives at Shanghai Hongqiao Station at 17:00). Option 2: G103 (departs at 09:00, arrives at 12:00) + G207 (departs at 16:00, arrives at 17:00); Option 3: G105 (departs at 10:00, arrives at 13:00) + G207 (departs at 16:00, arrives at 17:00); Option 4: G107 (departs at 11:00, arrives at 14:00) + G207 (departs at 16:00, arrives at 17:00); Option 5: G109 (departs at 12:00, arrives at 15:00) + G207 (departs at 16:00, arrives at 17:00); Similarly, the AI ​​service program processes the other candidate last sub-trips (G201, G203, G205) in sequence, filters out the previous sub-trip that meets the arrival time constraints for each last sub-trip, and generates the corresponding candidate transfer trips.

[0143] After generating all candidate transfer itineraries, the AI ​​service program filters and sorts the results. Based on the optimization objective of the reverse reasoning model (i.e., "latest departure"), the AI ​​service program sorts the candidate itineraries in descending order according to the departure time of the first sub-segment. Among all candidate itineraries, the one with the latest departure time for the first sub-segment is train G109 (departing at 12:00), and the corresponding complete itinerary is train G109 transferring to train G207.

[0144] Therefore, the AI ​​service program determines the optimal transfer route for the user as G109 to G207, and returns this route information to the user's terminal device via the travel service platform for display. The displayed information may include: the first leg's train number and departure and arrival times, transfer stations and transfer times (including dynamic buffer time), the second leg's train number and departure and arrival times, and the final arrival time, etc.

[0145] Through the above reverse reasoning process, the artificial intelligence service program can use the user-specified arrival time as the endpoint, reverse the timeline segment by segment to deduce the previous journey, and combine dynamic buffer time calculation to ensure the feasibility of transfer, and finally plan the latest departure route for the user from Beijing to Shanghai Hongqiao Station via Nanjing South Station.

[0146] In some embodiments, the transit itinerary planned for the user may include multiple transit itineraries planned in parallel based on a first reasoning mode or a second reasoning mode to meet the user's travel intentions. For example, an AI program might simultaneously find multiple feasible routes, such as those via Nanjing or Hefei, each with potentially different time combinations. The key to improving user experience lies in selecting the optimal solution from these results that best meets user expectations.

[0147] To address this situation, a tiered filtering mechanism can be provided. Based on this tiered filtering mechanism, the AI ​​service program can first identify target transit itineraries among the aforementioned multiple transit itineraries that include sub-itineraries with a transit type of same-station transit.

[0148] For example, all planned transfer routes can be analyzed to identify whether each sub-trip within each transfer route is a same-station transfer. If a transfer route has at least one sub-trip with a same-station transfer type, then the route can be marked as a "target transfer route".

[0149] Secondly, if the above multiple transit trips include a target transit trip with a transit type of same-station transit, then this target transit trip can be displayed to the user as the optimal transit trip.

[0150] Since same-station transfers do not require switching between different stations, the risk of transfers is low and the user experience is good. Prioritizing the display of such options allows for more efficient recommendation of the best choice to users, eliminating the need for them to painstakingly filter through a large number of ordinary options. When displaying options, the system can sort multiple same-station transfer options according to parameters such as the number of transfers, total travel time, and total fare.

[0151] Of course, if the multiple transit trips do not include transit trips with the transit type of same-station transit, that is, all routes must involve inter-station transfers, then the above-mentioned artificial intelligence service program can activate the adaptation scoring mechanism to calculate the adaptation score corresponding to the multiple transit trips respectively.

[0152] Specifically, the fit score can be used to represent the degree of fit with the user's travel intentions. For example, in practical applications, the fit score can be a numerical value used to quantitatively assess the degree of match between each transit itinerary and the user's travel intentions.

[0153] In some embodiments, the fit score can be calculated by weighted summation based on evaluation results from multiple dimensions, including but not limited to: Total time: The total time spent traveling from the starting point to the destination. The shorter the time, the higher the score.

[0154] Total ticket price: The total cost of the trip. The lower the ticket price, the higher the score.

[0155] Departure time deviation: How close the trip's departure time is to the user's preferred departure time (if the user has provided their initial travel intention). The smaller the deviation, the higher the score.

[0156] Arrival Time Deviation: How close the arrival time of the trip is to the user's requested arrival time (if the user has provided a second travel intention). The smaller the deviation, the higher the score.

[0157] Comfort level: The comfort score is calculated by taking into account factors such as nighttime travel, number of transfers, and whether it is a red-eye flight.

[0158] User preferences: The more a user's preferences are matched, the higher the score; for example, user preferences could be a user's preferred mode of transportation.

[0159] In practical applications, each of the above dimensions can be assigned a weight coefficient according to its importance. The system multiplies the scores of each dimension by their weights and then sums them to obtain the final fit score.

[0160] After calculating the suitability scores for all transit routes, the target transit route with the highest suitability score can be selected as the optimal transit route and displayed to the user.

[0161] For example, in practical applications, all candidate routes can be sorted from high to low according to their suitability scores, and the top one or more target transit routes with the highest scores (e.g., the top 3) can be displayed to the user.

[0162] In this way, even when same-station transfer options are unavailable, the system can still recommend inter-station transfer options that best match the user's intentions, ensuring the relevance and high quality of the output results.

[0163] In the above technical solution, two reasoning modes are set up: a first reasoning mode (forward reasoning) and a second reasoning mode (backward reasoning). By recognizing the user's input travel demand information, the appropriate target reasoning mode can be automatically determined. When the user's intent is "earliest arrival," the forward reasoning mode is used, starting from the arrival time of the first sub-trip and reasoning backward. When the user's intent is "latest departure," the backward reasoning mode is used, starting from the departure time of the second sub-trip and reasoning backward.

[0164] In this way, not only can the two core travel needs of users, "arriving early" and "leaving late", be met at the same time, but the automatic mapping from "user intent" to "computation mode" can also be achieved without the need for users to make complicated condition settings, which significantly improves the intelligence level of trip planning and user experience.

[0165] In addition, this application calculates the buffer time from the target station to the next transfer station in real time during the planning of the transfer itinerary. The calculation of this buffer time is not a fixed value, but is dynamically calculated based on multiple dimensions of parameters such as transfer type (same station transfer or different station transfer), station characteristics (exit time allowance, entry time allowance), travel time (local transportation time), and whether the travel time is within a preset time period (such as mealtime).

[0166] By quantifying and incorporating various real-world factors that may affect time consumption in transfer scenarios into the calculation model, the estimated transfer time becomes closer to the actual situation. This effectively avoids the risks of missing trains or flights due to inaccurate time estimates, or the waste of user time caused by ineffective waiting, significantly improving the feasibility of trip planning and user trust in the planning results.

[0167] Furthermore, after planning multiple transfer routes that meet the user's travel intentions, this application can further filter and sort the route results. Specifically, it can prioritize identifying and output target transfer routes that include same-station transfer sub-routes. Since same-station transfers do not require switching between different stations, the user experience is better and the risk of transfer failure is lower. Therefore, prioritizing the display of such options to the user allows for more efficient recommendation of the optimal choice. When no same-station transfer option exists, the system calculates the suitability score between each transfer route and the user's travel intentions, and displays the option with the highest suitability to the user. This hierarchical filtering mechanism considers both user experience and ensures the relevance and high quality of the final output results.

[0168] Finally, after determining the target reasoning pattern, this application utilizes a graph database to perform graph search to query transit paths from the origin to the destination. Graph databases can efficiently store and query the topological relationships between stations, transforming the path search problem into a pathfinding problem in graph theory, significantly improving search efficiency in complex networks.

[0169] Corresponding to the embodiments of the methods described above, this specification also provides embodiments of devices, electronic devices, and storage media.

[0170] Figure 4 This is a schematic structural diagram of a device provided in an exemplary embodiment. For example... Figure 4 As shown, device 300 mainly consists of a communication interface 302, a user interface 304, a processor 306, and a data storage 308. These components are interconnected and communicate with each other via a system bus, network, or other connection mechanism 310. The communication interface 302 enables device 300 to communicate with other devices, access networks, and transmission networks via analog or digital modulation. For example, the communication interface 302 may include a chipset and antenna for wireless communication with a radio access network or access point. Furthermore, the communication interface 302 can be a wired interface such as Ethernet, Token Ring, or a USB port, or a wireless interface such as Wi-Fi, Bluetooth, Global Positioning System (GPS), or a wide-area wireless interface (e.g., WiMAX or LTE). Of course, the communication interface 302 can also support other forms of physical layer interfaces and standard or proprietary communication protocols. The communication interface 302 may also include multiple physical communication interfaces, such as Wi-Fi, Bluetooth, and wide-area wireless interfaces.

[0171] User interface 304 includes receiving user input and providing output to the user. Therefore, user interface 304 may include input components such as a keypad, keyboard, touch-sensitive or presence-sensitive panel, computer mouse, trackball, joystick, microphone, still camera, and video camera, and output components such as a display screen (which may be combined with a touch-sensitive panel), CRT, LCD, LED, display using DLP technology, printer, and other similar devices known or developed in the future. User interface 304 may also generate auditory output via speakers, speaker jacks, audio output ports, audio output devices, headphones, and other similar devices known or developed in the future. In some embodiments, user interface 304 may include software, circuitry, or other forms of logic capable of transmitting and receiving data from external user input / output devices. Additionally or alternatively, device 300 may support remote access from other devices via communication interface 302 or another physical interface (not shown). User interface 304 may be configured to receive user input, the position and movement of which may be indicated by indicators or cursors described herein. User interface 304 may also be configured as a display device for rendering or displaying text fragments.

[0172] Processor 306 may contain one or more general-purpose processors and / or special-purpose processors.

[0173] Data storage 308 may include one or more volatile and / or non-volatile storage components and may be integrated wholly or partially with processor 306. Data storage 308 may include removable and non-removable components.

[0174] Processor 306 is capable of executing program instructions 318 (e.g., compiled or uncompiled program logic and / or machine code) stored in data storage 308 to perform the various functions described herein. Data storage 308 may contain a non-transitory computer-readable medium on which program instructions are stored, which, when executed by device 300, enable device 300 to perform any methods, processes, or functions disclosed in this specification and / or the accompanying drawings. Execution of program instructions 318 by processor 306 may result in processor 306 using data 312.

[0175] For example, program instructions 318 may include an operating system 322 (e.g., an operating system kernel, device drivers, and / or other modules) installed on device 300 and one or more applications 320 (e.g., a browser, social application, or game application). Similarly, data 312 may include operating system data 316 and application data 314. Operating system data 316 is primarily accessible to the operating system 322, while application data 314 is primarily accessible to one or more applications 320. Application data 314 may reside in a file system visible or hidden from the user of device 300.

[0176] Application 320 can communicate with operating system 322 through one or more application programming interfaces (APIs). These APIs help application 320 read and / or write application data 314, transmit or receive information via communication interface 302, receive or display information on user interface 304, etc.

[0177] In some terminology, application 320 may be simply referred to as "app". Furthermore, application 320 can be downloaded to device 300 through one or more online app stores or app markets. However, applications can also be installed on device 300 in other ways, such as through a web browser or a physical interface on device 300 (e.g., a USB port).

[0178] like Figure 4 As shown, Figure 4 This specification is a block diagram illustrating a transit itinerary planning device according to an exemplary embodiment. This device can operate as an LLM-based artificial intelligence service program deployed on a travel service platform, such as... Figure 3The electronic device shown implements the technical solution of this specification. The artificial intelligence service program supports multiple reasoning modes to plan transit routes for users; the transit routes include multiple sub-trips using different modes of transportation; the multiple reasoning modes include a first reasoning mode that, starting from the arrival time of a sub-trip satisfying the user's travel intention, reasones along the positive direction of the time axis to deduce the next sub-trip satisfying the user's travel intention; and a second reasoning mode that, starting from the departure time of a sub-trip satisfying the user's travel intention, reasones along the negative direction of the time axis to deduce the previous sub-trip satisfying the user's travel intention; the device includes: The acquisition module 301 acquires travel demand information input by the user and performs intent recognition on the travel demand information to determine the user's travel intent; The determination module 302 determines a target reasoning pattern for planning a transit itinerary for the user from the multiple reasoning patterns based on the user's travel intention; The planning module 303, if the target reasoning mode is the first reasoning mode, queries the trip database for sub-trips that satisfy the user's travel intention, and, starting from the arrival time of the sub-trip, reasons out the next sub-trip that satisfies the user's travel intention along the positive direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user; if the target reasoning mode is the second reasoning mode, queries the trip database for sub-trips that satisfy the user's travel intention, and, starting from the departure time of the sub-trip, reasons out the previous sub-trip that satisfies the user's travel intention along the negative direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user.

[0179] Accordingly, this specification also provides an electronic device including a processor; a memory for storing processor-executable instructions; wherein the processor is configured to implement all the steps in the previously described method flow.

[0180] Accordingly, this specification also provides a computer-readable storage medium having stored thereon executable computer program instructions; wherein, when executed by a processor, the instructions implement all the steps in the previously described method flow.

[0181] Accordingly, this specification also provides a computer program product having executable computer program instructions stored thereon; wherein, when the computer program instructions are executed by a processor, they implement all the steps in the previously described method flow.

[0182] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or physical entities, or by products with certain functions. A typical implementation device is a server system. Of course, it is not excluded that with the future development of computer technology, the computer implementing the functions of the above embodiments can be, for example, a personal computer, a laptop computer, an in-vehicle human-machine interaction device, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or any combination of these devices.

[0183] While one or more embodiments of this specification provide the operational steps of the methods described in the embodiments or flowcharts, more or fewer operational steps may be included based on conventional or non-inventive means. The order of steps listed in the embodiments is merely one possible order of execution among many steps and does not represent the only possible order. In actual device or end product execution, the methods shown in the embodiments or drawings may be executed sequentially or in parallel (e.g., in a parallel processor or multi-threaded processing environment, or even a distributed data processing environment). The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, product, or apparatus 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, method, product, or apparatus. Without further limitations, it is not excluded that the process, method, product, or apparatus that includes said elements may also have other identical or equivalent elements. For example, the use of terms such as "first," "second," etc., is used to denote names and does not indicate any particular order.

[0184] For ease of description, the above devices are described in terms of function, divided into various modules. Of course, when implementing one or more of these specifications, the functions of each module can be implemented in one or more software and / or hardware components, or a module that performs the same function can be implemented by a combination of multiple sub-modules or sub-units. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between devices or units, and may be electrical, mechanical, or other forms.

[0185] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0186] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0187] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0188] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.

[0189] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.

[0190] Computer-readable media includes both permanent and non-permanent media. Information storage can be achieved by any method or technology, whether removable or non-removable. Information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage, graphene storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0191] Those skilled in the art will understand that one or more embodiments of this specification can be provided as a method, system, or computer program product. Therefore, one or more embodiments of this specification can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of this specification can take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0192] One or more embodiments of this specification can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. One or more embodiments of this specification can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In a distributed computing environment, program modules can reside in local and remote computer storage media, including storage devices.

[0193] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, system embodiments are basically similar to method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments. In the description of this specification, the terms "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this specification. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described can be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.

[0194] The above description is merely an embodiment of one or more embodiments of this specification and is not intended to limit the scope of this specification. Various modifications and variations can be made to the one or more embodiments of this specification by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims.

Claims

1. A transit itinerary planning method, applied to an AI service program based on LLM deployed on a travel service platform; wherein, The AI ​​service program supports multiple reasoning modes to plan transit itineraries for users; the transit itinerary includes multiple sub-trips using different modes of transportation; the multiple reasoning modes include a first reasoning mode that starts from the arrival time of the sub-trip that satisfies the user's travel intention and reasones along the forward direction of the time axis to derive the next sub-trip that satisfies the user's travel intention; and a second reasoning mode that starts from the departure time of the sub-trip that satisfies the user's travel intention and reasones along the reverse direction of the time axis to derive the previous sub-trip that satisfies the user's travel intention; the method includes: Obtain travel demand information input by the user, and perform intent recognition on the travel demand information to determine the user's travel intent; Based on the user's travel intention, a target reasoning pattern is determined from the multiple reasoning patterns to plan the transit itinerary for the user; If the target reasoning mode is the first reasoning mode, query the trip database for sub-trips that satisfy the user's travel intention, and starting from the arrival time of the sub-trip, reason out the next sub-trip that satisfies the user's travel intention along the positive direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user. If the target reasoning mode is the second reasoning mode, query the user's travel intention sub-trip from the trip database, and starting from the departure time of the sub-trip, reason out the previous sub-trip that satisfies the user's travel intention along the reverse direction of the time axis, and so on, until at least one transit trip that satisfies the user's travel intention is planned for the user.

2. The method according to claim 1, wherein the user's travel intention includes a first travel intention in which the user indicates a departure time and a second travel intention in which the user indicates an arrival time; Based on the user's travel intention, a target inference pattern is determined from the multiple inference patterns to plan a transit itinerary for the user, including: Identify the type of the user's travel intention; If the user's travel intention is the first travel intention, the first reasoning mode is determined as the target reasoning mode for planning the transit itinerary for the user; If the user's travel intention is the second travel intention, the second reasoning mode is determined as the target reasoning mode for planning the user's transit itinerary.

3. The method according to claim 2, wherein the travel demand information includes the user-specified departure point and destination; The method further includes: After determining the target reasoning pattern for planning transit routes for the user from the multiple reasoning patterns, a graph search is performed in the graph database to query transit paths from the user's specified departure point to the destination; wherein, nodes in the graph data represent stations; edges in the graph data represent transit relationships between stations; the transit path includes a starting station corresponding to the departure point, at least one transit station, and a destination station corresponding to the destination.

4. The method according to claim 3, wherein if the target reasoning mode is the first reasoning mode, sub-trips that satisfy the user's travel intention are queried from the trip database, and the next sub-trip that satisfies the user's travel intention is reasoned out along the positive direction of the time axis, starting from the arrival time of the sub-trip, and so on, until a transit trip that satisfies the user's travel intention is planned, including: If the target reasoning mode is the first reasoning mode, query the first travel flight with a departure time after the user-indicated departure time from the travel flight information corresponding to the starting station stored in the travel database. Generate a first sub-trip based on the first travel flight. Starting from the arrival time of the first sub-trip, calculate in real time the first buffer time from the starting station to the next transfer station on the transfer path. Query the second travel flight with a departure time after the target time obtained by delaying the arrival time of the first sub-trip by the first buffer time from the travel flight information corresponding to the next transfer station stored in the travel database. Generate a second sub-trip based on the second travel flight. Continue this process until a transfer trip that satisfies the user's travel intentions is planned. If the target reasoning mode is the second reasoning mode, the system queries the trip information corresponding to the destination station stored in the trip database for the first trip whose arrival time is before the arrival time indicated by the user. Based on the first trip, a first sub-trip is generated. Starting from the departure time of the first sub-trip, the system calculates in real time the first buffer time from the destination station to the destination station from the previous transfer node on the transfer path. The system also queries the trip information corresponding to the previous transfer station stored in the trip database for the second trip whose arrival time is before the target time obtained by delaying the departure time of the first sub-trip forward by the first buffer time. Based on the second trip, a second sub-trip is generated. This process continues until a transfer trip that meets the user's travel intentions is planned.

5. The method according to claim 4, comprising calculating in real time the buffer time from any target station on the transit path to the next transit station on the transit path, including: Identify the transit type from any target station on the transit path to the next transit station on the transit path; wherein, the transit type includes same-station transit and different-station transit; If the transit type is same-station transit, the pre-configured same-station transit reservation time from the target station to the next transit station is obtained in real time and used as a buffer time from the target station to the next transit station; If the transit type is inter-station transit, the pre-configured outbound reserved time corresponding to the target station and the inbound reserved time corresponding to the next transit station are obtained in real time, and the travel time from the target station to the next transit station is calculated in real time. The outbound reserved time, the inbound reserved time and the travel time are added together to obtain the buffer time from the target station to the next transit station.

6. The method according to claim 5, wherein if the transit type is intra-station transit, real-time acquisition of a pre-configured intra-station transit reservation time from the target station to the next transit station, as a buffer time from the target station to the next transit station, includes: If the transit type is same-station transit, the pre-configured same-station transit reserved time from the target station to the next transit station is obtained in real time, and it is determined whether the travel time from the target station to the next transit station is a preset time period; wherein, the preset time period is bound to an additional reserved time period; If the travel time from the target station to the next transit station is a preset time period, the reserved transit time at the same station and the additional reserved time period bound to the preset time period are added together to obtain the buffer time from the target station to the next transit station.

7. The method according to claim 6, wherein if the transit type is inter-station transit, the pre-configured outbound reserved time corresponding to the target station and the inbound reserved time corresponding to the next transit station are obtained in real time, and the travel time from the target station to the next transit station is calculated in real time, and the outbound reserved time, the inbound reserved time and the travel time are accumulated to obtain the buffer time from the target station to the next transit station, including: If the transit type is inter-station transit, the pre-configured outbound reserved time corresponding to the target station and the inbound reserved time corresponding to the next transit station are obtained in real time, and the travel time from the target station to the next transit station is calculated in real time, and it is determined whether the travel time from the target station to the next transit station is a preset time period; wherein, the preset time period is bound to an additional reserved time period; If the travel time from the target station to the next transit station is a preset time period, the exit reservation time, the entry reservation time, the travel time, and the additional reservation time bound to the preset time period are added together to obtain the buffer time from the target station to the next transit station.

8. The method according to claim 7, wherein the at least one transit itinerary includes multiple transit itineraries planned in parallel for the user based on the first inference mode or the second inference mode to satisfy the user's travel intention; The method further includes: Identify a target transit itinerary that includes sub-transfer types of same-station transfers among the multiple transit itineraries; If the multiple transit trips include a target transit trip with a transit type of same-station transit, the target transit trip will be output and displayed to the user.

9. The method according to claim 8, further comprising: If none of the multiple transit itineraries contain a sub-itin with a transit type of same-station transit, calculate the suitability score corresponding to each of the multiple transit itineraries; wherein, the suitability score represents the degree of suitability with the user's travel intention; The user will be presented with at least one target transit trip that has the highest fit rating.

10. The method according to claim 1, wherein the LLM-based artificial intelligence service program includes an LLM-based intelligent agent.

11. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 10.

12. A computer program product comprising a computer program that, when executed by a processor, implements the steps of the method of any one of claims 1 to 10.