Method, system, medium and device for predicting category- and time-sensitive event sequences

By calculating the impact of event and category intensity and combining the transformation function, the problem of failure to fully consider event categories and duration in event sequence prediction in the prior art is solved, and more accurate event sequence prediction and personalized recommendation are achieved.

CN118627674BActive Publication Date: 2025-07-18SOUTHEAST UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410748224.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-11
Publication Date
2025-07-18
Estimated Expiration
2044-06-11

AI Technical Summary

Technical Problem

The prior art fails to fully consider the impact of event category and duration in event sequence prediction, resulting in inaccurate prediction and inaccurate complex relationships between events.

Method used

By calculating the event intensity and category intensity of the target user on the optional event, fuse the event characteristics and category characteristics, use the transformation function to obtain the final predicted value of the constant positive event intensity, and recommend the largest multiple optional events.

Benefits of technology

It improves the accuracy of event sequence prediction, can recommend projects that users may be interested in more accurately, and enhances personalized service level.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118627674B_ABST
    Figure CN118627674B_ABST
Patent Text Reader

Abstract

The present invention discloses a method, system, medium and device for predicting a sequence of category- and time-sensitive events, belonging to the field of machine learning. First, the present invention obtains the historical event records of a target user within a historical time range, and successively calculates the first intensity influence and the second intensity influence of the target user on each optional event in the optional event library. Then, for each optional event in the optional event library in turn, the initial predicted value of the event intensity of the target user with respect to the optional event is calculated, and it is converted into a finally predicted value of the event intensity that is always positive through a conversion function. Finally, multiple optional events with the largest finally predicted values of the event intensity are selected and recommended to the target user. The present invention describes the influence relationship between events from two aspects of event characteristics and event category characteristics, and at the same time considers the influence of the duration and occurrence time of historical events, and can achieve more accurate prediction of the next event.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of machine learning, and in particular relates to a method, system, medium and device for predicting a category and time-sensitive event sequence. Background Art

[0002] Sequence-based next event prediction often requires modeling interactive events in historical time series (e.g., user movie viewing history, user game playing history, etc.) to predict items that users may be interested in in the future (e.g., a certain movie, a certain game, etc.). Accurate sequence prediction is conducive to improving personalized service levels and can be converted into considerable commercial benefits, and has always been highly valued by the industry.

[0003] In statistics and probability theory, a point process is a random process that describes the distribution of random points. By observing the actual occurrence process of event sequences, we can find that in many scenarios, there is often an influence relationship between events, that is, the events that have occurred have a positive or negative effect on the occurrence of future events, and the influence of historical events is superimposed in a cumulative form. The existing event sequence modeling methods generally have the following main problems: 1) The category to which the event belongs has not received sufficient attention. In fact, events belonging to the same category may occur repeatedly. For example, although a player can change different games over a period of time, these games are likely to belong to the same category, which reflects a stable preference of the player during this period. 2) It is believed that the impact of historical events on current events is always positive. However, the relationship between users' sequential behaviors is often very complex. For example, similar items that have been purchased may not be purchased repeatedly in the short term. This shows that there are not only positive effects but also negative effects between events. 3) Only one influence factor is used to express the impact between two events, which is obviously insufficient in actual scenarios. In fact, the impact of one event on another event should be multifaceted, which may be the result of the joint influence of multiple different latent features. For example, the popularity of a song and the singer will affect whether the user is interested in the song. The popularity, style and other factors of a game will be important factors affecting whether the user will play the game. 4) Only considering the time of event occurrence ignores the duration of the event. Obviously, the longer the duration of an event, the greater the possibility of the event happening again. Therefore, how to better model the event sequence to achieve accurate prediction of the next event is a technical problem that needs to be solved urgently. Summary of the invention

[0004] The purpose of the present invention is to solve the above-mentioned technical problems existing in the prior art and to provide a category and time-sensitive event sequence prediction method, system, medium and device.

[0005] The specific technical solution adopted by the present invention is as follows:

[0006] In a first aspect, the present invention provides a method for predicting an event sequence sensitive to categories and time, which includes:

[0007] S1: Obtain the occurrence records of historical events of the target user within the historical time range as the historical event data set;

[0008] S2: Sequentially for each optional event in the optional event library, calculate the first intensity influence of the target user on the optional event in the event dimension based on the occurrence records of each historical event in the historical event data set;

[0009] S3: Sequentially for each optional event in the optional event library, calculate the second intensity influence of the target user on the optional event in the event category dimension based on the occurrence records of each historical event in the historical event data set;

[0010] S4: Sequentially for each optional event in the optional event library, fuse the initial intensity of the optional event, the initial intensity of the category to which the optional event belongs, the first intensity influence, and the second intensity influence to obtain the initial predicted value of the event intensity of the target user on the optional event;

[0011] S5: Convert the initial predicted value of the event intensity of the target user on each optional event in the optional event library into a positive final predicted value of the event intensity through a conversion function, and then recommend multiple optional events with the largest final predicted value of the event intensity to the target user.

[0012] Preferably, in the above first aspect, the steps S1 to S5 are specifically implemented in the following manner:

[0013] S1. Obtain all historical events of the target user u within the historical time range of all occurrence records as the historical event data set Historical events Each occurrence record of includes user ID, event name, event category, event trigger time, and event duration; Denote the set of different historical events as the optional event library E;

[0014] S2. Sequentially for each optional event e in the optional event library E, calculate the historical event data set in each historical event of each occurrence for the event intensity influence of the occurrence of the optional event e at the target time t and then sum, and the sum value is used as the first intensity influence m of the target user u on the optional event e u,e ; Where the historical event The impact of each occurrence on the event intensity of the optional event e occurring at the target time t is determined by the transposed vector of the event feature vector f of the optional event e, the historical event e , the event impact matrix for the optional event e historical event event feature vector of historical event the duration of this occurrence is obtained by sequentially multiplying the natural exponential conversion values of the first feature, where the first feature is composed of the transposed vector of the event feature vector f of the optional event e, the historical event e , the event impact attenuation matrix for the optional event e historical event event feature vector of the time difference between the target time t and the trigger time of the historical event of this occurrence is multiplied and then negated;

[0015] S3. For each optional event e in the optional event library E in sequence, calculate the impact of each occurrence of each historical event in the historical event dataset on the category intensity of the optional event e occurring at the target time t, and then sum them up. The sum value is used as the second intensity impact n of the target user u with respect to the optional event e u,e ; where the impact of each occurrence of the historical event on the category intensity of the optional event e occurring at the target time t is determined by the transposed vector of the event category feature vector g of the category c(e) to which the optional event e belongs, the historical event c(e) , category the event category impact matrix for the category c(e) to which the optional event e belongs historical event category event category feature vector of historical event the duration of this occurrence is obtained by sequentially multiplying the natural exponential conversion values of the second feature, where the second feature is composed of the transposed vector of the event category feature vector g of the category c(e) to which the optional event e belongs, the historical event c(e) , category the event category impact attenuation matrix for the category c(e) to which the optional event e belongs historical event category event category feature vector of the time difference between the target time t and the historical event It is obtained by multiplying the time differences between the triggering moments that occurred this time and then taking the negative value;

[0016] S4. For each optional event e in the optional event library E in turn, the transposed vector of the event feature vector f e of the optional event e and the event initial intensity weight vector a u,e of the target user u with respect to the optional event e, the product of the transposed vector of the event category feature vector g c(e) of the category c(e) to which the optional event e belongs and the event category initial intensity weight vector b u,c(e) of the target user u with respect to the category c(e) to which the optional event e belongs, the first intensity influence m u,e of the target user u with respect to the optional event e, and the second intensity influence n u,e of the target user u with respect to the optional event e are summed, and the sum value is used as the initial event intensity prediction value.

[0017] S5. Through a conversion function, the initial event intensity prediction value of the target user u with respect to each optional event e in the optional event library E is converted into a final event intensity prediction value that is always positive. Then, multiple optional events with the largest final event intensity prediction values are recommended to the target user u.

[0018] As an optimization of the above first aspect, the event feature vector f e of the optional event e, the event category feature vector g c(e) of the category to which the optional event e belongs, the event initial intensity weight vector a u,e of the target user u with respect to the optional event e, the event category initial intensity weight vector b u,c(e) of the target user u with respect to the category to which the optional event e belongs, historical events the event influence matrix of historical events for the optional event e, historical events the event influence attenuation matrix of historical events for the optional event e, historical events the event category influence matrix of the category to which the historical event belongs for the category to which the optional event e belongs historical events the event category influence attenuation matrix of the category to which the historical event belongs for the category to which the optional event e belongs all adopt optimized learnable parameters, and are obtained by performing supervised learning on the event prediction model framework composed of S1 to S5 through a historical event data set.

[0019] Preferably, in the first aspect above, the historical event dataset contains training samples that satisfy the input and output of the event prediction model, and is obtained by processing event occurrence records automatically collected for users; during the automatic collection process, the user ID, event name, event category, event start time, and event duration corresponding to each event occurrence record need to be collected, and event occurrence records containing missing values are deleted, and unreasonable event occurrence records with an event duration exceeding the upper threshold or lower than the lower threshold are deleted.

[0020] Preferably, in the supervised learning process, the loss function adopted is the weighted sum of the negative log-likelihood function and the L2 regularization term of the model parameters.

[0021] Preferably, in the first aspect above, the event feature vector f of the optional event e e and the event category feature vector g of the category to which the optional event e belongs c(e) and the initial event intensity weight vector a of the target user u with respect to the optional event e u,e and the initial event category intensity weight vector b of the target user u with respect to the category to which the optional event e belongs u,c(e) all have a dimension of n, and the historical events For the event influence matrix of the optional event e Historical events For the event influence decay matrix of the optional event e Historical events The event category influence matrix of the category to which the historical event belongs with respect to the category to which the optional event e belongs Historical events The event category influence decay matrix of the category to which the historical event belongs with respect to the category to which the optional event e belongs all have a dimension of n×n, where n = 32 to 512.

[0022] Preferably, in the first aspect above, the initial predicted value of the event intensity is converted into a final predicted value of the event intensity that is always positive The conversion function is: using the initial predicted value of the event intensity as the dividend, and the absolute value of the initial predicted value of the event intensity plus 1 as the divisor, and the quotient of the two plus 1 to obtain the converted final predicted value of the event intensity.

[0023] Second aspect, the present invention provides a category and time-sensitive network platform project recommendation system, which includes:

[0024] An interaction record monitoring module for recording interaction records between different users and projects on a network platform, where the interaction records include user ID, project name, project category, the moment when the user triggers the project, and the duration of the user's interaction with the project; all interaction records are classified and stored by user to form a historical event dataset for each user.

[0025] A project recommendation module for, according to the event sequence prediction method described in any one of the above first aspect solutions, taking the currently interacted projects on the platform as optional events in the optional event library, and making a recommendation for the next project for the target user.

[0026] In a third aspect, the present invention provides a computer program product including a computer program / instructions, which when executed by a processor, can implement the category and time-sensitive event sequence prediction method described in any one of the above first aspect solutions, or can implement the category and time-sensitive network platform project recommendation system described in any one of the above second aspect solutions.

[0027] In a fourth aspect, the present invention provides a computer-readable storage medium, characterized in that a computer program is stored on the storage medium, which when executed by a processor, can implement the category and time-sensitive event sequence prediction method described in any one of the above first aspect solutions, or can implement the category and time-sensitive network platform project recommendation system described in any one of the above second aspect solutions.

[0028] In a fifth aspect, the present invention provides a computer electronic device, which includes a memory and a processor;

[0029] The memory is used for storing a computer program;

[0030] The processor is used for, when executing the computer program, being able to implement the category and time-sensitive event sequence prediction method described in any one of the above first aspect solutions, or being able to implement the category and time-sensitive network platform project recommendation system described in any one of the above second aspect solutions.

[0031] The present invention has the following beneficial effects compared with the prior art:

[0032] 1. The present invention is directed to the interaction records between users and projects on a network platform, and provides an event sequence modeling method based on hidden features of events and event categories, which can more finely depict the mutual influence relationships between events and between event categories, and introduces event category information in the event sequence modeling prediction process, which can capture stable features affecting the occurrence of events, making the prediction of the next event more accurate, and can be used for recommending events such as games, music, movies, etc. that a user may be interested in at the next moment on the network platform.

[0033] 2. In the process of event sequence modeling and prediction, the present invention not only considers the occurrence time of historical events, but also incorporates the duration of historical events, thereby being able to more accurately depict the influence degree of historical events on the current event.

[0034] 3. The present invention allows the influence relationships between events and between event categories to be either positive or negative, and in the process of event sequence modeling and prediction, a transformation function is introduced to obtain a finally predicted value of event intensity that is always positive, which not only can more truly reflect the event occurrence mechanism, but also makes the event intensity more in line with reality and the model more interpretable. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 is a step flowchart of a category - and time - sensitive event sequence prediction method of the present invention;

[0036] Figure 2 is a schematic diagram of the event prediction model framework;

[0037] Figure 3 is a block diagram of the components of the event prediction model;

[0038] Figure 4 is a block diagram of the components of a category - and time - sensitive network platform project recommendation system of the present invention;

[0039] Figure 5 is an example diagram of the next game prediction in an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0040] To make the above - mentioned objects, features, and advantages of the present invention more obvious and understandable, the following will describe the specific embodiments of the present invention in detail with reference to the accompanying drawings. Many specific details are set forth in the following description to fully understand the present invention. However, the present invention can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without departing from the connotation of the present invention. Therefore, the present invention is not limited by the specific embodiments disclosed below. The technical features in each embodiment of the present invention can be combined correspondingly without conflict.

[0041] In the description of the present invention, it should be understood that the terms "first" and "second" are only used for the purpose of distinguishing descriptions, and cannot be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, the features defined with "first" and "second" may explicitly or implicitly include at least one of such features.

[0042] Existing event sequence modeling methods cannot fully utilize the category and time information of events and are difficult to accurately and comprehensively depict the complex relationships between the hidden features of different events, resulting in the inability of event sequence models to accurately express the occurrence process of events, thus affecting the accuracy of event prediction. The present invention provides a category and time-sensitive event sequence prediction method for predicting trigger events at future moments based on the historical interaction events of users. In order to more accurately model the event sequence, the present invention depicts the mutual influence relationship between events from two aspects: event features and event category features (where event features reflect the individual characteristics of events, and event category features reflect the stable characteristics of events), and at the same time considers the influence of the duration and occurrence time of historical events, and realizes more accurate prediction of the next event by constructing a sequence model.

[0043] It should be noted that the "event" in the present invention can be an item for which a user generates an interaction on the platform, and the item can be determined according to the specific content provided by the platform, such as movies, music, games, etc. For a certain user, the same "event" can occur repeatedly, and each occurrence will generate an occurrence record. Therefore, there may be multiple occurrence records for the same "event".

[0044] As Figure 1 shown, in a preferred embodiment of the present invention, the category and time-sensitive event sequence prediction method includes the following steps S1 to S5:

[0045] S1: Obtain the historical event occurrence records of the target user within the historical time range as the historical event data set.

[0046] S2: Sequentially for each optional event in the optional event library, based on the occurrence records of each historical event in the historical event data set, calculate the first intensity influence of the target user on the optional event in the event dimension.

[0047] S3: Sequentially for each optional event in the optional event library, based on the occurrence records of each historical event in the historical event data set, calculate the second intensity influence of the target user on the optional event in the event category dimension.

[0048] S4: Sequentially for each optional event in the optional event library, fuse the initial intensity of the optional event, the initial intensity of the category to which the optional event belongs, the first intensity influence, and the second intensity influence to obtain the initial predicted value of the event intensity of the target user on the optional event.

[0049] S5: Convert the initial predicted value of the event intensity of the target user on each optional event in the optional event library into a positive final predicted value of the event intensity through a conversion function, and then recommend multiple optional events with the largest final predicted value of the event intensity to the target user.

[0050] The following will introduce the specific implementation methods of steps S1 to S5 in detail respectively.

[0051] S1. Obtain all historical occurrence records of the target user u within the historical time range as the historical event dataset Each occurrence record of the historical event historical event includes the user ID, event name, event category, event trigger time, and event duration. Denote the set of different historical events as the optional event library E.

[0052] It should be noted that the historical time range included in the historical event dataset can be reasonably adjusted according to actual needs. In theory, all occurrence records of historical events related to the user can be included in the historical event dataset However, in practice, the influence of historical event occurrence records that are too far from the current moment on the occurrence of the current event will weaken, and too many historical event occurrence records will reduce the calculation efficiency. Therefore, only some of the recent historical event occurrence records need to be included in the historical event dataset That is, it is preferable to select 100 - 300 recent historical event occurrence records.

[0053] S2. For each optional event e in the optional event library E in turn, calculate the sum of the event intensity impacts of each occurrence (i.e., corresponding to each occurrence record) of each historical event in the historical event dataset on the occurrence of the optional event e at the target time t, and the sum value is used as the first intensity impact m of the target user u with respect to the optional event e. Among them, the event intensity impact of each occurrence of the historical event u,e on the occurrence of the optional event e at the target time t is obtained by multiplying the transposed vector f of the event feature vector f e of the optional event e, the event impact matrix e T of the historical event on the optional event e, the event feature vector of the historical event and the natural exponential conversion value of the duration of this occurrence of the historical event historical event in sequence. The first feature is obtained by multiplying the transposed vector f of the event feature vector f e of the optional event e, the event impact attenuation matrix e T of the historical event on the optional event e Historical event Event feature vector The time difference between the target time t and the trigger time of the historical event is multiplied by a negative value and obtained by taking the negative value of the product between the target time t and the trigger time of the historical event

[0054] The first intensity influence m of the above-mentioned target user u on the optional event e u,e , it is necessary to traverse each historical event in the historical event data set in turn each historical event in each occurrence of is calculated, and this process incorporates all historical events that occurred before the target time t of the target user u (that is, historical events that meet the requirements trigger time ) information (including event feature vector, duration, trigger time, etc.). Thus, the above first intensity influence m u,e The calculation formula can be expressed as follows:

[0055]

[0056] Among them, the summation range includes all historical events in the historical event data set all historical events in each occurrence of, represents the triggered historical event, and respectively represent the trigger time and duration of a certain trigger of the historical event , exp represents the exponential function, and the part in the parentheses is the aforementioned first feature. represents that the influence of each event dimension decays exponentially with the time interval (that is ), represents the comprehensive influence of the historical event on the intensity of the optional event e in each event dimension.

[0057] S3. For each optional event e in the optional event library E in turn, calculate the historical event data set each historical event in each occurrence of (that is, corresponding to each occurrence record) for the category intensity influence of the optional event e occurring at the target time t, and then sum, and the summation value is used as the second intensity influence n of the target user u on the optional event e u,e . Among them, for each occurrence of each historical event e in the historical event data set E th the category intensity influence on the optional event e is determined by the transposed vector g of the event category feature vector g of the category c(e) to which the optional event e belongs th c(e) transpose vector g c(e) T historical event​ Category to which it belongs Event category impact matrix for the category c(e) to which the optional event e belongs Historical event Category to which it belongs Event category feature vector of Historical event Duration of this occurrence Obtained by sequentially multiplying the natural exponential conversion values of the second feature, where the second feature is the transposed vector g of the event category feature vector g of the event category c(e) to which the optional event e belongs c(e) Transposed vector g of c(e) T and historical event Category to which it belongs Event category impact attenuation matrix for the category c(e) to which the optional event e belongs Historical event Category to which it belongs Event category feature vector of The time difference between the target time t and the trigger time of this occurrence of the historical event is multiplied by -1 to obtain.

[0058] The second intensity impact n of the above target user u on the optional event e u,e needs to traverse each historical event in the historical event dataset for each occurrence to calculate, and this process incorporates all historical events that occurred before the target time t of the target user u (i.e., historical events that satisfy the trigger time ) of information (including event category feature vector, duration, trigger time, etc.). Thus, the above second intensity impact n u,e can be calculated as follows:

[0059]

[0060] where the summation range includes all historical events in the historical event dataset for each occurrence, represents the category to which the historical event h triggered at time t belongs. represents that the impact of each event category dimension decays exponentially with the time interval (i.e., ), represents the comprehensive impact of the historical event on the intensity of the optional event e in each event category dimension.

[0061] S4. For each optional event e in the optional event library E in sequence, multiply the transposed vector f e of the optional event e by the initial event intensity weight vector a e T of the target user u with respect to the optional event e, multiply the transposed vector g u,e of the event category feature vector g of the category c(e) to which the optional event e belongs by the initial event category intensity weight vector b c(e) of the target user u with respect to the category c(e) to which the optional event e belongs, and sum the product, the first intensity influence m c(e) T of the target user u with respect to the optional event e, the second intensity influence n u,c(e) of the target user u with respect to the optional event e. Take the sum value as the initial predicted value of the event intensity u,e u,e

[0062] It should be noted that the above initial predicted value of the event intensity actually accumulates the initial intensity of the optional event e, the initial intensity of the category c(e) to which the optional event e belongs, the first intensity influence m u,e of the target user u with respect to the optional event e obtained in step S2 u,e and the second intensity influence n of the target user u with respect to the optional event e obtained in step S3. The intensities of each accumulation term comprehensively constitute the initial predicted value of the event intensity e where the initial intensity of the optional event e is obtained by multiplying the transposed vector of f u,e by a c(e) and the initial intensity of the category c(e) to which the event e belongs is obtained by multiplying the transposed vector of g u,c(e) by b Therefore, the calculation formula of the above initial predicted value of the event intensity

[0063]

[0064] where T represents transpose and c(e) represents the category to which the optional event e belongs.

[0065] S5. Convert the initial predicted value of the event intensity of the target user u with respect to each optional event e in the event library E through a conversion function into a positive event intensity final predicted value Then select multiple optional events with the largest final predicted value of the event intensity and recommend them to the target user u.

[0066] It should be noted that the above conversion function can be reasonably designed, and its purpose is to convert the initial predicted value of the event intensity into a constant positive value. Because in the real event occurrence mechanism, the influence relationships between events and between event categories may be positive or negative, so that the initial predicted value of the event intensity calculated may be negative. In the embodiments of the present invention, the conversion function takes the initial predicted value of the event intensity as the dividend, takes the absolute value of the initial predicted value of the event intensity plus 1 as the divisor, and adds 1 to the quotient of the two to obtain the final predicted value of the event intensity after conversion. The formula of the conversion function is expressed as follows:

[0067]

[0068] In the formula: || represents the absolute value operation.

[0069] The final predicted value of the event intensity after being converted by the above conversion function can be used for the Top-k recommendation of the conventional next event, and the specific number of recommendations is designed according to user requirements. For example, when only a single event needs to be recommended, the optional event with the largest final predicted value of the event intensity can be selected, and the overall in-model process is as Figure 2 shown.

[0070] In the present invention, the above steps S1 to S5 can constitute an event prediction model framework, as Figure 3 shown. In this event prediction model framework, there are an input module, a first intensity influence calculation module, a second intensity influence calculation module, an event intensity predicted value calculation module, and a predicted event output module, corresponding to steps S1, S2, S3, S4, and S5 respectively. The above S1 to S5 show the process of the forward data processing, that is, the inference link, of this event prediction model. However, this model also needs to be trained before being used for actual inference so that it can be applicable to the corresponding tasks. The learnable parameters in this model include: the event feature vector f e of the optional event e, the event category feature vector g c(e) of the event category to which the optional event e belongs, the event initial intensity weight vector a u,e of the target user u with respect to the optional event e, the event category initial intensity weight vector b u,c(e) of the target user u with respect to the event category to which the optional event e belongs, the event influence matrix of the historical event for the optional event e, the event influence attenuation matrix of the historical event for the optional event e, the event category influence matrix of the event category to which the historical event belongs for the event category to which the optional event e belongs, the event category influence matrix Event category impact attenuation matrix for the event category to which the optional event e belongs After the above learnable parameters are optimized, they can be used for actual inference. When new users appear or new events appear in the optional event library of the platform, that is, in the case of cold start, it is necessary to collect data again to train the model (that is, it is necessary to re-optimize the parameters).

[0071] In addition, the event prediction model framework composed of the above S1 to S5 can be obtained through the historical event data set by supervised learning. In the embodiments of the present invention, the construction of the historical event data set and the supervised learning of the model can be realized in the following manner.

[0072] First, the event trigger records of different users can be collected on the platform, and this process can be realized by an automated method. During the automated collection process, it is necessary to collect the user ID, event name, event category to which the event belongs, event start time, and event duration corresponding to each occurrence of each historical event, and delete the event occurrence records containing missing values, and delete the unreasonable event occurrence records whose event duration exceeds the upper threshold or is lower than the lower threshold. The specific upper / lower threshold needs to be obtained through statistical analysis of the actual data. After the event occurrence records automatically collected for users are processed by data, the above historical event data set can be finally constructed, and this data set contains training samples that meet the input and output of the event prediction model. The specific sample form can be determined according to the input and output requirements of the model.

[0073] Secondly, after obtaining the above historical event data set, all the occurred historical events are used as the optional event e and added to the optional event library E, and the historical event data set is used to perform supervised learning on the model. Before model training, it is necessary to initialize all the learnable parameters in advance, specifically:

[0074] 1) Randomly encode each optional event e: generate an n-dimensional event feature vector f for it e ; randomly encode each event category c, and generate an n-dimensional event category feature vector g for it c , where n represents the latent feature quantity of the event or event category;

[0075] 2) Initialize the initial intensity of each event and event category: For each user u, randomly initialize an n-dimensional event initial intensity weight vector a for each event e u,e and an n-dimensional event category initial intensity weight vector b for each event category c u,c ;

[0076] 3) Initialize the intensity influence between events: For each user u, randomly initialize its influence on any two events ei and e j an n×n dimensional event influence matrix between any two events e i and e j an n×n dimensional event influence attenuation matrix varying with time between

[0077] 4) Initialize the intensity influence between event categories: For each user u, randomly initialize an n×n dimensional event category influence matrix between any two event categories c i and c j an n×n dimensional event category influence matrix between any two event categories c i and c j an n×n dimensional event category influence attenuation matrix varying with time between

[0078] Thus, in this embodiment, the finally initialized learnable parameters are as follows: The event feature vector f of the optional event e e the event category feature vector g of the category to which the optional event e belongs c(e) the initial intensity weight vector a of the target user u with respect to the optional event e u,e the initial intensity weight vector b of the target user u with respect to the category to which the optional event e belongs u,c(e) can all be initialized as vectors with dimension n and all components being 1; historical events the event influence matrix for the optional event e historical events the event influence attenuation matrix for the optional event e historical events the event category influence matrix of the category to which the historical event belongs for the category to which the optional event e belongs historical events the event category influence attenuation matrix of the category to which the historical event belongs for the category to which the optional event e belongs can all be initialized as matrices with dimension n×n and all element values being 1. The specific dimension value n can be reasonably optimized according to actual needs. Generally, n = 32 - 512, and the optimal value is 128.

[0079] Subsequently, construct the loss function required for model training. The loss function of the present invention is the weighted sum of the negative log-likelihood and the L2 regularization term of the model parameters. In the embodiment of the present invention, the form of the loss function is as follows:

[0080]

[0081] where α is the regularization coefficient, N is the total number of test samples in the historical event dataset, The final predicted value of the event intensity of the target event e actually occurring at the target time t for the target user u.

[0082] Finally, after the construction of the data set, the initialization of the learnable parameters, and the construction of the loss function, the supervised learning training of the model can be carried out. The training of the model belongs to the prior art, and the error between the predicted event and the actually occurring event can be compared, and the parameters f e 、g c(e) 、a u,e 、b u,c(e) 、 are optimized through the ADAM method to obtain the event prediction model. Based on the trained event prediction model, a new historical event occurrence sequence of a target user can be input, and the next possible event of the target user can be predicted and recommended to the target user, for example, for personalized recommendations of games, movies, and music on the platform.

[0083] Thus, based on the same inventive concept, the present invention also provides a category and time-sensitive network platform project recommendation system corresponding to the category and time-sensitive event sequence prediction method provided in the above embodiment, as Figure 4 shown, which includes:

[0084] An interaction record monitoring module, configured to record the interaction records between different users and projects on the network platform, where the interaction records include user ID, project name, project category, the time when the user triggers the project, and the duration of the user's interaction with the project; all interaction records are classified and stored by user to form a historical event data set for each user;

[0085] A project recommendation module, configured to use the event sequence prediction method described in the foregoing embodiment, take the currently interacted projects on the platform as the optional events in the optional event library, and recommend projects for the target user.

[0086] Similarly, based on the same inventive concept, the present invention also provides a computer electronic device corresponding to the category and time-sensitive event sequence prediction method provided in the above embodiment, which includes a memory and a processor;

[0087] The memory is used to store a computer program;

[0088] The processor is configured to, when executing the computer program, be able to implement the category and time-sensitive event sequence prediction method described in the foregoing embodiment, or be able to implement the category and time-sensitive network platform project recommendation system described in the foregoing embodiment.

[0089] In addition, when the logical instructions in the above-mentioned memory are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention.

[0090] Therefore, based on the same inventive concept, the present invention provides a computer-readable storage medium corresponding to a method for predicting a category- and time-sensitive event sequence. A computer program is stored on the storage medium, and when the computer program is executed by a processor, it can implement the method for predicting a category- and time-sensitive event sequence as described in the foregoing embodiments, or can implement the category- and time-sensitive network platform project recommendation system as described in the foregoing embodiments.

[0091] Therefore, based on the same inventive concept, the present invention provides a computer program product, including a computer program / instructions. When the computer program / instructions are executed by a processor, they can implement the method for predicting a category- and time-sensitive event sequence as described in the foregoing embodiments, or can implement the category- and time-sensitive network platform project recommendation system as described in the foregoing embodiments.

[0092] It can be understood that the above storage medium may include a random access memory (RAM), and may also include a non-volatile memory (NVM), such as at least one disk memory. At the same time, the storage medium may also be various media such as a USB flash drive, a mobile hard disk, a magnetic disk, or an optical disc that can store program codes.

[0093] It can be understood that the above-mentioned processor may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0094] In addition, it should be noted that those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working process of the system described above can refer to the corresponding process in the foregoing method embodiments and will not be elaborated herein. In the embodiments provided in the present application, the division of steps or modules in the system and method is only a logical function division, and there may be other division methods in actual implementation. For example, multiple modules or steps can be combined or integrated together, and a module or step can also be split.

[0095] The above category and time-sensitive event sequence prediction method will be applied to a specific example below to demonstrate its specific personalized improvement process and personalized improvement effect.

[0096] Embodiment 1

[0097] In this embodiment, the category and time-sensitive event sequence prediction method shown in S1 to S5 above (hereinafter referred to as the method of the present invention) is applied to the actual effect of predicting the next game on the game platform. Figure 5 It is an example diagram for applying the method of the present invention to predict the next game. In this embodiment, a game play data set (i.e., a historical event data set) containing more than 430,000 game play records is introduced. This game data set records the start time and duration of different players playing different games, the game name and the category to which the game belongs. The method provided by the present invention is used to predict the game that a certain player will play at the next moment and recommend it to the player. The effectiveness of the method provided by the present invention is verified by recall rate and mean reciprocal rank.

[0098] The recall rate is defined by the following formula:

[0099]

[0100] Here, #(n, hit) represents the number of samples in which the next event is hit in the Top-n recommendation list given by the method provided by the present invention, and #(all) represents the total number of samples.

[0101] The mean reciprocal rank is defined by the following formula:

[0102]

[0103] Here, rank i represents the position of the next event that actually occurs in the i-th test sample in the predicted Top-n recommendation list. If it is not in the Top-n recommendation list (i.e., not hit), then rank i = 0.

[0104] The experimental results on this dataset show that the average recall rate of the method of the present invention for the Top-5 recommendation, Top-10 recommendation, Top-15 recommendation, and Top-20 recommendation (i.e., the top 5, 10, 15, and 20 optimal recommendations) in the next game is 65%, and the average MRR is 38%, which is better than the recall rate (47%) and MRR (23%) of GRU4Rec, and also better than the recall rate (25%) and MRR (8%) of LSTM.

[0105] The embodiments described above are only a preferred solution of the present invention, but they are not intended to limit the present invention. Those of ordinary skill in the relevant technical field can also make various changes and modifications without departing from the spirit and scope of the present invention. Therefore, all technical solutions obtained by means of equivalent replacement or equivalent transformation fall within the protection scope of the present invention.

Claims

1. A method for predicting a sequence of category- and time-sensitive events, characterized in that, The prediction method includes the following steps: S1: Obtain all historical events of the target user u within the historical time range of all occurrence records as the historical event dataset Historical event Each occurrence record of the event includes the user ID, event name, event category, event trigger time, and event duration; the event is an item generated by the user's interaction on the platform; S2: For each optional event e in the optional event library in sequence, based on the occurrence records of each historical event in the historical event dataset, calculate the first intensity influence m of the target user u on the optional event e in the event dimension The calculation formula is: u,e as follows: In the formula, the historical event data set is included in the summation range of all historical events for each occurrence of indicating the triggered historical event and respectively represent the trigger time and duration of a certain occurrence of the historical event , exp represents the exponential function, and the part in the brackets is the aforementioned first feature indicating the influence of each event dimension over the time interval, that is showing exponential decay; f e and are the event feature vectors of the optional event e and the historical event respectively is the event influence matrix of the historical event with respect to the optional event e is the duration of this occurrence of the historical event is the event influence attenuation matrix of the historical event with respect to the optional event e, t represents the target time, and T represents the transpose operation​ S3: Sequentially for each optional event e in the optional event library, based on the occurrence records of each historical event in the historical event dataset, calculate the second intensity influence n of the target user u on the optional event e in the event category dimension The calculation formula is: u,e as follows: Among them, those included in the summation range are historical event datasets all historical events for each occurrence of indicating the historical event triggered at time and its belonging category indicating that the influence of each event category dimension decays exponentially over time indicating the comprehensive influence, g, of historical events on the intensity of the optional event e in each event category dimension c(e) and are respectively the event category c(e) to which the optional event e belongs and the historical event and its belonging category of the event category feature vector is the event category influence matrix of the historical event and its belonging category for the event category c(e) to which the optional event e belongs is the event category influence decay matrix of the historical event and its belonging category for the event category c(e) to which the optional event e belongs S4: For each optional event e in the optional event library in sequence, fuse the initial intensity of the optional event, the initial intensity of the category to which the optional event belongs, the first intensity influence, and the second intensity influence to obtain the initial predicted value of the event intensity of the target user u with respect to the optional event e The calculation formula is as follows: Where: a u,e is the initial intensity weight vector of the event of the target user u regarding the optional event e, and b u,c(e) is the initial intensity weight vector of the event category of the target user u regarding the category c(e) to which the optional event e belongs; S5: Convert the initial predicted value of the event intensity of each optional event in the optional event library for the target user into a finally predicted value of the event intensity that is always positive through a conversion function Then select the finally predicted value of the event intensity Recommend the largest number of optional events e to the target user u.

2. The method for predicting a category- and time-sensitive event sequence according to claim 1, wherein The event feature vector f of the optional event e , the event category feature vector g of the category to which the optional event belongs c(e) , the initial event intensity weight vector a of the target user u with respect to the optional event e u,e , the initial event category intensity weight vector b of the target user u with respect to the category c(e) to which the optional event e belongs u,c(e) , historical events The event impact matrix for the optional event e , historical events The event impact attenuation matrix for the optional event e , historical events The event category impact matrix of the category to which the optional event belongs on the category to which the optional event e belongs , historical events The event category impact attenuation matrix of the category to which the optional event belongs on the category to which the optional event e belongs All adopt optimized learnable parameters and are obtained by supervised learning through the event prediction model framework composed of S1 to S5 and the historical event dataset.

3. The method for predicting a category- and time-sensitive event sequence according to claim 2, wherein The historical event dataset contains training samples that meet the input and output of the event prediction model, and is obtained by processing the event occurrence records automatically collected for users; during the automatic collection process, the user ID, event name, event category, event start time, and event duration corresponding to each event occurrence record need to be collected, and the event occurrence records containing missing values are deleted, and the unreasonable event occurrence records with event durations exceeding the upper threshold or lower than the lower threshold are deleted; During the supervised learning process, the loss function used is the weighted sum of the negative log-likelihood function and the L2 regularization term of the model parameters.

4. The method for predicting a category- and time-sensitive event sequence according to claim 1, wherein, The event feature vector f of the optional event e , the event category feature vector g of the category to which the optional event belongs c(e) , the initial event intensity weight vector a of the target user u with respect to the optional event e u,e , the initial event category intensity weight vector b of the target user u with respect to the category c(e) to which the optional event e belongs u,c(e) are all of dimension n, and the historical event The event impact matrix for the optional event e Historical event The event impact attenuation matrix of the category to which the historical event belongs for the category to which the optional event e belongs Historical event The event category impact matrix of the category to which the historical event belongs for the category to which the optional event e belongs Historical event The event category impact attenuation matrix of the category to which the historical event belongs for the category to which the optional event e belongs are all of dimension n×n, where n = 32 to 512.

5. A category and time-sensitive network platform project recommendation system, characterized in that, It includes: An interaction record monitoring module for recording the interaction records between different users and projects on the network platform, where the interaction records include user ID, project name, project category, the moment when the user triggers the project, and the duration of the user's interaction with the project; All interaction records are classified and stored by user to form a historical event dataset for each user; A project recommendation module for recommending the next project for the target user by using the event sequence prediction method according to any one of claims 1 to 4, with the currently selectable projects on the platform as the selectable events in the selectable event library.

6. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instructions are executed by a processor, it can implement the category- and time-sensitive event sequence prediction method according to any one of claims 1 to 4, or can implement the category- and time-sensitive network platform project recommendation system according to claim 5.

7. A computer-readable storage medium, characterized in that, A computer program is stored on the storage medium, and when the computer program is executed by a processor, it implements the category- and time-sensitive event sequence prediction method according to any one of claims 1 to 4, or can implement the category- and time-sensitive network platform project recommendation system according to claim 5.

8. A computer electronic device, characterized in that, It includes a memory and a processor; The memory is used for storing a computer program; The processor is used for, when executing the computer program, implementing the category- and time-sensitive event sequence prediction method according to any one of claims 1 to 4, or can implement the category- and time-sensitive network platform project recommendation system according to claim 5.

Citation Information

Patent Citations

  • Information prediction method and device and related equipment

    CN117035846A

  • Multi-target prediction method and apparatus, device, storage medium, and program product

    WO2023016147A1