Purchase behavior linkage prediction method and system based on e-commerce user social relationship mining
By constructing a weighted directed graph of social relationships and a purchase behavior trajectory vector for e-commerce users, and combining it with a logistic regression model to dynamically adjust feature weights, the problem of insufficient integration of social relationships and purchase behavior in the analysis of e-commerce user purchase behavior is solved, thereby improving the accuracy and stability of prediction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HANGZHOU YIDIYI NETWORK TECHNOLOGY CO LTD
- Filing Date
- 2026-04-24
- Publication Date
- 2026-05-29
AI Technical Summary
Existing technologies in e-commerce user purchase behavior analysis fail to effectively combine users' social relationships with their purchasing behavior. This results in predictions that do not adequately reflect group consumption trends, related propagation effects, and behavioral triggering chains, thus affecting the accuracy, stability, and scenario adaptability of the prediction results.
By constructing a weighted directed graph structure based on the social relationships of e-commerce users, the influence parameters of user nodes are calculated. Combined with the purchase behavior trajectory vector, a linkage prediction model is constructed. The prediction is performed using a Logistic regression model, and the model parameters are updated through real-time feedback data to dynamically adjust the weights of key input features.
It improves the ability to identify socially driven purchasing behavior, enhances the targeting and stability of linkage relationships, adapts to changes in different social structures and consumption cycles, and improves the accuracy and usability of prediction results.
Smart Images

Figure CN122115016A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of e-commerce user behavior prediction, specifically involving a method and system for predicting purchase behavior based on the mining of social relationships among e-commerce users. Background Technology
[0002] With the continuous development of e-commerce platforms, users have formed increasingly rich interactive trajectories both inside and outside the platforms. In addition to transactional behaviors such as browsing, saving, adding to cart, placing orders, and reviewing, there is also a continuous accumulation of social behavioral data such as following, sharing, forwarding, commenting, inviting, and group interaction. Social relationships not only reflect the connection status between users, but also, to a certain extent, reflect characteristics such as convergence of interests, transmission of consumption preferences, diffusion of trust, and behavioral imitation.
[0003] In existing technologies, the technical approaches related to e-commerce user purchase behavior analysis can be broadly categorized as follows: One approach builds purchase prediction models based on users' historical transaction records, browsing history, and product attribute information, using statistical analysis, collaborative filtering, or feature learning to predict which products users might purchase in the future. Another approach uses user profiling methods, integrating information such as age, region, consumption level, interest tags, and activity level to achieve user classification and preference inference. A third approach incorporates social network information into recommendation scenarios, analyzing the influence relationships between users through friend relationships, interaction frequency, or propagation paths. However, most existing technologies separate transaction behavior analysis from social relationship analysis, focusing on static preference matching or single behavior modeling, while paying insufficient attention to the linked purchase phenomena triggered by social connections between users. Furthermore, some solutions provide a rather coarse characterization of social relationships, making it difficult to distinguish the differences brought about by different relationship strengths, interaction directions, and influence sequences. This results in prediction results that do not adequately reflect group consumption trends, related propagation effects, and behavioral trigger chains, thus affecting the accuracy, stability, and scenario adaptability of the prediction results.
[0004] Therefore, it is necessary to provide a purchase behavior linkage prediction solution for e-commerce scenarios to more effectively explore the correlation between users' social relationships and purchase behavior, thereby providing more targeted technical support for user behavior analysis and business decision-making of e-commerce platforms. Summary of the Invention
[0005] To address the aforementioned problems, the present invention aims to propose a method for predicting purchase behavior linkage based on the mining of social relationships among e-commerce users, comprising the following steps: S1. Obtain user social data, user purchase data and product metadata information, wherein the user social data includes the user's friend relationships, interaction records and community structure, the user purchase data includes purchase time, product category and transaction amount, and the product metadata information includes product identifier, category tag and brand information; S2. Model the user's social network as a weighted directed graph structure. In the modeling process, users are regarded as nodes, social relationships are determined as directed edges, and weights are assigned to each directed edge according to the interaction frequency and content similarity between users. S3. Based on the established social network, calculate the influence parameters of each user node. The influence parameters are calculated based on the transmission path, topological depth and node aggregation degree in the graph structure, and are used to characterize the relative influence weight of each node in social communication. S4. Construct purchase behavior trajectory vectors based on user purchase data, cluster all users according to the similarity of purchase behavior trajectory vectors, and then determine the linkage factor, which is used to characterize the degree of synchronization of purchase behavior among users. S5. Combining the user's social network structure and purchasing behavior trajectory, construct a linkage prediction model. The linkage prediction model takes social influence, linkage factor and user basic information as input features, and the probability that the target user will engage in the same type of purchasing behavior after being influenced by his social circle is the output result. S6. Evaluate the fitting deviation of the prediction results of the linkage prediction model, dynamically adjust the weights of key input features, and update the model parameters based on real-time feedback data to improve the applicability of the model under different social structures and time periods.
[0006] As a preferred technical solution, in the process of social relationship modeling, user nodes are divided into primary and secondary influential users according to the degree of social clustering and interaction frequency. The primary influential users affect the target user through direct influence paths, while the secondary influential users indirectly influence the target user through intermediate nodes. Corresponding attenuation coefficients are assigned to different levels of paths, and the attenuation coefficients are updated based on path length and historical influence results.
[0007] As a preferred technical solution, the determination of the linkage factor is based on the following two dimensions: T1: Analyze the time difference of repeat purchases among different users in the same product category, perform distribution fitting on the repeat purchase time difference to determine the user response interval, and classify users in the high-density response interval into a high-linkage attribute group. T2: Construct a user consumption preference feature matrix based on product price range and consumption frequency, thereby enabling interconnected stratification at different consumption levels.
[0008] As a preferred technical solution, the determination of the linkage factor includes: Based on user purchase data, a purchase behavior trajectory vector is constructed for each user. This vector includes at least the product category, purchase time, product price range, and purchase frequency. Any two users within the same cluster are compared, and the purchase time difference between them in the same product category is calculated. When the proportion of product categories whose purchase time difference falls within a preset time range reaches a preset percentage, the two users are determined to meet the purchase time linkage condition. The number of purchases and the purchase frequency of any two users within the same cluster in each product price range are calculated. When the difference in the number of purchases within the same product price range is less than a preset threshold, and the difference in the purchase frequency in the same product category is less than a preset frequency threshold, the two users are determined to meet the consumption preference linkage condition. All user pairs within the same cluster are evaluated, and those that simultaneously meet both the purchase time linkage condition and the consumption preference linkage condition are identified as linked user pairs. The proportion of linked user pairs to the total number of user pairs within the cluster is used as the linkage factor for that cluster.
[0009] As a preferred technical solution, the linkage prediction model is a Logistic regression model. Its input features include social influence, linkage factor, total consumption of users in the past three months and number of product categories purchased. The output result is a continuous value representing the probability of linkage purchase.
[0010] As a preferred technical solution, the specific steps for calculating the influence parameters of computing nodes include: In a social network graph, let the target node be u, and the related nodes v include nodes in the first layer, the second layer, and the third layer; the influence value I(u) of node u is obtained by the following formula:
[0011]
[0012] in, For the value space of the nodes; This represents the first-level set of related nodes of the target node u. This represents the set of related nodes in the second layer of the target node u. This represents the set of related nodes in the third layer of the target node u; This represents the preset edge weight from node v to node u; This represents the degree value of node v; the degree value is determined based on the number of connecting edges of node v in the social network graph, the number of connecting edges includes the number of incoming edges pointing to node v and the number of outgoing edges from node v to other nodes; This represents the strength of the social relationship between node v and node u, calculated based on similarity. The strength of the social relationship is determined based on the interaction records between node v and node u. The interaction records include interaction frequency, interaction type, interaction time distribution, and interaction content similarity. The interaction indicators are normalized and then weighted and synthesized. This represents the propagation delay coefficient from node v to node u; the propagation delay coefficient is the sum of the normalized values of the propagation path length, historical interaction time difference, and response time difference of associated purchase behavior between node v and node u.
[0013] As a preferred technical solution, in the step of clustering based on user purchase behavior trajectory vectors, the K-means clustering method is first used to divide all users into k classes, where the value of k is determined by the Bayesian information criterion. Each class corresponds to an independent set of linkage factor parameters, which includes three indicators: purchase synchronization rate, category preference, and consumption elasticity.
[0014] As a preferred technical solution, in the process of evaluating the model fitting deviation, the offset between the model-predicted linked purchase trend and the actual user behavior trend is recorded and aggregated on a weekly basis. If the offset of two consecutive statistical periods exceeds the preset offset threshold, model iteration and parameter adjustment are triggered.
[0015] This invention also provides a purchase behavior linkage prediction system based on e-commerce user social relationship mining, including a data acquisition module, a social relationship modeling module, a behavior trajectory clustering module, a linkage prediction module, and a model adaptive optimization module, wherein: The data acquisition module is used to collect social network information and purchase record data of e-commerce users; The social relationship modeling module is used to establish a graph structure of weighted influence relationships between users and output an influence weight matrix; The behavior trajectory clustering module is used to extract the purchase behavior trajectory vectors of all users and perform linked clustering based on the similarity of the purchase behavior trajectory vectors. The linkage prediction module is used to output the purchase linkage probability of the target user based on social network structure information and purchase behavior trajectory information. The model adaptive optimization module is used to monitor the deviation between the predicted output and the actual result, and to trigger multi-cycle correction and parameter updates.
[0016] As a preferred technical solution, the data acquisition module includes a data collection component, which is used to perform the steps of acquiring user social data, user purchase data, and product metadata information.
[0017] As a preferred technical solution, the social relationship modeling module includes a graph structure building component, which is used to perform the step of modeling the user's social network as a weighted directed graph structure.
[0018] The beneficial effects of this invention are as follows: Compared to technical approaches that rely solely on users' historical purchase records for behavior prediction, this invention incorporates users' social relationships, interaction records, and community structure into the linked analysis of purchase behavior. Furthermore, it represents the social network as a weighted directed graph structure, thereby enabling the inclusion of the direction, intensity, and propagation level of influence between different users within a unified characterization scope. Based on this improvement, purchase behavior prediction is no longer limited to the static consumption characteristics of a single user, but can reflect the linkage effect of the social propagation chain on the target user's purchase decision, enhancing the ability to identify socially driven purchase behavior.
[0019] This invention constructs a purchase behavior trajectory vector and combines it with the time difference of repeated purchases, product price ranges, and purchase frequency to conduct a hierarchical analysis of the linkage relationship between users, thereby determining the linkage factor and providing a clearer basis for judging the degree of linkage between users. This improvement does not simply compare whether users buy the same products, but further reflects the superimposed relationship between the proximity of purchase time and the proximity of consumption preferences. Therefore, it can more accurately distinguish between genuinely linked users and occasional overlapping users, reduce the bias caused by single-dimensional matching, and enhance the targeting and stability of linkage characterization.
[0020] This invention introduces a mechanism for evaluating the fitting deviation of the prediction results and dynamically adjusting the weights of key input features after the linkage prediction is completed. This allows the prediction process to not only output the probability of linkage purchases but also continuously correct model parameters based on feedback data. Compared with prediction methods with fixed parameters and fixed periods, this improvement enables the constructed linkage prediction model to adapt to the impact of different social structures, different consumption cycles, and changes in user behavior over different time periods. It reduces the mismatch problem of static models in long-term operation, thereby improving the stability and usability of prediction results in continuous application scenarios. Attached Figure Description
[0021] Figure 1 This is a schematic diagram of the method flow of the present invention; Figure 2 This is a schematic diagram of the system structure of the present invention. Detailed Implementation
[0022] To enhance understanding of the present invention, the present invention will be further described in detail below with reference to embodiments. These embodiments are only used to explain the present invention and do not constitute a limitation on the scope of protection of the present invention.
[0023] Example 1 This embodiment presents a method for predicting purchase behavior linkages based on the mining of social relationships among e-commerce users, such as... Figure 1 As shown, it includes the following steps: S1. Obtain user social data, user purchase data, and product metadata information: In this embodiment, basic data is first obtained from the e-commerce platform's business database, social interaction database, and product information database. The obtained data mainly includes three categories. The first category is user social data, which reflects the connection relationships and interaction status between different users. This part of the data includes at least user friend relationships, interaction records, and community structure. Among them, friend relationships can be formed by data such as following, mutual following, adding friends, joining communities, and shared group relationships established by users within the platform; interaction records can include behaviors such as liking, commenting, forwarding, private messages, sharing products, participating in activities together, and interactive feedback after browsing recommended pages together; community structure can include user interest communities, brand communities, live broadcast fan groups, group buying groups, and user circle structures formed by tag aggregation.
[0024] The second category is user purchase data, used to depict users' actual consumption behavior within an existing statistical period. This data includes at least the purchase time, product category, and transaction amount. It may also further include order identifier, payment status, purchase frequency, refund status, whether it was a repeat purchase, and whether the transaction occurred during a promotional event. In this embodiment, to avoid interference from short-term abnormal data in subsequent analysis, after extracting the original purchase records, orders with failed duplicate payments, fully refunded orders, abnormal fraudulent orders, and invalid orders that clearly do not conform to real consumption habits can be filtered out, retaining data records that truly reflect user consumption behavior.
[0025] The third category is product metadata information, which provides a structured description of the product for purchasing decisions. This part of the data includes product identifiers, category tags, and brand information.
[0026] Further details can include price range, listing time, associated promotional activities, store type, and marketing hashtags. By introducing product metadata, similar purchasing behaviors can be mapped to a distinguishable product structure, facilitating the identification of user interactions based on factors such as product category consistency, price range similarity, and brand preference stability.
[0027] After data acquisition, the user social data, user purchase data, and product metadata are uniformly cleaned and preprocessed. Specifically, this includes: removing records with missing key fields; performing a unified format conversion on time fields; standardizing the mapping of product category names; merging abbreviations, aliases, and historical names of brand names; verifying the reasonableness of order records with abnormally large or small transaction amounts; and completing cross-data source association and integration based on a unified user identifier. After the above processing, a foundational dataset is formed that can be used for subsequent social network modeling, influence parameter calculation, purchase behavior trajectory construction, and linkage prediction.
[0028] S2. Model the user's social network as a weighted directed graph structure: In this embodiment, the preprocessed user set is mapped to nodes in a social network, and the social relationships between users are mapped to directed edges, thereby constructing a user social network graph. Since the influence between different users is not always bidirectional and equivalent, a weighted directed graph structure is used in the modeling to better reflect the real propagation path of "one user continuously influencing another user" in e-commerce scenarios.
[0029] For example, when a user consistently shares product links, posts reviews, or continuously recommends a certain type of product in a community, the purchase inducement they exert on other users often has a clear directionality. Therefore, representing this influence relationship with directed edges is more beneficial for subsequent analysis.
[0030] In establishing nodes and edges, the initial connection relationship is first determined based on friend relationships and interaction records. If two users have any of the pre-defined relationships such as following each other, exchanging private messages, commenting, sharing products, or participating in shared community activities, they can be considered to have a potential social edge.
[0031] Furthermore, the direction of the edge is determined based on the direction in which the interaction occurs. For example, if user A frequently sends product links, comments on user B's shopping updates, or forwards product content to user B, then the edge pointing from user A to user B can be considered the primary direction of influence.
[0032] For each directed edge, a weight needs to be assigned to reflect the strength of the social relationship in the spread of purchasing behavior. In this embodiment, the edge weight is determined based on a combination of user interaction frequency and content similarity. Interaction frequency can be obtained by counting the number of likes, comments, private messages, reposts, and sharing actions per unit time; content similarity can be obtained by comparing the similarity between two users in interactive text, shared products, browsed topics, or community topics. To improve the stability of the results, various interaction indicators can be normalized first, and then synthesized according to preset weights to obtain the edge weights.
[0033] In the process of social relationship modeling, user nodes can be divided into primary and secondary influential users based on the degree of social clustering and interaction frequency. Primary influential users affect target users through direct influence paths, meaning that there is a direct social edge between them and the target user, and the edge weight meets the preset standard. Secondary influential users exert indirect influence on target users through intermediate nodes, meaning that although they do not have a direct high-strength connection with the target user, they form an indirect influence path through mutual friends, mutual communities, mutual attention links, or intermediate propagation nodes.
[0034] To ensure that influence relationships at different levels can be handled within the same framework, corresponding attenuation coefficients are assigned to paths at different levels. Shorter paths, more stable historical interactions, and more pronounced historical linkages result in smaller attenuation levels; conversely, longer paths, more intermediate nodes, and weaker historical influences result in greater attenuation levels. This approach allows both direct and indirect influences to be included in the model's analysis, avoiding information gaps caused by analyzing only direct friend relationships.
[0035] S3. Based on the established social network, calculate the influence parameters of each user node: In this embodiment, after establishing the weighted directed graph structure, an influence parameter is calculated for each user node in the graph. This influence parameter characterizes the relative influence weight of different users in social communication, reflecting both the user's connection position in the social network and their potential ability to spread the purchasing behavior of surrounding users. Since purchase linkage in e-commerce scenarios is not solely determined by the number of connections, this embodiment does not only use the number of nodes connected as a criterion, but also comprehensively considers the transmission path, topological depth, and node aggregation degree in the graph structure.
[0036] In a social network graph, the target node is a user to be analyzed, and the relevant nodes include first-level nodes, second-level nodes, and third-level nodes.
[0037] The first layer of nodes represents users who have a direct and effective social connection with the target node; the second layer of nodes represents users who form a propagational connection with the target node through an intermediate node; and the third layer of nodes represents users who form a propagational connection with the target node through two intermediate nodes. Including nodes at different levels preserves the direct influence information of neighboring users while also reflecting the indirect impact of community diffusion on target users within a limited depth.
[0038] When calculating the impact value, the following components are mainly considered: First, the edge weight, which reflects the basic influence strength between the relevant node and the target node; second, the node degree, which characterizes the activity level and connection range of the relevant node in the entire social network; third, the social relationship strength, which reflects the interaction stability, interaction richness, and consistency of interaction content between two nodes; and fourth, the propagation delay coefficient, which reflects the path length, historical interaction time difference, and related purchase behavior response time difference of the social influence from the relevant node to the target node.
[0039] The node degree value is determined based on the number of connecting edges in the social network graph, including the number of incoming edges pointing to the node and the number of outgoing edges pointing from the node to other nodes. Generally, if a node can continuously receive interactive feedback from others and frequently output product information or consumer opinions to other nodes, it indicates that it is in a relatively active position in the network and is more likely to play a bridging role in the spread of behavior. The strength of social relationships is determined based on the interaction records between two nodes, including interaction frequency, interaction type, interaction time distribution, and similarity of interaction content.
[0040] Specifically, different interactive behaviors such as commenting, sharing, private messaging, liking, and participating in joint activities can be assigned different weights according to preset rules, and then weighted and synthesized after unified normalization. The propagation delay coefficient is determined by comprehensively considering the propagation path length between nodes, the time difference of historical interactions, and the response time difference of related purchase behaviors. If a node's interaction with a target node's product and subsequent purchase consistently show a short time difference, then the propagation timeliness of that path can be considered strong.
[0041] The influence parameters for each target node can be obtained through the above method. Compared with a rough classification based solely on the number of friends or followers, the influence parameters in this embodiment can simultaneously reflect the user's location, connection breadth, interaction intensity, and dissemination timeliness, providing a more granular expression of the differences in the roles of different users in social networks and offering more reliable social-side input for subsequent analysis of linked purchasing behavior.
[0042] S4. Construct a purchase behavior trajectory vector based on user purchase data and determine the linkage factors: In this embodiment, after extracting information from the social network side, a purchase behavior trajectory vector is further constructed from user purchase data. This purchase behavior trajectory vector includes at least the product category, purchase time, product price range, and purchase frequency. Through these four types of information, the consumption behavior of different users can be uniformly represented from dimensions such as "what was bought, when was it bought, preferred price range, and how often it is purchased."
[0043] When constructing a purchase behavior trajectory vector, purchase records within a preset statistical period can be arranged in chronological order, then categorized and statistically analyzed by product category, and different product prices can be mapped to several price ranges. At the same time, the purchase frequency of each product category within the statistical period can be calculated, thereby forming a structured representation of the user purchase trajectory.
[0044] After obtaining the purchase behavior trajectory vectors of all users, cluster all users according to the similarity of the trajectory vectors. Clustering methods can be used to divide all users into several categories, and then user groups with similar behavioral patterns can be identified based on the clustering results.
[0045] First, K-means clustering can be used to divide all users into several classes, the number of which is determined by the Bayesian information criterion. This approach avoids manually setting the number of classes based solely on experience, thus making the clustering more closely reflect the actual data distribution. Each class corresponds to an independent set of linkage factor parameters, including three indicators: purchase synchronization rate, category tendency, and consumption elasticity. This division allows for separate analysis of user relationships under different consumption patterns, avoiding the simplistic mixing of high-frequency, essential consumption and low-frequency, high-price consumption.
[0046] The determination of the linkage factor is based on two dimensions. The first dimension is the repeat purchase time difference dimension, which analyzes the time difference of repeat purchases among different users on the same product category. Distribution fitting is performed on this repeat purchase time difference to determine user response intervals, and users in high-density response intervals are categorized as high-linkage attribute groups. The core of this dimension is not only examining whether two users have purchased the same category of goods, but also whether the timing of their purchases is significantly close. If some users' purchase time differences on multiple identical product categories are consistently concentrated in short intervals, it indicates a potentially strong behavioral response relationship between them, rather than a random category overlap.
[0047] The second dimension is the consumption preference dimension, which constructs a user consumption preference feature matrix based on product price ranges and purchase frequency, thereby enabling stratification across different consumption levels. The core of this dimension lies in identifying the similarity of users in terms of consumption levels and purchasing rhythms. For example, although some users may have both purchased a certain product category, if one group concentrates on high-price ranges and purchases infrequently, while the other concentrates on low-price ranges and purchases frequently, the correlation between them will obviously be different. Therefore, by introducing price ranges and purchase frequency, we can further identify user groups with truly similar consumption structures.
[0048] The determination of the linkage factor includes the following process. First, a purchase behavior trajectory vector for each user is constructed based on user purchase data. Second, any two users within the same cluster are compared, and the purchase time difference between them in the same product category is calculated. When the proportion of product categories whose purchase time difference falls within a preset time interval reaches a preset proportion, it is determined that the two users meet the purchase time linkage condition.
[0049] Then, the purchase frequency of any two users within the same cluster is counted across price ranges for each product, as well as their purchase frequency across product categories. When the difference in purchase frequency between two users within the same price range is less than a preset threshold, and the difference in purchase frequency across the same product category is less than a preset frequency threshold, the two users are determined to meet the consumption preference linkage condition. Finally, all user pairs within the same cluster are evaluated, and those that simultaneously meet both the purchase time linkage condition and the consumption preference linkage condition are identified as linked user pairs. The proportion of linked user pairs to the total number of user pairs within that cluster is used as the linkage factor for that cluster.
[0050] The linkage factor obtained through the above method is not a simple description of user similarity, but rather a concentrated expression of the degree to which "similar consumption levels, similar purchase sequences, and similar product-related responses occur." Therefore, this linkage factor can effectively distinguish between synchronized purchasing behavior truly driven by social dissemination and purchasing behavior that is only statistically coincidental, thus providing a more stable basis for subsequent predictions of whether target users will engage in similar purchases under the influence of their social circles.
[0051] S5. Combine user social network structure with purchasing behavior patterns to construct a linked prediction model: In this embodiment, after obtaining the influence parameters on the social side and the linkage factors on the purchasing side, a linkage prediction model is further constructed to output the probability that a target user will engage in similar purchasing behavior after being influenced by their social circle. To ensure that the model results have clear interpretability and deployability, this embodiment uses a Logistic regression model as the linkage prediction model.
[0052] The input features of the aforementioned predictive model include social influence, linkage factors, the user's total spending over the past three months, and the number of product categories purchased. Social influence reflects the target user's level of influence on social networks and the intensity of its spread within their network; linkage factors reflect the density of synchronized purchasing relationships within the target user's behavioral group; total spending over the past three months reflects the user's overall recent consumption activity level; and the number of product categories purchased reflects the breadth of the user's consumption range. By incorporating these multi-dimensional inputs, social dissemination factors, behavioral linkage factors, and the user's recent consumption characteristics can be simultaneously included, avoiding reliance on a single data dimension for prediction.
[0053] During model training, samples with clear outcome labels can be selected from historical data as training samples. For example, if the target outcome is whether a user purchases similar products after related users in their social circle within a specific time window, the calculated social influence, linkage factor, total spending, and number of product categories purchased can be used as input features. After training, the model can be used to infer the behavior of the user to be predicted. When the features corresponding to a target user at the current moment are input, the model outputs the probability value of the target user engaging in similar purchasing behavior after being influenced by their social circle. The output is a continuous numerical value; the higher the value, the more likely the target user is to be driven by the behavior of their social circle to make similar purchases.
[0054] Compared to methods that rely solely on users' historical purchase records for repurchase prediction or preference recommendations, the linkage prediction model in this embodiment incorporates both social influence links and group synchronization levels into its analysis. Therefore, it is more suitable for e-commerce scenarios with significant social diffusion characteristics, such as live-streaming e-commerce, community group buying, friend sharing, content seeding, and interest circle dissemination.
[0055] S6. Evaluate the fitting bias of the prediction results of the linkage prediction model and update the model parameters based on the feedback data: In this embodiment, to prevent the model from gradually deviating from the actual behavior distribution across different time periods, social structures, or marketing stages, after the model outputs the probability of linked purchases, a fitting deviation assessment is further performed on the prediction results, and the weights of key input features are dynamically adjusted. This step ensures that the model maintains a consistent level of alignment with actual user behavior over long-term operation.
[0056] Specifically, after the model is put into operation, the deviation between the predicted linked purchase trends and the actual user behavior trends is continuously recorded. The deviation can be statistically analyzed from aspects such as whether the predicted high-probability users actually made a purchase, whether the predicted high-frequency linked purchase periods actually saw concentrated purchases, and whether the predicted high-linkage categories actually saw simultaneous purchases.
[0057] The offset is aggregated and analyzed on a weekly basis. If the offset exceeds a preset offset threshold for two consecutive statistical periods, model iteration and parameter adjustment are triggered. Parameter adjustment may include recalibrating the contribution weight of social influence in the model, re-examining the applicability of linkage factors in different product categories, updating the normalization range of total consumption and the number of product categories purchased, and adjusting the edge weight calculation method for recently emerging social activity forms.
[0058] In a specific application scenario, an e-commerce platform selects four categories of products—apparel, beauty, home furnishings, and digital products—as key analysis targets within a one-month statistical period. The system first obtains information on users' friend relationships, product sharing records, community participation records, and historical purchase orders within the platform, and then establishes a weighted directed graph of the social relationships between users.
[0059] Subsequently, the influence parameters of each target user within the three-layer dissemination range were calculated, and a purchase behavior trajectory vector was constructed based on purchase records from the past three months. After cluster analysis, several user groups with similar price ranges, purchase frequencies, and purchase time responses were identified. Then, the corresponding linkage factors were determined based on the proportion of linked user pairs within each group.
[0060] Finally, the social influence, linkage factor, total consumption over the past three months, and the number of product categories purchased are input into the linkage prediction model, which outputs the probability that a target user will make a linked purchase of a certain type of product. If, after two weeks of model operation, the model finds that the linked purchases of a certain type of product in actual promotional activities are significantly higher than the original prediction results, the system triggers model iteration based on the judgment that the deviation exceeds the threshold for two consecutive weeks. This readjusts the parameter contributions in the relevant samples of that type of product, thereby making subsequent prediction results closer to actual behavioral trends.
[0061] In summary, this embodiment, by sequentially executing steps such as data acquisition, social network modeling, influence parameter calculation, purchase behavior trajectory construction and clustering, linkage factor determination, linkage prediction modeling, and deviation assessment and model updating, incorporates social communication links, consumer behavior trajectories, and users' synchronous purchase relationships into a unified analysis framework. This allows for a more detailed depiction of the purchase linkage behavior formed by e-commerce users under social influence, and provides a complete, closed, and continuously updated implementation path for outputting the probability of similar purchases by target users.
[0062] Example 2 This embodiment provides a purchase behavior linkage prediction system based on the mining of social relationships among e-commerce users, such as... Figure 2As shown, it includes a data acquisition module, a social relationship modeling module, a behavior trajectory clustering module, a linkage prediction module, and a model adaptive optimization module, which are used to execute the steps in the aforementioned methodological technical solutions in order to predict the probability of e-commerce users engaging in similar purchasing behaviors under social influence.
[0063] The data acquisition module is used to collect social network information and purchase record data of e-commerce users.
[0064] The data acquisition module includes a data collection component, a data cleaning component, a data mapping component, and a data storage component. The data collection component is used to perform the steps of acquiring user social data, user purchase data, and product metadata information.
[0065] The user social data includes user friend relationships, interaction records, and community structure; the user purchase data includes purchase time, product category, and transaction amount; the product metadata information includes product identifier, category tag, and brand information. The data cleaning component is used to remove missing fields, filter abnormal records, remove duplicate records, and standardize the time format of the collected raw data.
[0066] The data mapping component is used to associate and integrate data from different business sources according to a unified user identifier, product identifier, and time field to form the structured input data required for subsequent modeling. The data storage component is used to classify and store the cleaned user social data, user purchase data, and product metadata information for use by other modules.
[0067] The social relationship modeling module is used to establish a graph structure of weighted influence relationships between users and output an influence weight matrix.
[0068] The social relationship modeling module includes a graph structure construction component, an edge weight calculation component, a hierarchy partitioning component, and a relationship matrix output component. The graph structure construction component performs the step of modeling the user's social network as a weighted directed graph structure, treating users as nodes and social relationships as directed edges. The edge weight calculation component assigns corresponding weights to each directed edge based on the interaction frequency and content similarity between users, and normalizes the edge weight results.
[0069] The hierarchical partitioning component is used to divide nodes into primary and secondary influential users based on the degree of social clustering and interaction frequency. Primary influential users directly influence target users, while secondary influential users indirectly influence target users through intermediate nodes. Simultaneously, corresponding attenuation coefficients are assigned to different hierarchical paths. The relationship matrix output component generates an influence weight matrix between users based on the connection direction and edge weight values between nodes, and outputs it to subsequent modules.
[0070] This module can transform previously scattered friend relationships, interactive behaviors, and community connections into a unified graph structure representation, thus providing a foundation for user influence propagation analysis.
[0071] The behavior trajectory clustering module is used to extract the purchase behavior trajectory vectors of all users and perform linked clustering based on the similarity of the purchase behavior trajectory vectors.
[0072] The behavior trajectory clustering module includes a trajectory vector extraction component, a similarity calculation component, a clustering partitioning component, and a linkage factor determination component. The trajectory vector extraction component constructs purchase behavior trajectory vectors for each user based on user purchase data. These trajectory vectors include at least the product category, purchase time, product price range, and purchase frequency. The similarity calculation component performs pairwise comparisons of all users' purchase behavior trajectory vectors to determine the trajectory similarity relationships between users.
[0073] The clustering component is used to group users based on the trajectory similarity relationship, and to group users with similar purchasing behavior patterns into the same cluster category.
[0074] The clustering component uses clustering methods to cluster all users and determines the clustering results by combining the number of categories selection rules. The linkage factor determination component is used to determine the linkage conditions of purchase time and consumption preference between any two users within the same cluster category; user pairs that simultaneously meet both conditions are identified as linked user pairs; then, the linkage factor corresponding to that cluster category is determined based on the proportion of linked user pairs to the total number of user pairs within that cluster category. Through this module, the temporal proximity, price level proximity, and consumption frequency proximity of user purchase behavior can be uniformly incorporated into the analysis process, providing a clearer data foundation for determining the degree of linkage.
[0075] The linkage prediction module is used to output the purchase linkage probability of the target user based on social network structure information and purchase behavior trajectory information.
[0076] The linkage prediction module includes a node impact analysis component, a feature combination component, a prediction model component, and a result output component.
[0077] The node influence analysis component is used to calculate the influence parameters of each user node based on the influence weight matrix, node connection status, and propagation path information.
[0078] The influence parameter is calculated based on the transmission path, topological depth, and node aggregation degree in the graph structure, and is used to characterize the relative influence weight of each node in social communication. The feature combination component is used to combine social influence, linkage factor, total consumption amount of the user in the past three months, and number of product categories purchased as predictive input features. The prediction model component is used to perform linkage prediction processing based on the input features, and output the probability value of the target user engaging in similar purchasing behavior after being influenced by their social circle.
[0079] The prediction model component employs a Logistic regression model to enhance the continuity and interpretability of the output results. The result output component is used to output the predicted purchase linkage probability to the business system to support recommendations, ad placement, marketing rhythm adjustments, or user behavior analysis.
[0080] The model adaptive optimization module is used to monitor the deviation between the predicted output and the actual result, and to trigger multi-cycle correction and parameter updates.
[0081] The model adaptive optimization module includes a deviation monitoring component, a periodic aggregation component, an iteration triggering component, and a parameter update component. The deviation monitoring component records the offset between the model's predicted linked purchase trends and the actual user behavior trends. The periodic aggregation component statistically aggregates the offsets on a weekly basis to obtain the fitting results under different statistical periods.
[0082] The iteration triggering component is used to determine whether the offset within multiple consecutive statistical periods exceeds a preset offset threshold. If it does, a model iteration instruction is generated. The parameter update component is used to update the model parameters based on feedback data and dynamically adjust the weights of key input features to enable the model to gradually adapt to changes in user behavior under different social structures, product cycles, and marketing stages. The feedback data includes at least the actual purchase results after the prediction output, the actual response time, and the corresponding product category information.
[0083] In this embodiment, the above modules work together sequentially according to a preset data flow order: First, the data acquisition module collects and organizes user social data, user purchase data and product metadata information from multiple data sources on the e-commerce platform; Secondly, the social relationship modeling module establishes a weighted directed graph structure based on the organized social data and outputs an influence weight matrix; Then, the behavior trajectory clustering module extracts user trajectory features from purchase records, completes user clustering, and determines linkage factors; Next, the linkage prediction module integrates social influence information with purchase behavior information to output the purchase linkage probability of the target user. Finally, the model adaptive optimization module continuously receives actual feedback results, monitors prediction deviations, and triggers parameter updates when conditions are met.
[0084] The modular division of labor described above not only clearly defines the boundaries of each processing stage, but also facilitates system deployment, upgrades, and expansion.
[0085] In a specific application scenario, an e-commerce platform can deploy this system on a user behavior analysis server. The data acquisition module periodically retrieves data from the platform, including friend relationships, product sharing records, comment interaction data, historical order data, and basic product attribute data. The social relationship modeling module transforms this data into a weighted directed graph and outputs the influence weight relationships between users. The behavior trajectory clustering module identifies user groups with similar consumption patterns based on purchase records from the past three months and determines linkage factors within each group. The linkage prediction module outputs the probability of a target user making a linked purchase of a specific product category. The model adaptive optimization module periodically adjusts the model based on subsequent actual transaction data. Through this configuration, the system can perform relatively detailed identification and prediction of socially driven purchasing behavior.
[0086] In summary, the system in this embodiment integrates user social relationship mining, purchase behavior trajectory analysis, linkage factor determination, purchase probability prediction, and continuous model optimization into a unified framework by setting up a data acquisition module, a social relationship modeling module, a behavior trajectory clustering module, a linkage prediction module, and a model adaptive optimization module. This forms a complete purchase behavior linkage prediction processing chain and is applicable to user behavior analysis scenarios based on the influence of social communication in e-commerce platforms.
[0087] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended claims and their equivalents.
Claims
1. A method for predicting purchase behavior linkage based on e-commerce user social relationship mining, characterized in that, Includes the following steps: S1. Obtain user social data, user purchase data and product metadata information, wherein the user social data includes the user's friend relationships, interaction records and community structure, the user purchase data includes purchase time, product category and transaction amount, and the product metadata information includes product identifier, category tag and brand information; S2. Model the user's social network as a weighted directed graph structure. In the modeling process, users are regarded as nodes, social relationships are determined as directed edges, and weights are assigned to each directed edge according to the interaction frequency and content similarity between users. S3. Based on the established social network, calculate the influence parameters of each user node. The influence parameters are calculated based on the transmission path, topological depth and node aggregation degree in the graph structure, and are used to characterize the relative influence weight of each node in social communication. S4. Construct purchase behavior trajectory vectors based on user purchase data, cluster all users according to the similarity of purchase behavior trajectory vectors, and then determine the linkage factor, which is used to characterize the degree of synchronization of purchase behavior among users. S5. Combining the user's social network structure and purchasing behavior trajectory, construct a linkage prediction model. The linkage prediction model takes social influence, linkage factor and user basic information as input features, and the probability that the target user will engage in the same type of purchasing behavior after being influenced by his social circle is the output result. S6. Evaluate the fitting deviation of the prediction results of the linkage prediction model, dynamically adjust the weights of key input features, and update the model parameters based on real-time feedback data to improve the applicability of the model under different social structures and time periods.
2. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: In the process of social relationship modeling, user nodes are divided into primary and secondary influential users according to the degree of social clustering and interaction frequency. The first-level influencing users act on the target users through direct influence paths, while the second-level influencing users indirectly influence the target users through intermediate nodes. Corresponding attenuation coefficients are assigned to different levels of paths, and these attenuation coefficients are updated based on path length and historical influence results.
3. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: The determination of the linkage factor is based on the following two dimensions: T1: Analyze the time difference of repeat purchases among different users in the same product category, perform distribution fitting on the repeat purchase time difference to determine the user response interval, and classify users in the high-density response interval into a high-linkage attribute group. T2: Construct a user consumption preference feature matrix based on product price range and consumption frequency, thereby enabling interconnected stratification at different consumption levels.
4. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: The linkage prediction model is a Logistic regression model. Its input features include social influence, linkage factor, total consumption amount and number of product categories purchased by users in the past three months, and the output result is a continuous value representing the probability of linkage purchase.
5. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: The specific steps for calculating the node influence parameter include: In a social network graph, let the target node be u, and the related nodes v include nodes in the first, second, and third layers; the influence value I(u) of node u is obtained by the following formula: ; ; in, For the value space of the nodes; This represents the set of first-level related nodes of the target node u. This represents the set of related nodes in the second layer of the target node u. This represents the set of related nodes in the third layer of the target node u; This represents the preset edge weight from node v to node u; This represents the degree value of node v; the degree value is determined based on the number of connecting edges of node v in the social network graph, the number of connecting edges includes the number of incoming edges pointing to node v and the number of outgoing edges from node v to other nodes; This represents the strength of the social relationship between node v and node u, calculated based on similarity. The strength of the social relationship is determined based on the interaction records between node v and node u. The interaction records include interaction frequency, interaction type, interaction time distribution, and interaction content similarity. The interaction indicators are normalized and then weighted and synthesized. This represents the propagation delay coefficient from node v to node u; the propagation delay coefficient is the sum of the normalized values of the propagation path length, historical interaction time difference, and response time difference of associated purchase behavior between node v and node u.
6. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: In the step of clustering based on user purchase behavior trajectory vectors, the K-means clustering method is first used to divide all users into k classes. The value of k is determined by the Bayesian information criterion. Each class corresponds to an independent set of linkage factor parameters, which includes three indicators: purchase synchronization rate, category tendency, and consumption elasticity.
7. The method for predicting purchase behavior based on e-commerce user social relationship mining according to claim 1, characterized in that: In the process of evaluating the model fitting deviation, the deviation between the model-predicted linked purchase trend and the actual user behavior trend is recorded and aggregated on a weekly basis. If the deviation for two consecutive statistical periods exceeds the preset deviation threshold, model iteration and parameter adjustment are triggered.
8. A purchase behavior linkage prediction system based on e-commerce user social relationship mining, used to implement the method as described in any one of claims 1-7, characterized in that, It includes a data acquisition module, a social relationship modeling module, a behavior trajectory clustering module, a linkage prediction module, and a model adaptive optimization module, among which: The data acquisition module is used to collect social network information and purchase record data of e-commerce users; The social relationship modeling module is used to establish a graph structure of weighted influence relationships between users and output an influence weight matrix; The behavior trajectory clustering module is used to extract the purchase behavior trajectory vectors of all users and perform linked clustering based on the similarity of the purchase behavior trajectory vectors. The linkage prediction module is used to output the purchase linkage probability of the target user based on social network structure information and purchase behavior trajectory information. The model adaptive optimization module is used to monitor the deviation between the predicted output and the actual result, and to trigger multi-cycle correction and parameter updates.
9. The purchase behavior linkage prediction system based on e-commerce user social relationship mining according to claim 8, characterized in that: The data acquisition module includes a data collection component, which is used to perform the steps of acquiring user social data, user purchase data, and product metadata information.
10. The purchase behavior linkage prediction system based on e-commerce user social relationship mining according to claim 8, characterized in that: The social relationship modeling module includes a graph structure building component, which is used to perform the step of modeling the user's social network as a weighted directed graph structure.