User recommendation model training method, coupon recommendation method and device
By using the pulse time-dependent plasticity mechanism and the training method of the user recommendation model in the absence of massive training data, the accuracy and overfitting problems of the user recommendation model when the data is insufficient is solved, and more accurate user recommendations are achieved.
Patent Information
- Application Number
- CN202411918707.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-24
- Publication Date
- 2025-04-01
AI Technical Summary
When existing user-recommended models lack massive training data, the calculation results are inaccurate and are prone to overfitting, resulting in recommendation deviations.
Unsupervised training is performed using pulse time-dependent plasticity mechanism. The training data set is constructed based on the attribute information of the target item and the user portrait information, and the synaptic weight of the pulse neural network is updated, so that the user recommended model is obtained.
It improves the accuracy of the model calculation results, reduces the risk of overfitting, and enhances the accuracy of recommendations.
Smart Images

Figure CN119740616A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a training method for a user recommendation model, a coupon recommendation method and a device. Background Art
[0002] Currently, since the interaction data between users and items is often sparse, most user recommendation models perform poorly in the face of a lack of data, making it difficult to accurately predict recommended users and prone to overfitting, resulting in recommendation bias.
[0003] In the process of implementing the present invention, the inventors found that there are at least the following problems in the related art:
[0004] The amount of training sample data required for the recommendation model is large, and the model calculation results are inaccurate and prone to overfitting. Summary of the invention
[0005] In view of this, the embodiments of the present invention provide a training method for a user recommendation model, a coupon recommendation method and a device, which can perform unsupervised training by relying on a small amount of unlabeled samples and using a pulse time-dependent plasticity mechanism when there is a lack of massive training data, thereby improving the accuracy of the model calculation results and preventing overfitting.
[0006] To achieve the above object, according to one aspect of an embodiment of the present invention, a method for training a user recommendation model is provided, comprising:
[0007] A first training data set is constructed based on the attribute information of the target item, and a second training data set is constructed based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target user includes users who have placed an order and users who have added items to a purchase;
[0008] updating the synaptic weights of a pre-constructed spiking neural network using a spike timing-dependent plasticity mechanism according to the first training data set;
[0009] The second training data set is input into the updated spiking neural network to train and obtain a user recommendation model.
[0010] Optionally, constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item includes:
[0011] Based on the target user's portrait information corresponding to the target item, the target user is divided into one or more user groups, and a user group label of each user group is determined;
[0012] According to the user group labels of each user group, labels are added to the target items to obtain the user group label results of the target items;
[0013] A second training data set is constructed based on the attribute information of each target item and the user group label result.
[0014] Optionally, a pre-built spiking neural network is obtained by:
[0015] Define the basic framework of the spiking neural network; the basic framework includes input layer, excitation layer and inhibition layer;
[0016] Establish synaptic connections between neurons in the input layer, the excitatory layer, and the inhibitory layer; wherein the neurons in the input layer are connected to the neurons in the excitatory layer via presynaptic connections, and the neurons in the excitatory layer are connected to the neurons in the inhibitory layer via postsynaptic connections;
[0017] A spiking neural network is constructed based on the connection results.
[0018] Optionally, updating the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set comprises:
[0019] Inputting the first training data set into a pre-built spiking neural network to determine a pre-synaptic trace value and a post-synaptic trace value;
[0020] The synaptic weights of the spiking neural network are updated according to the trace values of the pre-synaptic and the post-synaptic.
[0021] Optionally, before updating the synaptic weights of the pre-constructed spiking neural network using the spike time-dependent plasticity mechanism according to the first training data set, the method further includes:
[0022] The synaptic weights from the input layer to the excitatory layer are initialized using a random strategy, or the synaptic weights from the excitatory layer to the inhibitory layer and the synaptic weights from the inhibitory layer to the excitatory layer are initialized using a preset experimental strategy to update the initialized synaptic weights of the pre-constructed spiking neural network.
[0023] Optionally, the second training data set is input into the updated spiking neural network to train a user recommendation model, including:
[0024] Inputting the second training data set into the updated spiking neural network, and determining the pulse intensity ratio corresponding to the neurons in the excitatory layer of the updated spiking neural network;
[0025] The target items in the second training data set are grouped according to the pulse intensity ratio, and a user recommendation model is obtained by training based on the grouping results.
[0026] According to a second aspect of an embodiment of the present invention, a coupon recommendation method is provided, comprising:
[0027] Obtain attribute information of items to be recommended;
[0028] Determine a recommended user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention;
[0029] The obtained available coupons for the recommended items are pushed to the recommending users corresponding to the recommended items.
[0030] According to a third aspect of an embodiment of the present invention, there is provided a training device for a user recommendation model, comprising:
[0031] A construction module is used to construct a first training data set based on the attribute information of the target item, and to construct a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target user includes users who have placed an order and users who have added items to a purchase;
[0032] An updating module, configured to update the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set;
[0033] The training module is used to input the second training data set into the updated spiking neural network to train and obtain a user recommendation model.
[0034] According to a fourth aspect of an embodiment of the present invention, a coupon recommendation device is provided, including:
[0035] An acquisition module is used to obtain attribute information of items to be recommended;
[0036] A determination module, used to determine a recommendation user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention;
[0037] The recommendation module is used to push the obtained available coupons of the recommended items to the recommending users corresponding to the recommended items.
[0038] According to a fifth aspect of an embodiment of the present invention, there is provided an electronic device, including:
[0039] one or more processors;
[0040] a storage device for storing one or more programs,
[0041] When one or more programs are executed by one or more processors, the one or more processors implement the method of any of the above embodiments.
[0042] According to a sixth aspect of an embodiment of the present invention, there is provided a computer-readable medium on which a computer program is stored, and when the program is executed by a processor, the method of any of the above embodiments is implemented.
[0043] According to a seventh aspect of an embodiment of the present invention, there is provided a computer program product, including a computer program, which implements the method of any of the above embodiments when the computer program is executed by a processor.
[0044] An embodiment of the above invention has the following advantages or beneficial effects: by constructing a first training data set based on the attribute information of the target item, and constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; the target user includes users who have placed an order and users who have added to a purchase; according to the first training data set, the synaptic weights of the pre-constructed spiking neural network are updated by using the pulse time-dependent plasticity mechanism; the second training data set is input into the updated spiking neural network to train and obtain a user recommendation model; thereby, when there is a lack of massive training data, unsupervised training can be performed by using a small amount of unlabeled samples using the pulse time-dependent plasticity mechanism, thereby improving the accuracy of the model calculation results and not prone to overfitting. By obtaining the attribute information of the item to be recommended; based on the attribute information of the item to be recommended, using the user recommendation model, determining the recommended user corresponding to the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention; the available coupons of the item to be recommended obtained are pushed to the recommended user corresponding to the item to be recommended; thereby, the accuracy of the coupon recommendation and the user experience can be improved.
[0045] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0047] Figure 1 is a schematic diagram of the main process of a training method for a user recommendation model according to an embodiment of the present invention;
[0048] Figure 2 is a schematic diagram of the main process of the coupon recommendation method according to an embodiment of the present invention;
[0049] Figure 3 is a schematic diagram of the main process of a coupon recommendation method according to a preferred embodiment of the present invention;
[0050] Figure 4 is a schematic diagram of main modules of a training device for a user recommendation model according to an embodiment of the present invention;
[0051] Figure 5 is a schematic diagram of main modules of a coupon recommendation device according to an embodiment of the present invention;
[0052] Figure 6 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0053] Figure 7 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION
[0054] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0055] It should be noted that the acquisition, storage and application of personal information etc. involved in the embodiments of the present invention are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
[0056] At present, since the interaction data between users and items is often sparse, most user recommendation models perform poorly in the face of lack of data, making it difficult to accurately predict recommended users and prone to overfitting, resulting in recommendation bias. Therefore, the amount of training sample data required for the recommendation model is large, and the model calculation results are inaccurate and prone to overfitting.
[0057] In view of this, according to a first aspect of an embodiment of the present invention, a method for training a user recommendation model is provided.
[0058] Figure 1 FIG. 1 is a schematic diagram of the main process of the training method of the user recommendation model according to an embodiment of the present invention. Figure 1 As shown, the training method of the user recommendation model according to the embodiment of the present invention mainly includes the following steps S101 to S103.
[0059] Step S101, constructing a first training data set based on the attribute information of the target item, and constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target users include users who have placed an order and users who have added items to a cart.
[0060] The target items include the inventory units (SKUs) that need to be analyzed and processed in the system. They can be items whose activity exceeds a preset threshold. For example, products with high user access frequency, high number of additions to shopping carts, or large order volumes can be regarded as target items. Attribute information is a variety of data that describes the characteristics of the target items, including but not limited to the classification, price, brand, specification, inventory status, sales history, etc. of the items. These attribute information can help to comprehensively characterize the characteristics of the target items to construct the first training data set. The first training data set is a basic training data set built on the target items based on their attribute information. Specifically, the attribute information of the target items can be extracted from the database, and combined with the screening condition that the activity exceeds the preset threshold, the target items with high user attention or commercial value can be filtered out; the attribute information of these target items is organized into a first training data set available to the model in a specific structured format (such as a table or feature vector).
[0061] Target users refer to the user groups associated with the target items, mainly including users who have placed orders, added items to cart, and favorited items, etc. The data of these users can reflect the popularity and potential demand of the target items. Portrait information is a multi-dimensional description of the behavior and feature data of the target users, including the user's age, gender, geographic location, purchase preferences, browsing history, purchase frequency, payment habits, etc. This information is generated by recording and analyzing user behavior and can be used as an important basis for constructing the second training data set. The second training data set is a comprehensive data set constructed on the basis of the first training data set combined with the portrait information of the target users, which can be used to learn the association between items and users. Specifically, relevant data can be extracted from the interaction history of the target items and target users, and the attribute information of the items and the user portrait information can be combined to generate feature vectors that describe the item-user matching characteristics; these features can be combined with the user's behavior labels (such as whether to place an order, whether to add items to cart, etc.) to construct the second training data set for supervised learning.
[0062] Step S102, updating the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set.
[0063] Spike-Timing-Dependent Plasticity (STDP) is a biologically inspired learning mechanism that dynamically adjusts the weight of synapses by simulating the time difference between the pulses of presynaptic neurons and postsynaptic neurons, reflecting the causal relationship and timing dependency between neurons. Presynaptic neurons can also be called presynapses, and postsynaptic neurons can also be called postsynapses. When the presynapse fires a pulse before the postsynapse, the synaptic weight is enhanced; otherwise, the synaptic weight is weakened. The STDP mechanism gradually optimizes the connection strength of the neural network by adjusting the synaptic weights, so that it can more effectively adapt to the characteristics of the input data. The pre-built spiking neural network is a computational model designed based on the behavior of biological neural networks, with the capabilities of pulse firing, timing processing, and dynamic weight updating. Unlike traditional neural networks, spiking neural networks transmit and process information through discrete pulse signals, which can capture temporal dynamic characteristics more efficiently. When constructing a spiking neural network, the number and structure of neurons in the input layer, hidden layer, and output layer can be set according to specific task requirements, and the synaptic connections between layers and their initial weights can be initialized. Synaptic weight is a parameter that connects two neurons and indicates the strength of the connection between them. The change of weight directly affects the propagation and activation of pulse signals in the network, and is the core optimization goal of model training.
[0064] Based on the first training data set, the synaptic weights are updated using the STDP mechanism. When the spiking neuron emits a pulse, the trace value of the presynapse (indicating the pulse history of the presynaptic neuron) and the trace value of the postsynapse (indicating the pulse history of the postsynaptic neuron) can be calculated. Each time the current synapse or postsynapse emits a pulse, its corresponding trace value will be reset to 1, and then exponentially decay under the control of the time constant. Based on these two trace values, the increment of the synaptic weight is calculated in combination with the STDP learning rule, thereby realizing dynamic adjustment of the weight. The timestamps of the presynaptic and postsynaptic pulses can also be recorded to calculate the time interval between the two. When the time interval is a positive value, the weight enhancement process is triggered; when the time interval is a negative value, the weight inhibition process is triggered. By designing an asymmetric learning window, the amplitude of the weight change is adjusted according to the size of the time interval, so that the network can more sensitively reflect the characteristics of the time series input. In the above manner, the STDP mechanism is used to update the weights of the pre-constructed spiking neural network, so that it can gradually adapt to the pattern characteristics in the first training data set, providing a basis for subsequent model optimization and task application.
[0065] Step S103, inputting the second training data set into the updated spiking neural network to train and obtain a user recommendation model.
[0066] The second training data set is input into the pulse neural network that has completed the weight update, and through further training, a model that can realize user recommendation is constructed. Specifically, it can be a user recommendation model training based on supervised learning, and the second training data set contains a clear input and output mapping relationship, such as the target user's preference for the target item (rating, click-through rate or purchase behavior, etc.). During the training process, the target user's portrait information and the attribute information of the target item are used as input, and the user's interactive behavior with the item is used as the output target. Through the forward propagation process of the pulse neural network, the network prediction results are calculated and compared with the actual target, and a specific error function (such as mean square error or cross entropy) is used to evaluate the performance of the model. During the error back propagation process, the synaptic weights of the network are further adjusted through an optimizer (such as an adaptive algorithm based on the characteristics of the pulse signal), thereby improving the recommendation effect of the model. It can also be feature extraction and clustering based on unsupervised learning. When the second training data set lacks clear user behavior labels, the temporal coding ability and clustering characteristics of the pulse neural network can be used to perform unsupervised learning on the data. The target user's portrait information and the target item's attribute information are encoded as pulse inputs through time series signals. After entering the network, the excitatory neurons will be clustered into different response groups based on the similarity of the input pulses. By observing the triggering mode and output pulse intensity of the neurons, users can be grouped into specific interest groups, and target items can be matched to the corresponding target user groups. This method can be used in scenarios where the data scale is large and labels are difficult to obtain, and it can effectively capture the potential connection between users and items.
[0067] The embodiment of the present invention constructs a first training data set based on the attribute information of the target item, and constructs a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; the target users include users who have placed an order and users who have added items to a cart; according to the first training data set, the pulse time-dependent plasticity mechanism is used to update the synaptic weights of the pre-constructed pulse neural network; the second training data set is input into the updated pulse neural network to train and obtain a user recommendation model; thereby, when there is a lack of massive training data, unsupervised training can be performed by relying on a small amount of unlabeled samples using the pulse time-dependent plasticity mechanism, thereby improving the accuracy of the model calculation results and preventing overfitting.
[0068] Optionally, a second training data set is constructed based on the attribute information of the target item and the portrait information of the target user corresponding to the target item, including: dividing the target users into one or more user groups based on the portrait information of the target users corresponding to the target item, and determining the user group label of each user group; adding labels to the target items according to the user group labels of each user group to obtain user group label results of the target items; and constructing the second training data set based on the attribute information of each target item and the user group label results.
[0069] In this embodiment, the target user can be divided into one or more user groups based on the target user's portrait information, based on a specific classification algorithm (such as K-means clustering) or a rule division strategy (such as age group, consumption ability). The division of user groups allows the diversified characteristics of the target users to be effectively aggregated, which is convenient for subsequent processing. At the same time, in order to identify the characteristics of different user groups, a unique user group label is assigned to each user group. The user group label can be a numerical or categorical identifier, indicating the common characteristics of the group of users, such as high-frequency purchasing users, interest-focused users, etc. These user group labels are associated with the target items, and labels are added to the target items through the interactive behaviors of the target users and the target items (such as purchases, clicks, collections, etc.), thereby obtaining user group label results. This process reflects the preference or matching degree of different user groups for the target items, and improves the accuracy and diversity of the target item labels. For example, a target item may be consumed by multiple user groups at the same time, and its label can reflect the proportion or preference of these user groups. Based on the attribute information of each target item and the generated user group label results, a second training data set is constructed. By combining the inherent attributes of the items and the demand characteristics of the user group, the second training data set can capture the deeper connection between the target users and the target items, providing a rich data foundation for subsequent recommendation model training, which not only improves the effectiveness of the data, but also enhances the accuracy and interpretability of the model in the recommendation process.
[0070] Optionally, the pre-constructed spiking neural network is obtained by the following steps: defining a basic framework of the spiking neural network; wherein the basic framework includes an input layer, an excitatory layer and an inhibitory layer; establishing synaptic connections for neurons in the input layer, the excitatory layer and the inhibitory layer; wherein the neurons in the input layer are connected to the neurons in the excitatory layer through pre-synapses, and the neurons in the excitatory layer are connected to the neurons in the inhibitory layer through post-synapses; and constructing the spiking neural network based on the connection results.
[0071] The pre-built spiking neural network is gradually implemented by clarifying the basic framework and establishing synaptic connections to provide efficient neural computing capabilities and accurate task modeling capabilities. First, the basic framework of the spiking neural network is defined, including the input layer, excitatory layer, and inhibitory layer; the input layer can be used to receive external data, such as attribute information or label information in the training sample, and convert these data into pulse signals, which are transmitted to the network in the form of neural activity; the excitatory layer can be used to simulate the excitation behavior of biological neurons, and complete the main feature extraction and information processing by integrating input pulses and triggering output pulses; the inhibitory layer can be used to regulate the balance and stability of the network, and prevent the network from falling into a state of local over-activation by inhibiting some excessive neuronal activities. After clarifying the basic framework, synaptic connections are established for neurons in each layer. The neurons in the input layer are connected to the neurons in the excitatory layer through presynapses. These connections are directional and carry synaptic weights to simulate the strength of information transmission. The neurons in the excitatory layer are connected to the neurons in the inhibitory layer through postsynapses. These connections not only transmit information, but also regulate the overall dynamic behavior of the network. The establishment of these synaptic connections can be completed through random initialization, configuration based on structural rules, or preset strategies combined with task requirements. In addition, in order to enhance the adaptability and learning ability of the network, the synaptic connections can be designed to be plastic and dynamically updated based on specific mechanisms (such as STDP) during training. Based on these connection results, the neurons in the input layer, excitation layer, and inhibition layer are organized according to the framework and connection rules to complete the construction of the spiking neural network, which not only has the ability to simulate the characteristics of biological nervous systems, but also can provide support for complex tasks (such as feature extraction or classification).
[0072] Optionally, the synaptic weights of a pre-constructed spiking neural network are updated using a pulse time-dependent plasticity mechanism according to the first training data set, including: inputting the first training data set into the pre-constructed spiking neural network to determine the trace values of the pre-synapse and the post-synapse; and updating the synaptic weights of the spiking neural network according to the trace values of the pre-synapse and the post-synapse.
[0073] When updating the synaptic weights of the pre-constructed spiking neural network, the adaptive adjustment of the neural network is effectively achieved through the spike time-dependent plasticity (STDP) mechanism. The first training data set is input into the pre-constructed spiking neural network, and the pulse history behavior of the presynaptic neuron and the postsynaptic neuron is recorded by the activity of the neuron, so as to determine the trace value of the presynapse and the trace value of the postsynapse. The trace value of the presynapse is used to describe the pulse triggering characteristics of the presynaptic neuron, while the trace value of the postsynapse reflects the response characteristics of the postsynaptic neuron. These trace values decay exponentially through a time constant to simulate the dynamic activity law of biological neurons. According to these trace values, the synaptic weights are adjusted through the STDP rule. Specifically, when the pulse triggering time of the presynaptic and postsynaptic neurons is close, the synaptic weight will be strengthened, otherwise it will be weakened. This weight update method not only simulates the learning mechanism between biological neurons, but also can capture the implicit time series characteristics in the input data. Through multiple rounds of weight updates, the spiking neural network gradually optimizes its internal connection mode and improves the feature extraction and pattern recognition capabilities of the attribute information of the target object.
[0074] Optionally, before updating the synaptic weights of the pre-constructed spiking neural network using the pulse time-dependent plasticity mechanism according to the first training data set, it also includes: initializing the synaptic weights from the input layer to the excitatory layer using a random strategy, or initializing the synaptic weights from the excitatory layer to the inhibitory layer and the synaptic weights from the inhibitory layer to the excitatory layer through a preset experimental strategy to update the initialized synaptic weights of the pre-constructed spiking neural network.
[0075] Before updating the synaptic weights using the pulse time-dependent plasticity mechanism, the synaptic weights in the network can be initialized to make the spiking neural network have a reasonable initial state. The synaptic weights from the input layer to the excitatory layer are initialized by a random strategy, which can give the network a certain degree of randomness and avoid the limitations of network learning caused by fixed weights. At the same time, the synaptic weights from the excitatory layer to the inhibitory layer can also be set by a preset experimental strategy. They need to be large enough to ensure that the connected inhibitory neurons also emit pulses when the excitatory neurons emit pulses, so they are set to a larger value. The synaptic weights from the inhibitory layer to the excitatory layer are set experimentally to inhibit other excitatory neurons from emitting pulses. This weight initialization method not only lays a balanced foundation for the subsequent synaptic weight updates, but also effectively improves the convergence speed and performance of the network, so that the network has stronger plasticity and adaptability in the early stages of training, thereby enhancing the learning ability of the spiking neural network for complex patterns.
[0076] Optionally, the second training data set is input into the updated spiking neural network to train a user recommendation model, including: inputting the second training data set into the updated spiking neural network to determine the pulse intensity ratio corresponding to the neurons in the excitation layer of the updated spiking neural network; grouping the target items in the second training data set according to the pulse intensity ratio, and training a user recommendation model based on the grouping results.
[0077] After the second training data set is input into the updated spiking neural network, the pulse intensity ratio of the neurons in the excitation layer is first determined through the network, which reflects the degree of association between different target items and user groups. The target items in the training data are grouped according to the pulse intensity ratio, so that each group of target items corresponds to a specific user group label. Based on this grouping result, the spiking neural network is further trained to enhance its ability to model the relationship between target items and user groups, and finally a user recommendation model that can accurately match target items and user needs is constructed, so that the model can better explore the characteristics of target items and achieve efficient recommendations.
[0078] According to a second aspect of an embodiment of the present invention, a coupon recommendation method is provided.
[0079] Figure 2 is a schematic diagram of the main process of the coupon recommendation method according to an embodiment of the present invention; Figure 2 As shown, the coupon recommendation method according to the embodiment of the present invention mainly includes the following steps S201 to S203.
[0080] Step S201, obtaining attribute information of the item to be recommended.
[0081] Step S202, based on the attribute information of the item to be recommended, using the user recommendation model, determine the recommendation user corresponding to the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiments of the present invention.
[0082] Step S203: Push the obtained available coupons of the recommended items to the recommending users corresponding to the recommended items.
[0083] In this embodiment, step S201 first obtains the attribute information of the item to be recommended, which includes key information such as the type, price, brand, and activity of the item. Step S202 identifies the recommended user who best matches the item based on the attribute information of the item to be recommended through the user recommendation model trained previously. The recommendation model determines the user group that is most likely to be interested in the item by analyzing the user's historical behavior, interest preferences and other characteristics. Finally, in step S203, the available coupons matched to the item to be recommended based on the recommendation results are pushed to the recommending user. These coupons will motivate the recommending user to make a purchase, thereby improving the recommendation effect of the item and the user's purchase conversion rate. The recommendation model is used to accurately push the most suitable coupons for each item to be recommended, thereby improving the marketing effect and user experience.
[0084] This embodiment obtains attribute information of the item to be recommended; determines the recommended user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention; and pushes the obtained available coupons of the item to be recommended to the recommended user corresponding to the item to be recommended; thereby improving the accuracy of the coupon recommendation and the user experience.
[0085] Figure 3 FIG. 1 is a schematic diagram of the main process of the coupon recommendation method according to a preferred embodiment of the present invention. Figure 3 As shown, it specifically includes three parts: data preparation, recommendation user model training based on the constructed spiking neural network (SNN), and coupon recommendation.
[0086] In the data preparation step, the active SKUs in the SKU (stock keeping unit) active information table and the corresponding users who have added to cart and placed orders are used to construct a data set. This embodiment mainly collects nearly 500 features of the SKU's basic information, advertising words, size, color, place of shipment, warranty, price, etc. Each feature is mapped into a specific feature value according to the dimension table, and all feature values are concatenated into a feature vector sequence. The vector length is the number of neurons in the input layer. At the same time, the feature vector is pulse-encoded by the pulse neural network simulator brain2. This embodiment uses Poisson coding to pulse-encode the feature values. The simulator will encode the input into a pulse sequence that conforms to the Poisson distribution, and associate the users who have purchased and added to cart under these SKUs. These users are divided into user groups. The user group identifier is similar to (age_education_children_3-month average order value_promotion sensitivity_personal user life cycle). Each identifier is equivalent to a label, and then the SKU is labeled according to the user group to construct a data set. In this embodiment, 1000 SKUs are used to construct a data set and label them. The input of each SKU is a one-dimensional vector after nearly 500 features are encoded, and the label is the user group to which the current SKU belongs. In addition, the first 80% can be used as a training set and the last 20% as a test set.
[0087] When constructing a spiking neural network (SNN), this embodiment adopts a network structure of three layers: input layer I (coding layer) - excitation layer E (classification layer) - inhibition layer L. The input layer mainly realizes the information encoding of samples to pulse sequences; the neurons in the excitation layer receive pulses transmitted by synapses, causing changes in their membrane potential. When the membrane potential reaches the threshold, a pulse is generated, and the excitation pulse continues to be transmitted to the next layer; the inhibition layer simulates the lateral inhibition and competitive learning mechanism between neurons in the brain-like neuron system. In addition, the above three types of synaptic weights in SNN are initialized in different ways. First, the synaptic weights from the input layer to the excitation layer can be randomly initialized, or the training sample initialization method described in detail below is used; secondly, the synaptic weights from the excitation layer to the inhibition layer are set experimentally, which need to be large enough to ensure that when the excitatory neurons emit pulses, the connected inhibitory neurons also emit pulses; finally, the synaptic weights from the inhibition layer to the excitation layer are set experimentally to inhibit other excitatory neurons from emitting pulses.
[0088] First, the LIF model (Leaky Integrate-and-Fire) is selected to simulate neuron dynamics. In this embodiment, neurons are composed of excitatory neurons and inhibitory neurons, and synapses are composed of excitatory synapses and inhibitory synapses. The membrane potential V e Described by equation (1):
[0089]
[0090] Among them, E rest is the resting membrane potential, E exc and E inh is the equilibrium potential of the excitatory and inhibitory synapses, g e and g i and are the conductances of the excitatory and inhibitory synapses, respectively, and τ e is the time constant of the membrane potential of an excitatory neuron. Usually, driven by the dynamics of equation (1), the membrane potential changes exponentially. When the membrane potential of a neuron exceeds its threshold V th The neuron fires a pulse when V reset , can be set equal to the resting membrane potential E rest For a few milliseconds after the reset, the neuron remains in its refractory period and can no longer fire. All synaptic dynamics are simulated by changes in conductance. The conductance g of an excitatory synapse is e The dynamics are shown in equation (2), and under normal circumstances, it decays exponentially.
[0091]
[0092] where τ is the time constant for the decay of the excitatory synaptic conductance.
[0093] ge
[0094] When touched, the conductivity g e It will increase instantly as the synaptic weight ω increases.
[0095] g e =g e +ω (3)
[0096] If the neuron is an inhibitory neuron, the conductance g is updated using equations similar to those in equations (2) and (3). i , but using a different time constant τ gi .
[0097]
[0098] In a similar way, when any pulse arrives at a synapse, it increases the weight of the synapse. In the input layer, there are N neurons corresponding to a one-dimensional vector of input length N. Each neuron takes an input value and calculates it as a pulse probability, performs Poisson encoding and outputs a pulse sequence within a time period T. Δt is the time step. The number of pulses emitted by the input neuron within the time period is Poisson distributed, and then the input value x i Calculate the probability p of generating a pulse at each step i .
[0099]
[0100] The pulses generated in each step during the time period constitute a coded pulse train.
[0101] There are M excitatory neurons in the excitatory layer, and each neuron operates according to the LIF model in equation (1). All excitatory neurons are fully connected to input neurons and are simultaneously connected to inhibitory neurons in a one-to-one manner, that is, each pulse in an excitatory neuron will trigger its corresponding inhibitory neuron to emit a pulse. When the connected input neuron emits a pulse, the excitatory neuron E k The conductance value of will change according to the synaptic weight as shown in equation (3), and then its membrane potential will change as shown in equation (1). The membrane potential threshold determines whether the pulse is sent to the neuron I in the inhibitory layer. k Each inhibitory neuron I k Will connect back to all excitatory neurons E j (j≠k), except for the excitatory neuron that is forwardly connected to it. This means that the excitatory neuron and the inhibitory neuron are forwardly connected through excitatory synapses, while the inhibitory neuron is backwardly connected through inhibitory synapses. This connection provides lateral inhibition and leads to competition between excitatory neurons.
[0102] Using the simplified LIF model, the membrane potential of an inhibitory neuron can be modeled as shown in equation (6):
[0103]
[0104] Among them, τ i is the time constant of the membrane potential, E′ rest and E′ exc is the resting potential and equilibrium potential of the inhibitory neuron. The threshold of the inhibitory neuron is V′ th , the reset potential is V′ reset .
[0105] Since SNN is a biological model, the parameters from Eq. (1) to Eq. (4) and Eq. (6) are initialized to biologically reasonable ranges, including resting potential and equilibrium potential, E rest 、E exc 、E inh , E′ rest , E′ exc , the time constant of the membrane potential and the conductance, τ e , τ i , τ ge , τ gi In this embodiment, the specific values of the test are included in Table 1 below based on the suggestions obtained from many biological test results. In excitatory neurons, the distance |E rest -Vth |, represents how much input the neuron needs to integrate to generate a spike. Therefore, the threshold V th It should be selected according to the actual signal conditions and can be a fixed value or adaptively adjusted during network updates. Generally speaking, the pulse triggering of inhibitory neurons depends on the pulse triggering of excitatory neurons, which means that the discharge threshold of excitatory neurons is more important. Therefore, V th Adaptively update V′ during learning, which will be described in detail in the next section. th In this paper, it is set to a fixed value. Reset potential V reset and V′ reset are always set equal to the resting potential, E rest and E′ rest Also set equal to the resting potential.
[0106] Table 1 Test specific values
[0107]
[0108] The weights are updated using an unsupervised learning mechanism, namely the spike time-dependent plasticity STDP mechanism, which is used to update the synaptic weights connecting the input layer and the excitatory layer neurons. In SNN, the synaptic weights connecting the excitatory layer and the inhibitory layer do not need to be updated. In this embodiment, a symmetric update mechanism is used, in which the dynamic changes of the weights are calculated using the pre-synaptic and post-synaptic trace values. When the pre-synaptic pulse arrives at the synapse, the post-synaptic trace value x is used to update the weights. post Calculate the change in weights:
[0109] Δw pre =-η pre x post w μ (7)
[0110] Among them, η pre is the learning rate for the presynaptic spike, and μ represents the dependence of the current weight change on the previous weight w.
[0111] When the postsynaptic neuron fires a spike, the value x is passed through the presynaptic trace pre Calculate the change in weights:
[0112] Δw post =η post (x pre -x tar )(w max -w) μ (8)
[0113] where η post is the learning rate for the presynaptic spike, w max is the maximum weight, x taris the preset target value of the presynaptic trace value. The higher the target value, the smaller the change in synaptic weight. pre and the postsynaptic trace value x post , simulating the pulse history of the pre-synaptic and post-synaptic neurons. When the pre-synaptic neuron emits a pulse, x pre will be reset to 1. Similarly, when the postsynaptic neuron emits a pulse, x post will be reset to 1, and the rest of the time they decay exponentially with the time constant, as shown in Equations (9) and (10).
[0114]
[0115] The above learning rule ensures that the synapses directly connected to the current postsynaptic neuron by the presynaptic neuron that rarely causes the postsynaptic neuron to emit a spike will become increasingly disconnected, that is, the current synaptic weight will become smaller and smaller, which is particularly useful when the postsynaptic neuron is rarely active. Otherwise, the current synapse will become increasingly important, that is, the synaptic weight will become larger and larger.
[0116] At the same time, the neuron threshold needs to be updated. The inhomogeneity of the input signal causes each excitatory neuron to have a different pulse firing frequency, and lateral inhibition further increases this difference. However, in order to prevent some neurons from dominating the response mode, we hope that the pulse firing frequency of all neurons is roughly the same while ensuring the differentiation of the neuron's receptive field. To achieve this, we use an adaptive membrane potential threshold. Specifically, after an excitatory neuron fires a pulse, the threshold of the current excitatory neuron increases by θ.
[0117] V th =V th +θ (11)
[0118] where the change in θ is similar to the presynaptic trace value x pre and the postsynaptic trace value x post of the change law, but with different attenuation constants τ θ Each time an excitatory neuron fires, its threshold increases by θ and θ is set to θ th , when the excitatory neuron has no trigger pulse, θ decays exponentially as shown in equation (12).
[0119]
[0120] Therefore, the more times an excitatory neuron spikes, the higher its membrane potential threshold becomes, and in turn, the excitatory neuron requires more input to reach a spike in the near future. Using this dynamic threshold mechanism, the neuron's spike firing rate is limited because the conductance-based synaptic model limits the maximum membrane potential to a value just below the excitatory equilibrium potential in equation (1), namely, Eexc Once the neuron membrane threshold is close to or above the threshold E exc , it will reduce the pulse firing frequency or even stop the discharge completely until θ is sufficiently reduced.
[0121] Classify the SKUs into corresponding user groups. After the network learning is completed, the SKUs are grouped using the pulse intensity ratio of the output of each excitatory neuron. In the labeling process, some labeling data in the training samples are used to label each neuron as a neuron of a specific user group according to the actual pulse triggering intensity of the type of labeled sample. In the test, the neuron with the maximum pulse triggering intensity for a specific input is regarded as the neuron of its user group.
[0122] In the labeling step, the length of the output vector is the same as the number of excitatory neurons, and each value in the vector represents the number of pulses emitted by the current excitatory neuron in the time period. When all the labeled sku information is input into the network, the total number of pulses emitted by each type of sample in each excitatory neuron is divided by the number of samples of that type, and then the pulse response intensity of each type of sample in each excitatory neuron is obtained.
[0123]
[0124] Where is the j-th excitatory neuron subscript, representing the j-th excitatory neuron, k is the sample type, n k is the number of samples of the kth type, F j,k is the pulse triggering intensity of the j-th excitatory neuron for the k-th type sample, num i,j,k is the number of pulses fired by the i-th sample of the k-th type in the j-th excitatory neuron. In this way, each neuron is labeled according to its maximum pulse triggering intensity for a specific type of sample, and the excitatory neurons are divided into four labeled groups.
[0125] In the test, when a test sample is input into the network, the output pulse number of each group of labeled neurons is calculated respectively, and the average trigger pulse number of each type of excitatory neurons is calculated, as shown in equation (14).
[0126]
[0127] Among them, num i,k is the number of output pulses of the i-th excitatory neuron in the k-th group of the test sample, M k is the number of labeled excitatory neurons in group k, Num k is the average number of output pulses of the kth group of the test sample. Then, the neuron category with the largest average number of pulse triggering times is used as the user group label of the current sample.
[0128] After the SKU is divided into the corresponding user group, the SKU is associated with the corresponding coupon, and then the coupon is recommended to the user group, which can increase the probability of users purchasing and placing orders.
[0129] According to a third aspect of an embodiment of the present invention, a training device for a user recommendation model is provided.
[0130] Figure 4 is a schematic diagram of the main modules of the training device of the user recommendation model according to an embodiment of the present invention, such as Figure 4 As shown, a training device 400 for a user recommendation model includes:
[0131] A construction module 401 is used to construct a first training data set based on the attribute information of the target item, and to construct a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target user includes users who have placed an order and users who have added items to a purchase;
[0132] An updating module 402, configured to update the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set;
[0133] The training module 403 is used to input the second training data set into the updated spiking neural network to train and obtain a user recommendation model.
[0134] Optionally, the construction module 401 is further used for:
[0135] Based on the target user's portrait information corresponding to the target item, the target user is divided into one or more user groups, and a user group label of each user group is determined;
[0136] According to the user group labels of each user group, labels are added to the target items to obtain the user group label results of the target items;
[0137] A second training data set is constructed based on the attribute information of each target item and the user group label result.
[0138] Optionally, the apparatus 400 further includes an establishing module, and the establishing module is used to:
[0139] Define the basic framework of the spiking neural network; the basic framework includes input layer, excitation layer and inhibition layer;
[0140] Establish synaptic connections between neurons in the input layer, the excitatory layer, and the inhibitory layer; wherein the neurons in the input layer are connected to the neurons in the excitatory layer via presynaptic connections, and the neurons in the excitatory layer are connected to the neurons in the inhibitory layer via postsynaptic connections;
[0141] A spiking neural network is constructed based on the connection results.
[0142] Optionally, the updating module 402 is further configured to:
[0143] Inputting the first training data set into a pre-built spiking neural network to determine a pre-synaptic trace value and a post-synaptic trace value;
[0144] The synaptic weights of the spiking neural network are updated according to the trace values of the pre-synaptic and the post-synaptic.
[0145] Optionally, the apparatus 400 further includes an initial module, and the initial module is used to:
[0146] The synaptic weights from the input layer to the excitatory layer are initialized using a random strategy, or the synaptic weights from the excitatory layer to the inhibitory layer and the synaptic weights from the inhibitory layer to the excitatory layer are initialized using a preset experimental strategy to update the initialized synaptic weights of the pre-constructed spiking neural network.
[0147] Optionally, the training module 403 is further used for:
[0148] Inputting the second training data set into the updated spiking neural network, and determining the pulse intensity ratio corresponding to the neurons in the excitatory layer of the updated spiking neural network;
[0149] The target items in the second training data set are grouped according to the pulse intensity ratio, and a user recommendation model is obtained by training based on the grouping results.
[0150] It should be noted that the specific implementation content of the training device for the user recommendation model in the embodiment of the present invention has been described in detail in the above training method for the user recommendation model, so the repeated content will not be described again here.
[0151] According to a fourth aspect of an embodiment of the present invention, a coupon recommendation device is provided.
[0152] Figure 5 is a schematic diagram of the main modules of the coupon recommendation device according to an embodiment of the present invention. Figure 5 As shown, a coupon recommendation device 500 includes:
[0153] The acquisition module 501 is used to acquire the attribute information of the item to be recommended;
[0154] A determination module 502 is used to determine a recommendation user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention;
[0155] The recommendation module 503 is used to push the obtained available coupons of the recommended items to the recommending users corresponding to the recommended items.
[0156] It should be noted that the specific implementation content of the coupon recommendation device in the embodiment of the present invention has been described in detail in the above coupon recommendation method, so the repeated content will not be described again here.
[0157] According to a fifth aspect of an embodiment of the present invention, there is provided an electronic device, including:
[0158] one or more processors;
[0159] a storage device for storing one or more programs,
[0160] When one or more programs are executed by one or more processors, the one or more processors implement the method provided by the first aspect of the embodiment of the present invention and / or the second aspect of the embodiment of the present invention.
[0161] According to a sixth aspect of an embodiment of the present invention, a computer-readable medium is provided, on which a computer program is stored. When the program is executed by a processor, the method provided by the first aspect of the embodiment of the present invention and / or the second aspect of the embodiment of the present invention is implemented.
[0162] According to a seventh aspect of an embodiment of the present invention, a computer program product is provided, including a computer program, which, when executed by a processor, implements the method provided by the first aspect of the embodiment of the present invention and / or the second aspect of the embodiment of the present invention.
[0163] Figure 6 An exemplary system architecture 600 is shown to which the method for training a user recommendation model or the apparatus for training a user recommendation model according to an embodiment of the present invention can be applied.
[0164] like Figure 6 As shown, system architecture 600 may include terminal devices 601, 602, 603, network 604 and server 605. Network 604 is used to provide a medium for communication links between terminal devices 601, 602, 603 and server 605. Network 604 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0165] Users can use terminal devices 601, 602, and 603 to interact with server 605 through network 604 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 601, 602, and 603, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only examples).
[0166] The terminal devices 601 , 602 , and 603 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers, etc.
[0167] The server 605 may be a server that provides various services, such as a backend management server (only an example) that provides support for shopping websites browsed by users using the terminal devices 601, 602, and 603. The backend management server may analyze and process the received data such as the model training request, and feed back the processing results (such as the user recommendation model - only an example) to the terminal device.
[0168] It should be noted that the training method of the user recommendation model provided in the embodiment of the present invention is generally run by the server 605 , and accordingly, the training device of the user recommendation model is generally set in the server 605 .
[0169] It should be noted that the coupon recommendation method provided in the embodiment of the present invention is generally executed by the server 605 , and accordingly, the coupon recommendation device is generally disposed in the server 605 .
[0170] It should be understood that Figure 6 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0171] Reference below Figure 7 , which shows a schematic diagram of the structure of a computer system 700 of a terminal device suitable for implementing an embodiment of the present invention. Figure 7 The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0172] like Figure 7 As shown, the computer system 700 includes a central processing unit (CPU) 701, which can execute various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 into a random access memory (RAM) 703. In the RAM 703, various programs and data required for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.
[0173] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN card, a modem, etc. The communication section 709 runs a communication process via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage section 708 as needed.
[0174] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for running the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 709, and / or installed from the removable medium 711. When the computer program is run by the central processing unit (CPU) 701, the above-mentioned functions defined in the system of the present invention are run.
[0175] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0176] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, functions and operations of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually run basically in parallel, and they can sometimes run in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that runs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0177] The modules involved in the embodiments of the present invention may be implemented in software or hardware. The modules described may also be arranged in a processor, for example, they may be described as: a processor including a construction module, an update module and a training module. The names of these modules do not, in some cases, constitute limitations on the modules themselves. For example, the training module may also be described as "a module for inputting a second training data set into an updated pulse neural network to train a user recommendation model". Alternatively, a processor includes an acquisition module, a determination module and a recommendation module, wherein the names of these modules do not, in some cases, constitute limitations on the modules themselves. For example, the recommendation module may also be described as "a module for pushing the acquired available coupons for the items to be recommended to the recommendation users corresponding to the items to be recommended".
[0178] As another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently and not be assembled into the device. The above computer-readable medium carries one or more programs. When the above one or more programs are executed by a device, the device includes: constructing a first training data set based on the attribute information of the target item, and constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; the target user includes an ordering user and an added purchase user; according to the first training data set, using the pulse time-dependent plasticity mechanism, the synaptic weights of the pre-constructed pulse neural network are updated; the second training data set is input into the updated pulse neural network to train and obtain a user recommendation model. Alternatively, the device implements the following method: obtaining the attribute information of the item to be recommended; determining the recommended user corresponding to the item to be recommended using the user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention; pushing the available coupons of the item to be recommended obtained to the recommended user corresponding to the item to be recommended.
[0179] The computer program product provided by the embodiment of the present invention includes a computer program. When the computer program is executed by a processor, it implements the user recommendation model training method in the embodiment of the first aspect of the present invention and / or the coupon recommendation method in the embodiment of the second aspect of the present invention.
[0180] According to the technical solution of the embodiment of the present invention, the following advantages or beneficial effects are achieved: by constructing a first training data set based on the attribute information of the target item, and constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; the target user includes users who have placed an order and users who have added to a purchase; according to the first training data set, the synaptic weights of the pre-constructed spiking neural network are updated by using the pulse time-dependent plasticity mechanism; the second training data set is input into the updated spiking neural network to train and obtain a user recommendation model; thereby, when there is a lack of massive training data, unsupervised training can be performed by using a small amount of unlabeled samples using the pulse time-dependent plasticity mechanism, thereby improving the accuracy of the model calculation results and not prone to overfitting. By obtaining the attribute information of the item to be recommended; based on the attribute information of the item to be recommended, using the user recommendation model, determining the recommended user corresponding to the item to be recommended; wherein the user recommendation model is obtained by any method in the first aspect of the embodiment of the present invention; the available coupons of the item to be recommended obtained are pushed to the recommended user corresponding to the item to be recommended; thereby, the accuracy of the coupon recommendation and the user experience can be improved.
[0181] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
[0182] It should be noted that the acquisition, storage and application of user personal information involved in the technical solution of the present disclosure are in compliance with the provisions of relevant laws and regulations and do not violate public order and good morals.
Claims
1. A method for training a user recommendation model, characterized in that: include: A first training data set is constructed based on the attribute information of the target item, and a second training data set is constructed based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target user includes users who have placed an order and users who have added items to a purchase; updating the synaptic weights of a pre-constructed spiking neural network using a spike timing-dependent plasticity mechanism according to the first training data set; The second training data set is input into the updated spiking neural network to train and obtain a user recommendation model.
2. The method according to claim 1, characterized in that Constructing a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item includes: Based on the portrait information of the target user corresponding to the target item, the target user is divided into one or more user groups, and a user group label of each user group is determined; According to the user group labels of the respective user groups, labels are added to the target items to obtain user group label results of the target items; A second training data set is constructed based on the attribute information of each target item and the user group label result.
3. The method according to claim 1, characterized in that: The pre-built spiking neural network is obtained by the following steps: Defining the basic framework of the spiking neural network; wherein the basic framework includes an input layer, an excitation layer and an inhibition layer; Establishing synaptic connections for the neurons in the input layer, the excitatory layer, and the inhibitory layer; wherein the neurons in the input layer are connected to the neurons in the excitatory layer via presynaptic connections, and the neurons in the excitatory layer are connected to the neurons in the inhibitory layer via postsynaptic connections; A spiking neural network is constructed based on the connection results.
4. The method according to claim 3, characterized in that: Updating the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set includes: Inputting the first training data set into a pre-constructed spiking neural network to determine the trace value of the pre-synapse and the trace value of the post-synapse; The synaptic weights of the spiking neural network are updated according to the trace value of the pre-synapse and the trace value of the post-synapse.
5. The method according to claim 3, characterized in that: Before updating the synaptic weights of the pre-constructed spiking neural network using the spike time-dependent plasticity mechanism according to the first training data set, the method further includes: The synaptic weights from the input layer to the excitatory layer are initialized using a random strategy, or the synaptic weights from the excitatory layer to the inhibitory layer and the synaptic weights from the inhibitory layer to the excitatory layer are initialized using a preset experimental strategy to update the initialized synaptic weights of the pre-constructed spiking neural network.
6. The method according to claim 3, characterized in that Inputting the second training data set into the updated spiking neural network to train a user recommendation model includes: Inputting the second training data set into the updated spiking neural network, and determining the pulse intensity ratio corresponding to the neurons in the excitatory layer of the updated spiking neural network; The target items in the second training data set are grouped according to the pulse intensity ratio, and a user recommendation model is obtained by training based on the grouping result.
7. A coupon recommendation method, characterized in that: include: Obtain attribute information of items to be recommended; Determine a recommended user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by any one of the methods described in claims 1 to 6; The obtained available coupons for the item to be recommended are pushed to the recommending user corresponding to the item to be recommended.
8. A training device for a user recommendation model, characterized in that: include: A construction module is used to construct a first training data set based on the attribute information of the target item, and to construct a second training data set based on the attribute information of the target item and the portrait information of the target user corresponding to the target item; wherein the target item includes items whose activity exceeds a preset threshold; and the target user includes users who have placed an order and users who have added items to a purchase; An updating module, configured to update the synaptic weights of the pre-constructed spiking neural network using a spike time-dependent plasticity mechanism according to the first training data set; A training module is used to input the second training data set into the updated spiking neural network to train and obtain a user recommendation model.
9. A coupon recommendation device, characterized in that: include: An acquisition module is used to obtain attribute information of items to be recommended; A determination module, configured to determine a recommended user corresponding to the item to be recommended by using a user recommendation model based on the attribute information of the item to be recommended; wherein the user recommendation model is obtained by the method described in any one of claims 1 to 6; The recommendation module is used to push the obtained available coupons of the item to be recommended to the recommending user corresponding to the item to be recommended.
10. An electronic device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 7.
11. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
12. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
Citation Information
Cited By
Coupon pushing method and device for multi-port delivery
CN120580001A
A multi-port coupon pushing method and device
CN120580001B