Itinerary recommendation method and device, platform and storage medium

By identifying and standardizing the semantic elements in user statements, recommended itineraries are determined and pushed, solving the problem that life service platforms cannot plan multiple events, and realizing intelligent recommendation and travel arrangement for multiple events.

CN117216400BActive Publication Date: 2026-06-09CHINA CONSTRUCTION BANK +1

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA CONSTRUCTION BANK
Filing Date
2023-09-26
Publication Date
2026-06-09

Smart Images

  • Figure CN117216400B_ABST
    Figure CN117216400B_ABST
Patent Text Reader

Abstract

This application provides a method, apparatus, platform, and storage medium for trip recommendation, relating to the field of artificial intelligence technology. First, it acquires a user statement in a preset format and identifies the semantic elements contained within the user statement. Each semantic element includes at least one location element or one event element. Then, it determines the element set corresponding to the semantic elements according to a preset set format, obtaining a set of elements to be processed. The elements in this set are then normalized to obtain a target element set, where the elements in the preset set sequentially include time, location, direction, and event. Next, it determines recommended trips for each trip in the user statement based on the target element set, and pushes each recommended trip to the user according to the timeline between them. Based on the user-provided user statement, it provides complete trip recommendations for multiple events, facilitating user travel planning and enhancing the intelligence of the life service platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of artificial intelligence technology, and in particular to a method, apparatus, platform and storage medium for trip recommendation. Background Technology

[0002] Current lifestyle service platforms only allow single-event searches and cannot provide users with multi-event travel planning. Furthermore, searches are limited to fixed locations, such as subway lines or shopping districts. This application aims to provide users with comprehensive multi-event travel planning to facilitate their travel arrangements. Summary of the Invention

[0003] This application provides a trip recommendation method, device, platform, and storage medium for providing users with comprehensive trip planning for multiple events to facilitate their travel arrangements.

[0004] Firstly, this application provides a method for recommending itineraries, including:

[0005] Obtain user statements with a preset statement format, identify the semantic elements contained in the user statements, and the semantic elements include at least one location element or one event element;

[0006] The element set corresponding to the semantic element is determined according to the format of the preset set to obtain the element set to be processed, and the elements in the element set to be processed are normalized to obtain the target element set. The elements in the preset set include time, location, orientation and event in sequence.

[0007] Based on the target element set, a recommended trip is determined for each trip in the user statement, and each recommended trip is pushed to the user according to the timeline between each recommended trip.

[0008] In one possible design, after pushing each recommended trip to the user according to the timeline between each recommended trip, the following is also included:

[0009] The system obtains multiple modes of transportation and the corresponding travel time for each mode of transportation between adjacent trips in each recommended trip, and pushes each mode of transportation and its corresponding travel time to the user.

[0010] In one possible design, after determining the recommended trip for each trip in the user statement based on the target element set, the method further includes:

[0011] Obtain candidate trips corresponding to each recommended trip and push each candidate trip to the user. When a candidate trip is selected as a recommended trip, the subsequent trips of the selected candidate trip will automatically switch following the selected candidate trip.

[0012] In one possible design, identifying the semantic elements contained in the user statement includes:

[0013] The intent recognition model sequentially identifies the time statement, location statement, and event statement contained in the user's statement;

[0014] Extract the time nouns from the time statement to obtain the time element of the semantic element;

[0015] Extract the location nouns and / or directional words from the location statement to obtain the location element of the semantic element;

[0016] Extract the event verbs from the event terms to obtain the event elements of the semantic elements;

[0017] The user language shall include at least one location statement or one event statement.

[0018] In one possible design, determining the element set corresponding to the semantic element according to a preset set format to obtain the element set to be processed includes:

[0019] The time element, location element, and event element in the semantic elements are sequentially filled into the preset set to obtain the set of elements to be processed;

[0020] If any one of the time element, the location element, and the event element is absent, the current element position in the preset set is left empty.

[0021] In one possible design, the normalization process of the elements in the set of elements to be processed to obtain the target set of elements includes:

[0022] Identify whether each set of elements to be processed contains only time-related elements;

[0023] If not, the time elements in each set of elements to be processed are converted to standard time according to the time period correspondence table, and the location elements and orientation elements in each set of elements to be processed are filtered and merged, and the processed set of elements to be processed is determined as the corresponding target element set.

[0024] If so, delete the current set of elements to be processed.

[0025] In one possible design, determining the recommended trip for each trip in the user statement based on the target element set includes:

[0026] Based on the corresponding locations contained in the location elements and the corresponding events contained in the event elements in the first target element set, search the map library to find candidate locations for the first trip of the user's terminology;

[0027] The corresponding time contained in the time element of the first target element set is matched with the opening time of the candidate locations of the first itinerary to obtain the recommended locations and recommended times of the first itinerary;

[0028] Based on the corresponding events contained in the elements of the events in the first set of target elements, the recommended location and recommended time of the first trip, the recommended itinerary of the first trip is obtained;

[0029] Based on the set of subsequent target elements and the recommended itinerary of the first itinerary, the recommended itinerary for subsequent itineraries after the first itinerary is determined, thus obtaining the recommended itinerary for each itinerary.

[0030] In one possible design, after obtaining the recommended itinerary for each itinerary, the process further includes:

[0031] If the number of recommended trips is less than the preset number of trips, a continuation trip of the recommended trips is generated based on the user's historical behavior and the behavior recommendation model;

[0032] The extended itinerary is pushed to the user according to the timeline between the recommended itinerary and the extended itinerary.

[0033] In one possible design, the intent recognition model includes at least one of the NER model, the large model, and the word segmentation model.

[0034] Secondly, this application provides a trip recommendation device, comprising:

[0035] The first processing module is used to acquire user statements in a preset statement format and identify the semantic elements contained in the user statements, wherein the semantic elements include at least one location element or one event element.

[0036] The second processing module is used to determine the element set corresponding to the semantic element according to the format of the preset set, to obtain the element set to be processed, and to perform normalization processing on the elements in the element set to be processed to obtain the target element set. The elements in the preset set include time, location, orientation and event in sequence.

[0037] The third processing module is used to determine the recommended trip for each trip in the user statement based on the target element set, and to push each recommended trip to the user according to the timeline between each recommended trip.

[0038] In one possible design, the third processing module is further configured to:

[0039] The system obtains multiple modes of transportation and the corresponding travel time for each mode of transportation between adjacent trips in each recommended trip, and pushes each mode of transportation and its corresponding travel time to the user.

[0040] In one possible design, the third processing module is further configured to:

[0041] Obtain candidate trips corresponding to each recommended trip and push each candidate trip to the user. When a candidate trip is selected as a recommended trip, the subsequent trips of the selected candidate trip will automatically switch following the selected candidate trip.

[0042] In one possible design, the first processing module is specifically used for:

[0043] The intent recognition model sequentially identifies the time statement, location statement, and event statement contained in the user's statement;

[0044] Extract the time nouns from the time statement to obtain the time element of the semantic element;

[0045] Extract the location nouns and / or directional words from the location statement to obtain the location element of the semantic element;

[0046] Extract the event verbs from the event terms to obtain the event elements of the semantic elements;

[0047] The user language shall include at least one location statement or one event statement.

[0048] In one possible design, the second processing module is specifically used for:

[0049] The time element, location element, and event element in the semantic elements are sequentially filled into the preset set to obtain the set of elements to be processed;

[0050] If any one of the time element, the location element, and the event element is absent, the current element position in the preset set is left empty.

[0051] In one possible design, the second processing module is further configured to:

[0052] Identify whether each set of elements to be processed contains only time-related elements;

[0053] If not, the time elements in each set of elements to be processed are converted to standard time according to the time period correspondence table, and the location elements and orientation elements in each set of elements to be processed are filtered and merged, and the processed set of elements to be processed is determined as the corresponding target element set.

[0054] If so, delete the current set of elements to be processed.

[0055] In one possible design, the third processing module is further configured to:

[0056] Based on the corresponding locations contained in the location elements and the corresponding events contained in the event elements in the first target element set, search the map library to find candidate locations for the first trip of the user's terminology;

[0057] The corresponding time contained in the time element of the first target element set is matched with the opening time of the candidate locations of the first itinerary to obtain the recommended locations and recommended times of the first itinerary;

[0058] Based on the corresponding events contained in the elements of the events in the first set of target elements, the recommended location and recommended time of the first trip, the recommended itinerary of the first trip is obtained;

[0059] Based on the set of subsequent target elements and the recommended itinerary of the first itinerary, the recommended itinerary for subsequent itineraries after the first itinerary is determined, thus obtaining the recommended itinerary for each itinerary.

[0060] In one possible design, the trip recommendation device further includes: a fourth processing module; the fourth processing module is used for:

[0061] If the number of recommended trips is less than the preset number of trips, a continuation trip of the recommended trips is generated based on the user's historical behavior and the behavior recommendation model;

[0062] The extended itinerary is pushed to the user according to the timeline between the recommended itinerary and the extended itinerary.

[0063] In one possible design, the intent recognition model includes at least one of the NER model, the large model, and the word segmentation model.

[0064] Thirdly, this application provides a life service platform, including: a processor, and a memory communicatively connected to the processor;

[0065] The memory stores computer-executed instructions;

[0066] The processor executes computer execution instructions stored in the memory to implement any of the possible trip recommendation methods provided in the first aspect.

[0067] Fourthly, this application provides a computer-readable storage medium storing computer-executable instructions, which, when executed by a processor, are used to implement any of the possible route recommendation methods provided in the first aspect.

[0068] Fifthly, this application provides a computer program product including computer execution instructions, which, when executed by a processor, are used to implement any of the possible route recommendation methods provided in the first aspect.

[0069] This application provides a method, apparatus, platform, and storage medium for trip recommendation. First, it acquires a user statement in a preset format and identifies the semantic elements contained within the user statement. Each semantic element includes at least one location element or one event element. Then, it determines the element set corresponding to the semantic elements according to a preset set format, obtaining a set of elements to be processed. The elements in this set are then normalized to obtain a target element set, where the elements in the preset set sequentially include time, location, direction, and event. Next, it determines recommended trips for each trip in the user statement based on the target element set, and pushes each recommended trip to the user according to the timeline between them. Based on the user-provided user statement, it provides complete trip recommendations for multiple events, facilitating user travel planning and enhancing the intelligence of the lifestyle service platform. Attached Figure Description

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

[0071] Figure 1 This is a schematic diagram of an application scenario provided by an embodiment of this application;

[0072] Figure 2 A flowchart illustrating a trip recommendation method provided in an embodiment of this application;

[0073] Figure 3 A flowchart illustrating another itinerary recommendation method provided in an embodiment of this application;

[0074] Figure 4 A flowchart illustrating another itinerary recommendation method provided in an embodiment of this application;

[0075] Figure 5 A flowchart illustrating yet another itinerary recommendation method provided in an embodiment of this application;

[0076] Figure 6 This is a schematic diagram of the structure of a trip recommendation device provided in an embodiment of this application;

[0077] Figure 7 A schematic diagram of another trip recommendation device provided in an embodiment of this application;

[0078] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation

[0079] 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 numbers in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this application. Rather, they are merely examples of methods and apparatus consistent with some aspects of this application as detailed in the appended claims.

[0080] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented, for example, in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0081] The collection, storage, use, processing, transmission, provision, and disclosure of financial data, user data, or business reports involved in the technical solution of this application all comply with the provisions of relevant laws and regulations and do not violate public order and good morals.

[0082] Current lifestyle service platforms only allow single-event searches and cannot provide users with multi-event itinerary planning. Furthermore, they can only search for events centered around fixed locations, such as subway lines or shopping districts. Therefore, they cannot plan complete itineraries involving multiple events.

[0083] To address the aforementioned problems in the existing technology, this application provides a trip recommendation method, apparatus, platform, and storage medium. The inventive concept of the trip recommendation method provided in this application is as follows: First, a user statement in a preset format is obtained, that is, the user inputs a travel plan according to the preset format. Then, semantic elements contained in the user statement are identified based on an intent recognition model, and these semantic elements are sequentially filled into a preset set, thereby processing the user statement into a corresponding set, obtaining a set of elements to be processed. The elements in the set of elements to be processed are then standardized to obtain a set of target elements. The user statement may include multiple trips, and the user statement describing each trip is processed into a corresponding set of target elements. Then, a recommended trip is determined for each trip in the user statement based on the set of target elements, and each recommended trip is pushed to the user according to the timeline between each recommended trip. This achieves simultaneous planning of multiple trips included in the user statement, providing users with complete trip recommendations for multiple events, facilitating travel arrangements, and improving the intelligence level of the life service platform.

[0084] Figure 1 This is a schematic diagram illustrating an application scenario provided by an embodiment of this application. For example... Figure 1 As shown, the life service platform 100 is configured to execute the itinerary recommendation method provided in this application embodiment. The user terminal 200 is the client of the itinerary recommendation method provided in this application embodiment. For example, the itinerary recommendation method is configured as an application, the life service platform 100 is the server of the application, and the user terminal 200 is the client of the application. The user logs in to the application and enters a user statement on the application interface. The user statement must conform to a preset statement format. The life service platform 100 obtains the user's words in the preset statement format, identifies the semantic elements contained in the user statement, and determines the element set corresponding to the semantic elements according to the format of the preset set to obtain the element set to be processed. Then, it normalizes the elements in the element set to be processed to obtain the target element set. Then, it determines the recommended itinerary for each itinerary in the user statement according to the target element set, and pushes each recommended itinerary to the user terminal 200 according to the timeline between each recommended itinerary, so as to realize the simultaneous planning of multiple itineraries included in the user statement, thereby completing the multi-event complete itinerary recommendation and facilitating the user's travel arrangements.

[0085] Understandably, the life service platform 100 runs on devices such as servers, server clusters, computers, and laptops, while the user terminal 200 can be a smartphone, smart wearable device, tablet, or other terminal. Figure 1 The life service platform 100 in the example is run on a computer. Figure 1 The user terminal 200 in this embodiment is illustrated using a smartphone as an example. This application does not limit the device type of the life service platform 100 or the user terminal 200.

[0086] Figure 2 This is a flowchart illustrating a trip recommendation method provided in an embodiment of this application. Figure 2 As shown, the itinerary recommendation method provided in this application includes:

[0087] S101: Retrieve user statements with preset statement formats.

[0088] User statements can be text or voice input by the user, but the statement format must conform to the preset statement format.

[0089] The preset statement format is Time1Location1Event1, Time2Location2Event2, ..., TimeNLocationNEventN, where N is the maximum number of trips that the trip recommendation method provided in this application embodiment can recommend based on multiple events. The order of the trips cannot be confused and is specifically determined by the data processing capabilities of the hardware, software, etc., executing the trip recommendation method. This application embodiment does not limit the value of N. For example, Time1Location1Event1 means performing Event1 at the location indicated by Location1 at the time indicated by Time1, which constitutes one trip. The time, location, and event in a trip can be empty. The user statement must include at least one location statement or one event statement, that is, the user statement must include at least one statement representing a location or one statement representing an event.

[0090] For example, user statements could be "Go to the library area to watch a movie the day after tomorrow afternoon and then eat Cantonese food in the evening", "Hot pot", or "Eat hot pot and then go to watch a movie".

[0091] S102: Identify the semantic elements contained in the user's statement.

[0092] Based on the intent recognition model, the user's statement is used to identify semantic elements, which can be time elements, location elements, and event elements. Time-related terms in the user's statement include time elements, location-related terms include location elements, and event-related terms include event elements.

[0093] In one possible design, step S102 could be implemented as follows: Figure 3 As shown. Figure 3 This is a flowchart illustrating another itinerary recommendation method provided in an embodiment of this application. Figure 3 As shown, the embodiments of this application include:

[0094] S1021: The intent recognition model sequentially identifies the time statement, location statement, and event statement contained in the user's statement.

[0095] The intent recognition model identifies the text or speech corresponding to the user's statement, and then identifies statements indicating time, location, and event.

[0096] S1022a: Extract time nouns from time statements to obtain the time elements of semantic elements.

[0097] Extract the nouns that indicate time from the time statement to obtain the time element.

[0098] S1022b: Extract location nouns and / or directional words from location statements to obtain the location elements of semantic elements.

[0099] Extract the nouns that indicate location and / or the directional words that indicate the location from the location statement to obtain the location elements.

[0100] S1022c: Extract the event verbs from the event terms to obtain the event elements of semantic elements.

[0101] The process involves extracting verbs from event terminology that indicate the method of achieving the event, resulting in event verbs. Then, event elements are identified from the events that the verbs connect to. The reason for not directly extracting event nouns in event element identification is to ensure that when a noun without a preceding verb is identified, it is recognized as a time or location element rather than an event element. This has two advantages: first, it facilitates subsequent itinerary recommendations; for example, even if an event element is mistakenly searched as a location element, the impact on search results is minimal, but if a location element is mistakenly searched as an event element, the search results are poor. Second, users' language habits tend to predominantly include verbs before events, which helps the intent recognition model identify event elements.

[0102] Optionally, the intent recognition model used in the embodiments of this application may include at least one of NER models, large models, and word segmentation models. NER models are a natural language processing (NLP) technique used to identify and classify named entities from text. Named entities refer to words or phrases with specific meanings, such as names of people, places, organizations, dates, numbers, etc. The purpose of NER models is to label these entities and classify them into predefined categories for subsequent analysis or application. Large models refer to artificial neural network models with a very large number of parameters; they typically have stronger expressive power and higher accuracy, but also require more computational resources and time.

[0103] Large models have wide applications in the field of Natural Language Processing (NLP), such as text generation, question answering systems, and machine translation.

[0104] When using the NER model, it is necessary to train on pre-labeled corpus data.

[0105] When using a large model, provide a suitable prompt, such as: "Please extract the time nouns, place nouns, and event verbs from the following sentence in order. I expect the event verbs to represent a complete event, and when there is only one word, identify it as a place noun." For example, semantic elements obtained using a large model could be: "The day after tomorrow afternoon (time element) near the Military Museum (place element) watch a movie (event element) then in the evening (time element) eat Cantonese food (event element)", "hot pot (place element)", "go to the area between Songjiazhuang and Qilizhuang (place element) eat hot pot (event element) then watch a movie (event element)".

[0106] Use a word segmentation model with part-of-speech recognition, such as jieba. You can segment event verbs and then extract event nouns based on their parts of speech; segment location nouns and extract various location and directional modifiers. Here, only one directional modifier is taken; if there are multiple, the first or last one can be used.

[0107] It is understood that a user statement includes at least one statement indicating a location or one statement indicating an event, and correspondingly, a semantic element includes at least one location element or one event element.

[0108] As described above, the intent recognition model identifies user language within a pre-defined sentence format, revealing the semantic elements contained within the user's statements. Specifically, by combining user language habits, event element identification is achieved through the recognition of event verbs, enabling more accurate search results to be returned in subsequent search phases and improving the accuracy of recommended itineraries.

[0109] S103: Determine the set of elements corresponding to the semantic elements according to the format of the preset set, and obtain the set of elements to be processed.

[0110] After completing the identification of semantic elements, the identified semantic elements are processed according to the format of a preset set to form an element set corresponding to the semantic elements. One trip corresponds to one element set, that is, one trip corresponds to one element set to be processed.

[0111] For example, the time element, location element, and event element in the semantic elements are sequentially filled into a preset set, and the resulting set is determined as the set of elements to be processed.

[0112] If any of the time element, location element, or event element is missing, the current element position in the preset set will be left empty.

[0113] For example, given the semantic elements "watching a movie near the Military Museum (location element) the day after tomorrow afternoon (time element), then eating Cantonese food in the evening (time element) (event element)," the time, location, and event elements are sequentially filled into a preset set, resulting in two sets. These two sets are the sets of elements to be processed. One set is {Time: the day after tomorrow afternoon, Location: {Noun: library, Location: nearby}, Event: movie}, and the other set is {Time: evening, Location: {Noun: [], Location: []}, Event: Cantonese food}.

[0114] The preset set is formatted as {time:} To be filled Location: {Noun:} To be filled locative words: To be filled}, Event: To be filled}.

[0115] The positions to be filled in the preset set are filled with the time element, location element and event element from the semantic elements. If any of them are not present, the position to be filled in the preset set is left empty, such as "Noun: [], Locative word: []" in the illustration.

[0116] S104: Normalize the elements in the set of elements to be processed to obtain the target set of elements.

[0117] The elements in the set of elements to be processed are normalized according to pre-set rules, such as data filtering, normalization of time elements, and location merging, so that the elements in the set of elements to be processed are normalized. After normalization of the set of elements to be processed, the target set of elements is obtained.

[0118] In one possible design, step S104 could be implemented as follows: Figure 4 As shown. Figure 4 A flowchart illustrating another itinerary recommendation method provided in this application embodiment is shown below. Figure 4 The embodiments shown in this application include:

[0119] S201: Identify whether each set of elements to be processed contains only time-related elements.

[0120] For each set of elements to be processed, identify the elements. If the set contains only time-related elements (i.e., location, orientation, and event are all empty), then the elements in the set are invalid, and step S202 is executed, i.e., the current set of elements to be processed is deleted. Otherwise, if not, i.e., the set of elements to be processed does not contain only time-related elements, then steps S203a and S203b are executed.

[0121] S202: Delete the current set of elements to be processed.

[0122] S203a: Convert the time elements in each set of elements to be processed to standard time according to the time period correspondence table.

[0123] For each set of elements to be processed, the time elements in the set of elements to be processed that are not left blank are numerated according to a pre-set time period correspondence table, so as to convert the time elements from text into standard time represented by numerical values.

[0124] For example, the time difference is divided into date time and hour time according to the rules. Elements such as "today, tomorrow, the day after tomorrow, the day after that, Monday to Sunday, [month and day], [day], etc." can be matched. The specific time represented by the element is then calculated based on the date, with a unified format of "month and day". Next, hour time is matched, including elements such as "morning, noon, afternoon, evening, etc." and "time [hour], [hour and minute]". A corresponding time period mapping table is set, such as: "morning: 6-9 am; morning: 9-11 am; noon: 11 am-2 pm; afternoon: 2 pm-6 pm; evening: 6 pm-10 pm". Finally, the time elements are converted into standard time points or time periods; for example, if the time element is "afternoon", it is converted to "14:00 or 14:00-15:00".

[0125] S203b: Filter and merge the location and orientation elements in each set of elements to be processed.

[0126] For each set of elements to be processed, for example, the elements representing location have fixed restrictions, such as only being able to use "East, South, West, North, Up, Down, Left, Right, Middle, Nearby". If an element representing location does not contain the set fixed keywords, that element is left blank. If an element representing location contains more than two nouns, it is determined whether the location element corresponds to "Middle". If not, the nouns of the multiple location elements are merged into one noun. Merging can be done by, for example, arbitrarily selecting one of the two or more nouns, or selecting the first one, etc.

[0127] S204: Each set of elements to be processed after processing is determined as the corresponding set of target elements.

[0128] For each set of elements to be processed, the data filtering, time element standardization, and location merging steps described above are completed, and each set of elements to be processed after processing is determined as the corresponding set of target elements.

[0129] The above steps achieve the normalization of elements in the set of elements to be processed, so as to search based on the elements in the obtained target set of elements to determine the recommended itinerary for each itinerary corresponding to the target set of elements.

[0130] S105: Determine the recommended itinerary for each trip in the user statement based on the target element set.

[0131] The system searches based on elements in the target element set and filters the results according to preset rules to determine the optimal search result. This optimal search result is then identified as the recommended trip for the current target element set. Each target element set corresponds to a trip within a user's statement, and based on each target element set, a recommended trip can be determined for each trip within that user statement.

[0132] A single user statement may include multiple trips, thus yielding multiple sets of target elements. Each set of target elements is arranged according to the trip order within the user statement. The search is performed first on the first set of target elements, and then the search results for subsequent sets of target elements are used as the basis for that search, ultimately resulting in the search results for each set of target elements.

[0133] In one possible design, step S105 could be implemented as follows: Figure 5 As shown, Figure 5 This is a flowchart illustrating another itinerary recommendation method provided in an embodiment of this application. Figure 5 As shown, the embodiments of this application include:

[0134] S301: Search the map library to find candidate locations for the user's first trip based on the corresponding locations contained in the location elements and the corresponding events contained in the event elements in the first target element set.

[0135] For the elements in the first set of target elements, the map library is first searched based on the location elements and event elements to determine the location of the first trip.

[0136] For example, if the location element contains only one corresponding location, the most matching location is found in the map database. The search result with the highest similarity to the desired location is the most matching location. If multiple locations with the same similarity are found, the locations are filtered by combining the corresponding events contained in the event element of the first target element set to determine the most matching location, which is then selected as a candidate location for the first trip. When combining the event element, if the event element is empty (i.e., the user's statement does not contain an event), it likely indicates that the user is searching for the location represented by the location element. In this case, multiple locations with the same similarity are retained, and their attributes can be identified, such as whether the location is a restaurant, hotel, or bookstore. Locations with the same attributes can be ranked according to other criteria such as distance or rating, and the location ranked first is determined as the most matching location. If the event element is not empty, then multiple locations with the same similarity are filtered based on the event element. The location that best matches the event contained in the event element is then determined as the candidate location for the first trip. It should be noted that the location and event can match in terms of attributes. For example, if the event is "eating" and the location is "restaurant," then they match.

[0137] If the location element contains multiple corresponding locations, and the event element is empty, the location with the center of latitude and longitude is taken as the candidate location for the first trip. If no location has a center of latitude and longitude, the user's terminal location is taken as the candidate location for the first trip. If the event element is not empty, multiple locations can be filtered by region by combining the location element with the location element indicating direction. For example, if the direction element is "nearby", then the location centered on the location indicated by the location element is considered "nearby" within a 2KM radius. Based on the location filtered by region, the event element is matched to determine the location that matches the event indicated by the event element as the candidate location for the first trip.

[0138] S302: Match the corresponding time contained in the time element of the first target element set with the opening time of the candidate locations of the first trip to obtain the recommended location and recommended time of the first trip.

[0139] The time represented by the time element in the first set of target elements is matched with the opening time of the previously determined candidate locations. The candidate locations with matching times are determined as recommended locations, and the opening time of the recommended locations is the recommended time.

[0140] Optionally, if the recommended location does not have an opening time, step S302 is skipped, and the time represented by the time element is the recommended time, and the candidate location becomes the recommended location. If the time element is empty, the candidate location becomes the recommended location, and the opening time of the recommended location becomes the recommended time. If the recommended location does not have an opening time, the time represented by the time element becomes the recommended time.

[0141] S303: Based on the corresponding events contained in the elements of the events in the first target element set, the recommended location of the first trip, and the recommended time, obtain the recommended itinerary for the first trip.

[0142] Steps S301 and S302 can be used to search for the recommended location and time of the first trip, and then combine the events of the first trip to obtain the recommended itinerary for the first trip. The events of the first trip are the corresponding events contained in the elements of the event set of the first target elements.

[0143] Thus, by completing the search for elements in the first target element set through steps S301 to S303, the recommended itinerary for the first trip contained in the user's statement has been determined.

[0144] S304: Based on the set of subsequent target elements and the recommended itinerary of the first itinerary, determine the recommended itinerary for subsequent itineraries after the first itinerary, and obtain the recommended itinerary for each itinerary.

[0145] The subsequent target element set is a collective term for all target element sets other than the first target element set. Specifically, searching for elements in the second target element set requires combining the recommended trips from the first trip; that is, searching for elements in subsequent target element sets requires combining the recommended trips corresponding to the target element sets listed before the current target element set.

[0146] For example, if the location elements in subsequent target element sets are not empty, the search for elements in the current target element set is the same as the search for elements in the first target element set to determine the recommended itinerary for the first trip. That is, the first target element set in steps S301 to S303 is replaced with the current target element set to determine the recommended itinerary for the trip corresponding to the current target element set, thus obtaining the recommended itinerary for each trip in the user statement. If the location elements in subsequent target element sets are empty, the recommended location of the recommended itinerary corresponding to the target element set arranged before the current target element set is used as the location represented by the element in the current target element set, so that the location elements are not empty, thus determining the recommended itinerary for the trip corresponding to the current target element set.

[0147] Through such Figure 5The steps shown can determine the recommended itinerary for each trip contained in the user's statement.

[0148] Furthermore, S106: Push each recommended trip to the user according to the timeline between each recommended trip.

[0149] After obtaining each recommended trip, the system connects them according to a timeline and pushes each connected trip to the user's device for display, thus completing the multi-event trip push. Users can then plan their schedules based on the displayed recommended trips.

[0150] Optionally, after step S105, the following may also be included:

[0151] S107a: Obtain multiple modes of transportation between adjacent trips in each recommended trip, as well as the corresponding travel time for each mode of transportation.

[0152] S107b: Push each mode of transportation and its corresponding travel time to the user.

[0153] To facilitate user travel, after pushing each recommended trip to the user, the system also obtains the transportation routes between each recommended trip and pushes these routes to the user to help them plan their trip. For example, it can obtain multiple modes of transportation between adjacent trips in each recommended trip, as well as the corresponding travel time for each mode of transportation, and then push each mode of transportation and its corresponding travel time to the user.

[0154] Optionally, after step S105, the following may also be included:

[0155] S108: Obtain the candidate itineraries corresponding to each recommended itinerary and push each candidate itinerary to the user.

[0156] For each recommended trip, corresponding candidate trips are also obtained. First, the candidate trips for the first recommended trip are obtained. Then, candidate trips for subsequent recommended trips are determined based on the first recommended trip and the subsequent recommended trips. For example, if a user statement contains trips A and B, and the recommended trips for the user statement are determined to be A1 and B1, then the candidate trip for A1 is first determined, for example, A2. Then, based on A2 and B1, the candidate trip for B1 is determined to be B2. In other words, adjacent candidate trips are related.

[0157] After obtaining the candidate trips corresponding to each recommended trip, the system pushes these candidate trips to the user according to their timelines. Users can manually select candidate trips as recommended trips. When a candidate trip is selected as a recommended trip, its subsequent trips will automatically switch accordingly, while the previous recommended trips remain unchanged. For example, if the displayed recommended trips are A1-B1-C1, and the user manually changes B1 to B2 in their candidate trips, then B1's subsequent trip C1 will automatically switch to C2, and the latest recommended trips will be A1-B2-C2. Here, B2 and C2 are adjacent candidate trips and have a relationship.

[0158] In some embodiments, users can select the corresponding candidate itinerary by choosing the time and location in the itinerary.

[0159] In some embodiments, candidate locations and candidate times in a candidate itinerary can be determined based on the popularity of events in a recommended itinerary or the distance to a recommended location; however, this application does not limit this.

[0160] The itinerary recommendation method provided in this application first obtains a user statement in a preset format, identifies the semantic elements contained in the user statement, and the semantic elements include at least one location element or one event element. Then, according to a preset set format, it determines the element set corresponding to the semantic elements, obtaining a set of elements to be processed. The elements in the set of elements to be processed are then normalized to obtain a target element set, wherein the elements in the preset set sequentially include time, location, direction, and event. Next, based on the target element set, it determines the recommended itinerary for each itinerary in the user statement, and pushes each recommended itinerary to the user according to the timeline between each recommended itinerary. Based on the user-provided user statement, it provides users with complete itinerary recommendations for multiple events, facilitating user travel planning and improving the intelligence level of the life service platform.

[0161] Based on the above embodiments, to improve user experience, after obtaining the recommended trips for each trip, if the number of recommended trips is less than the preset number of trips, a continuation trip of the recommended trip is generated based on the user's historical behavior and a behavior recommendation model. This continuation trip is then pushed to the user according to the timeline between the recommended trip and the continuation trip. In other words, when the number of trips contained in the user's statement is less than the preset number of trips, to enrich the user's trips and improve user experience, continuation trips of the recommended trips of the user's statement are recommended to the user based on the user's historical behavior and the behavior recommendation model.

[0162] For example, if the number of recommended trips is less than the preset number, it can be assumed that the user's trip may not be fully planned or rich enough. In such cases, a behavioral recommendation model can recommend K possible events to the user based on distance from the recommended location, forming K follow-up trips. The initial recommendation model is trained based on the user's historical behavior, and this initial model can be any behavioral prediction recommendation model. For instance, based on a large amount of user historical behavior, the behavioral recommendation model might learn that a user will go for a massage after skiing. Therefore, if the user's recommended trip includes a ski resort, a massage parlor near the ski resort would be automatically recommended as a follow-up trip.

[0163] Figure 6 This is a schematic diagram of a trip recommendation device provided in an embodiment of this application. Figure 6 As shown, the trip recommendation device 400 provided in this application embodiment includes:

[0164] The first processing module 401 is used to obtain user statements in a preset statement format and identify the semantic elements contained in the user statements. The semantic elements include at least one location element or one event element.

[0165] The second processing module 402 is used to determine the element set corresponding to the semantic element according to the format of the preset set, to obtain the element set to be processed, and to perform normalization processing on the elements in the element set to be processed to obtain the target element set. The elements in the preset set include time, location, orientation and event in sequence.

[0166] The third processing module 403 is used to determine the recommended trip for each trip in the user's statement based on the target element set, and to push each recommended trip to the user according to the timeline between each recommended trip.

[0167] In one possible design, the third processing module 403 is also used for:

[0168] Obtain multiple modes of transportation and their corresponding travel times for adjacent trips within each recommended itinerary, and push each mode of transportation and its corresponding travel time to the user.

[0169] In one possible design, the third processing module 403 is also used for:

[0170] Retrieve candidate trips for each recommended trip and push each candidate trip to the user. When a candidate trip is selected as a recommended trip, the subsequent trips of the selected candidate trip will automatically switch.

[0171] In one possible design, the first processing module 401 is specifically used for:

[0172] The intent recognition model sequentially identifies the time statement, location statement, and event statement contained in the user's statement.

[0173] Extract time nouns from time statements to obtain the time elements of semantic elements;

[0174] Extract location nouns and / or directional words from location statements to obtain the location elements of semantic elements;

[0175] Extract the event verbs from the event terms to obtain the event elements of semantic elements;

[0176] The user language must include at least one location statement or one event statement.

[0177] In one possible design, the second processing module 402 is specifically used for:

[0178] The time element, location element, and event element in the semantic elements are sequentially filled into a preset set to obtain the set of elements to be processed.

[0179] If any of the time element, location element, or event element is missing, the current element position in the preset set will be left empty.

[0180] In one possible design, the second processing module 402 is also used for:

[0181] Identify whether each set of elements to be processed contains only time-related elements;

[0182] If not, the time elements in each set of elements to be processed are converted to standard time according to the time period correspondence table, and the location and orientation elements in each set of elements to be processed are filtered and merged, and each set of elements to be processed after processing is determined as the corresponding target element set.

[0183] If so, delete the current set of elements to be processed.

[0184] In one possible design, the third processing module 403 is also used for:

[0185] Based on the corresponding locations contained in the location elements and the corresponding events contained in the event elements in the first target element set, search the map library to find candidate locations for the user's first trip.

[0186] Match the corresponding time contained in the time element of the first target element set with the opening time of the candidate locations of the first itinerary to obtain the recommended locations and recommended times of the first itinerary;

[0187] Based on the corresponding events contained in the elements of the events in the first set of target elements, the recommended location and recommended time of the first trip, the recommended itinerary for the first trip is obtained;

[0188] Based on the set of subsequent target elements and the recommended itinerary of the first itinerary, the recommended itinerary for each subsequent itinerary is determined.

[0189] exist Figure 6 On this basis, Figure 7 This is a schematic diagram of another trip recommendation device provided in an embodiment of this application. Figure 7 As shown, the trip recommendation device 400 provided in this application embodiment further includes: a fourth processing module 404; the fourth processing module 404 is used for:

[0190] If the number of recommended trips is less than the preset number of trips, a continuation trip of the recommended trips will be generated based on the user's historical behavior and the behavior recommendation model.

[0191] Extended itineraries are pushed to users based on the timeline between the recommended itinerary and the extended itinerary.

[0192] In one possible design, the intent recognition model includes at least one of the NER model, the large model, and the word segmentation model.

[0193] The trip recommendation device provided in this application embodiment can execute the corresponding steps of the trip recommendation method in the above method embodiment. Its implementation principle and technical effect are similar, and will not be described again here.

[0194] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. This electronic device is used to run a lifestyle service platform. Figure 8 As shown, the electronic device 500 may include a processor 501 and a memory 502 communicatively connected to the processor 501.

[0195] Memory 502 is used to store programs. Specifically, the program may include program code, which includes computer-executable instructions.

[0196] Memory 502 may include high-speed RAM memory, and may also include non-volatile memory, such as at least one disk storage device.

[0197] The processor 501 is used to execute computer execution instructions stored in the memory 502 to implement the above-mentioned recommended process method.

[0198] The processor 501 may be a central processing unit (CPU), an application specific integrated circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of this application.

[0199] Optionally, the memory 502 can be either standalone or integrated with the processor 501. When the memory 502 is a device independent of the processor 501, the electronic device 500 may further include:

[0200] Bus 503 is used to connect processor 501 and memory 502. The bus can be an industry standard architecture (ISA) bus, a peripheral component (PCI) bus, or an extended industry standard architecture (EISA) bus, etc. Buses can be categorized as address buses, data buses, control buses, etc., but this does not mean there is only one bus or one type of bus.

[0201] Optionally, in a specific implementation, if the memory 502 and the processor 501 are integrated on a single chip, the memory 502 and the processor 501 can communicate through an internal interface.

[0202] This application also provides a computer-readable storage medium, which may include various media capable of storing program code, such as a USB flash drive, a portable hard drive, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk. Specifically, the computer-readable storage medium stores computer-executable instructions, which are used in the methods described in the above embodiments.

[0203] This application also provides a computer program product, including computer execution instructions that, when executed by a processor, implement the methods described above.

[0204] Other embodiments of this application will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of this application that follow the general principles of this application and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this application are indicated by the claims.

[0205] It should be understood that this application is not limited to the precise structure described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this application is limited only by the appended claims.

Claims

1. A trip recommendation method, characterized in that, include: Obtain user statements with a preset statement format, identify the semantic elements contained in the user statements, and the semantic elements include at least one location element or one event element; The user statements include multiple trips; The time element, location element, and event element from the semantic elements are sequentially filled into a preset set to obtain a set of elements to be processed; wherein, the elements in the preset set include time, location, orientation, and event in sequence; if any one of the time element, location element, and event element is not present, the current element position in the preset set is left empty; one trip corresponds to one set of elements to be processed; Identify whether each set of elements to be processed contains only time-related elements; If so, delete the current set of elements to be processed; If not, the time elements in each set of elements to be processed are converted to standard time according to the time period correspondence table, and the location and orientation elements in each set of elements to be processed are filtered and merged to determine each set of elements to be processed as the corresponding target element set; multiple target element sets are arranged according to the itinerary order in the user statement; Based on the target element set, a recommended trip is determined for each trip in the user statement, and each recommended trip is pushed to the user according to the timeline between each recommended trip.

2. The itinerary recommendation method according to claim 1, characterized in that, After pushing each recommended trip to the user according to the timeline between each recommended trip, the method further includes: The system obtains multiple modes of transportation and the corresponding travel time for each mode of transportation between adjacent trips in each recommended trip, and pushes each mode of transportation and its corresponding travel time to the user.

3. The itinerary recommendation method according to claim 1, characterized in that, After determining the recommended itinerary for each trip in the user statement based on the target element set, the method further includes: Obtain candidate trips corresponding to each recommended trip and push each candidate trip to the user. When a candidate trip is selected as a recommended trip, the subsequent trips of the selected candidate trip will automatically switch following the selected candidate trip.

4. The itinerary recommendation method according to any one of claims 1-3, characterized in that, The identification of semantic elements contained in the user statement includes: The intent recognition model sequentially identifies time-related terms, location-related terms, and event-related terms contained in the user's statements; Extract the time nouns from the time statement to obtain the time element of the semantic element; Extract the location nouns and / or directional words from the location statement to obtain the location element of the semantic element; Extract the event verbs from the event terms to obtain the event elements of the semantic elements; The user language shall include at least one location statement or one event statement.

5. The itinerary recommendation method according to claim 1, characterized in that, The step of determining the recommended itinerary for each trip in the user statement based on the target element set includes: Based on the corresponding locations contained in the location elements and the corresponding events contained in the event elements in the first target element set, search the map library to find candidate locations for the first trip of the user's terminology; The corresponding time contained in the time element of the first target element set is matched with the opening time of the candidate locations of the first itinerary to obtain the recommended locations and recommended times of the first itinerary; Based on the corresponding events contained in the elements of the events in the first set of target elements, the recommended location and recommended time of the first trip, the recommended itinerary of the first trip is obtained; Based on the set of subsequent target elements and the recommended itinerary of the first itinerary, the recommended itinerary for subsequent itineraries after the first itinerary is determined, thus obtaining the recommended itinerary for each itinerary.

6. The itinerary recommendation method according to claim 5, characterized in that, After obtaining the recommended itinerary for each of the trips, the process further includes: If the number of recommended trips is less than the preset number of trips, a continuation trip of the recommended trips is generated based on the user's historical behavior and the behavior recommendation model; The extended itinerary is pushed to the user according to the timeline between the recommended itinerary and the extended itinerary.

7. The itinerary recommendation method according to claim 4, characterized in that, The intent recognition model includes at least one of the NER model, the large model, and the word segmentation model.

8. A trip recommendation device, characterized in that, include: The first processing module is used to acquire user statements in a preset statement format, identify the semantic elements contained in the user statements, and the semantic elements include at least one location element or one event element; the user statements include multiple trips; The second processing module is used to sequentially fill the time element, location element, and event element from the semantic elements into a preset set to obtain a set of elements to be processed. The elements in the preset set sequentially include time, location, orientation, and event. If any one of the time element, location element, or event element is missing, the current element position in the preset set is left empty. One trip corresponds to one set of elements to be processed. The module identifies whether each set of elements to be processed contains only time elements. If so, the current set of elements to be processed is deleted. If not, the time elements in each set of elements to be processed are converted to standard time according to a time period correspondence table, and the location and orientation elements in each set of elements to be processed are filtered and merged. The processed set of elements to be processed is then determined as the corresponding target element set. Multiple target element sets are arranged according to the trip order in the user statement. The third processing module is used to determine the recommended trip for each trip in the user statement based on the target element set, and to push each recommended trip to the user according to the timeline between each recommended trip.

9. A lifestyle service platform, characterized in that, include: A processor, and a memory communicatively connected to the processor; The memory stores computer-executed instructions; The processor executes computer execution instructions stored in the memory to implement the trip recommendation method as described in any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-executable instructions, which, when executed by a processor, are used to implement the trip recommendation method as described in any one of claims 1 to 7.

11. A computer program product comprising computer-executable instructions, which, when executed by a processor, are used to implement the trip recommendation method as described in any one of claims 1 to 7.