Merchant decision prediction method, device, equipment and storage medium

By extracting and recoding merchant representations and combining decision-making representations for prediction, the problem of existing models ignoring personalized features is solved, accurate predictions of merchant decisions are achieved, and prediction accuracy and flexibility are improved.

CN118429003BActive Publication Date: 2024-10-01ZHEJIANG NIAOCHAO SUPPLY CHAIN MANAGEMENT CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410889058.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-04
Publication Date
2024-10-01
Estimated Expiration
2044-07-04

AI Technical Summary

Technical Problem

Existing merchant decision-making prediction models ignore the personalized characteristics of merchants during the training process, making it difficult to capture the differences between merchants and unable to accurately predict the decisions of different types of merchants.

Method used

By extracting the initial merchant representation and environmental representation of the target merchant, re-encoding and fusing the decision-making representation, calculate the features to be predicted, and use adaptive prediction algorithms to process these features to achieve decision-making prediction, ensuring that the prediction model is based on the merchant's personalized characteristics. Customized forecasts.

Benefits of technology

It achieves accurate prediction of personalized decision-making results for different types of merchants, improves the flexibility and accuracy of the prediction model, and can better express the personalized characteristics of merchants in their environment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118429003B_ABST
    Figure CN118429003B_ABST
Patent Text Reader

Abstract

The embodiments of the present application provide a prediction method, device, equipment and storage medium for merchant decisions, and relate to the field of AI technology. The method includes: extracting the initial merchant representation of the target merchant, the environmental representation and decision representation corresponding to the target merchant, the environmental representation refers to the representation of the business environment in which the target merchant is located; re-encoding the initial merchant representation according to the environmental representation to obtain the merchant representation; fusing the decision representation and the merchant representation to obtain the feature to be predicted; calling the prediction algorithm matched with the target merchant to process the feature to be predicted, and obtaining the prediction result of the decision corresponding to the decision representation of the target merchant, and the parameters of the prediction algorithm are calculated according to the merchant representation. The adoption of this technical solution enables the merchant representation to reflect the personalized characteristics of the target merchant in the environment in which it is located, and can accurately predict the result of the decision execution of the target merchant based on the personalized characteristics of the target merchant.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of artificial intelligence (AI) technology, and in particular to a merchant decision prediction method, device, equipment and storage medium. Background Art

[0002] With the development of deep learning technology, each merchant can call on the prediction model to simulate different operational decisions during operation to predict the operational effect of adopting the corresponding operational decisions. The prediction model can be obtained by deep learning based on samples that reflect various characteristics of the merchant.

[0003] In actual implementation scenarios, the market environment, store establishment time, product categories, and operation scale of each merchant are different, and the difference between each merchant and other merchants usually includes the characteristics that reflect the individuality of the corresponding merchant. However, the samples used in the training process of the commonly used prediction models are all based on a large number of samples that reflect common characteristics, while samples that reflect the individual characteristics of merchants are usually ignored as long-tail samples. As a result, the commonly used prediction models are difficult to capture the differences between merchants, and thus cannot accurately predict the decisions of different types of merchants. Summary of the invention

[0004] To overcome the problems existing in the related art, the embodiments of the present application provide a merchant decision prediction method, device, equipment and storage medium.

[0005] According to a first aspect of an embodiment of the present application, a method for predicting merchant decisions is provided, comprising:

[0006] Extracting an initial merchant representation of a target merchant, an environment representation corresponding to the target merchant, and a decision representation, wherein the environment representation refers to a representation of the business district environment where the target merchant is located;

[0007] Re-encoding the initial merchant representation according to the environment representation to obtain a merchant representation;

[0008] Fusion of the decision representation and the merchant representation to obtain features to be predicted;

[0009] The prediction algorithm matched with the target merchant is called to process the feature to be predicted, and the prediction result of the decision corresponding to the decision representation of the target merchant is obtained. The parameters of the prediction algorithm are calculated according to the merchant representation.

[0010] According to a second aspect of an embodiment of the present application, a prediction device for merchant decision is provided, the device comprising:

[0011] A feature extraction module, used to extract an initial merchant representation of a target merchant, an environment representation corresponding to the target merchant, and a decision representation, wherein the environment representation refers to a representation of the business district environment where the target merchant is located;

[0012] A re-encoding module, configured to re-encode the initial merchant representation according to the environment representation to obtain a merchant representation;

[0013] A feature fusion module, used for fusing the decision representation and the merchant representation to obtain a feature to be predicted;

[0014] The prediction module is used to call the prediction algorithm matched with the target merchant to process the features to be predicted, and obtain the prediction result of the decision corresponding to the decision representation of the target merchant. The parameters of the prediction algorithm are calculated according to the merchant representation.

[0015] According to a third aspect of an embodiment of the present application, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the method described in the first aspect.

[0016] According to a fourth aspect of an embodiment of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the method described in the first aspect is implemented.

[0017] According to a fifth aspect of the embodiments of the present application, a computer program product is provided, comprising instructions, which, when executed on a computer, cause the computer to execute the method described in the first aspect.

[0018] The technical solution provided by the embodiments of the present application may have the following beneficial effects:

[0019] The initial merchant representation of the target merchant is recoded according to the environmental representation corresponding to the target merchant, and the merchant representation obtained after recoding is used as the feature expression of the target merchant for prediction. The environmental representation refers to the representation of the business environment in which the target merchant is located. In this way, the embodiment of the present application applies the market environment representation and supply and demand representation of the environment in which the target merchant is located to the representation of the target merchant, so that the merchant representation can reflect the personalized characteristics of the target merchant in the environment. Further, the parameters of the prediction algorithm are calculated according to the merchant representation, and the features to be predicted are processed according to the prediction algorithm to obtain the prediction result of the decision corresponding to the decision representation of the target merchant. That is, the prediction algorithm is adaptively determined based on the initial merchant representation of the target merchant and the environmental representation corresponding to the target merchant, so that a matching prediction algorithm can be customized for the specific feature expression of the target merchant, so that the corresponding prediction algorithm can accurately predict the result of the decision execution of the target merchant based on the personalized characteristics of the target merchant.

[0020] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the embodiments of the present application. It should be understood that for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative labor.

[0022] Figure 1 A schematic diagram of an exemplary method flow of a merchant decision prediction method provided in an embodiment of the present application;

[0023] Figure 2A An exemplary structural diagram of a prediction model for merchant decision-making provided in an embodiment of the present application;

[0024] Figure 2B for Figure 2A An exemplary structural diagram of the re-encoding module;

[0025] Figure 2C for Figure 2A An exemplary structural diagram of the parameter generation algorithm module;

[0026] Figure 2D for Figure 2A FIG. 1 is a schematic diagram of an exemplary structure of a feature fusion module;

[0027] Figure 3 A schematic diagram of an exemplary scenario of a prediction model for training merchant decisions provided in an embodiment of the present application;

[0028] Figure 4 A schematic diagram of an exemplary composition of a prediction device for merchant decision-making provided in an embodiment of the present application;

[0029] Figure 5 An exemplary structural diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0030] The technical solution of the embodiment of the present application is described below in conjunction with the drawings in the embodiment of the present application.

[0031] The terms used in the following embodiments of the present application are for the purpose of describing specific embodiments, and are not intended to be used as limitations on the technical solutions of the present application. As used in the specification and the appended claims of the present application, the singular expressions "one", "a kind of", "said", "above", "the" and "this" are intended to also include plural expressions, unless there is a clear indication to the contrary in the context. It should also be understood that although the terms first, second, etc. may be used to describe a certain class of objects in the following embodiments, the objects should not be limited to these terms. These terms are used to distinguish the specific implementation objects of this class of objects.

[0032] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in the embodiments of the present application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and provide corresponding operation entrances for users to choose to authorize or refuse.

[0033] The technical terms involved in the embodiments of the present application are explained below.

[0034] Merchant diagnosis: refers to the process of helping merchants identify key factors that affect their performance by analyzing their operating data and operating processes when they encounter problems during operations, and selecting targeted improvement decisions based on causal effect predictions.

[0035] Treatment: refers to the diagnostic action taken on the diagnostic object (such as a merchant) (e.g. whether to launch a takeaway model). In the actual implementation scenario, the decision can be pre-set according to the diagnostic object. For example, if the diagnostic object is a merchant, the pre-set decision may include: whether to increase store exposure, whether to increase advertising investment, how much advertising investment to increase, whether to launch discount activities, etc.

[0036] Causal Effect Estimation: It refers to determining the impact of a specific decision (treatment) (also described as processing or intervention) on the outcome based on statistical models and causal inference techniques. For example, predicting how a merchant’s sales will change if it implements a certain marketing strategy.

[0037] Among them, in some optional implementation scenarios, an initial causal effect prediction model can be trained based on the characteristic samples of the diagnosis object in the implementation scenario combined with the preset decision to obtain the decision prediction model required for the scenario. For example, in the scenario of merchant diagnosis, an initial causal effect prediction model can be trained based on the characteristic samples of the merchant combined with the preset merchant operation decisions to obtain the prediction model of the merchant decision.

[0038] At present, most commonly used prediction models for merchant decisions are trained based on the TARNet model, Dragonnet model, and TransTEE model. During the training process, these models are greatly influenced by a large number of samples with common characteristics. The personalized feature representations brought by the merchant's business environment, store establishment time, product categories, and operation scale are usually ignored as long-tail samples. These personalized feature representations are often the key features that affect the accuracy of decision prediction. It can be seen that commonly used prediction models are difficult to capture the differences between merchants, and thus cannot accurately predict the decisions of different types of merchants.

[0039] In view of this, the embodiments of the present application provide a prediction method, device, equipment and storage medium for merchant decisions, which apply the market environment characterization and supply and demand characterization of the target merchant's environment to the characterization of the target merchant, so that the merchant characterization can reflect the personalized characteristics of the target merchant in the environment in which it is located, and then, use the merchant characteristics to calculate the parameters of the prediction algorithm, and call the prediction algorithm using the corresponding parameters to predict the results of the target merchant's decision execution, so that the corresponding prediction model can accurately predict the results of the target merchant's decision execution based on the personalized characteristics of the target merchant.

[0040] The technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems are described in detail below with specific embodiments. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.

[0041] Please refer to Figure 1 , Figure 1 A merchant decision prediction method is provided for the embodiment of the present application. This embodiment takes calling a trained merchant decision prediction model to execute the method as an example. The merchant decision prediction method includes the following steps:

[0042] In step S101, an initial merchant representation of a target merchant, an environment representation corresponding to the target merchant, and a decision representation are extracted, wherein the environment representation refers to a representation of the business environment in which the target merchant is located.

[0043] Among them, the initial merchant representation, environment representation and decision representation can all be realized as semantic vectors.

[0044] In step S102, the initial merchant representation is re-encoded according to the environment representation to obtain a merchant representation.

[0045] In step S103, the decision representation and the merchant representation are integrated to obtain the feature to be predicted.

[0046] In step S104, the prediction algorithm matched with the target merchant is called to process the features to be predicted, and the prediction result of the decision corresponding to the decision representation of the target merchant is obtained. The parameters of the prediction algorithm are calculated according to the merchant representation.

[0047] The prediction result may be, for example, changes in order volume or other indicators (eg, profit margin, market share, etc.).

[0048] It should be pointed out that the trained merchant decision prediction model may include multiple algorithm models, such as the prediction algorithm. Different algorithm models can perform different data processing. The implementation of any step in the above steps S101 to S104 can be implemented by one or more algorithm models in the merchant decision prediction model.

[0049] It can be seen that the prediction method of the merchant decision provided by the embodiment of the present application is adopted, and the initial merchant representation of the target merchant is recoded according to the environmental representation corresponding to the target merchant, and the merchant representation obtained after recoding is used as the characteristic expression of the target merchant for prediction. Environmental representation refers to the representation of the business environment in which the target merchant is located. In this way, the embodiment of the present application applies the market environment representation and supply and demand representation of the environment in which the target merchant is located to the representation of the target merchant, so that the merchant representation can reflect the personalized characteristics of the target merchant in the environment. Further, the parameters of the prediction model are calculated according to the merchant representation, and the characteristics to be predicted are processed according to the prediction model to obtain the prediction result of the decision corresponding to the decision representation of the target merchant. That is, the prediction model is adaptively determined based on the initial merchant representation of the target merchant and the environmental representation corresponding to the target merchant, so that a matching prediction model can be customized for the specific characteristic expression of the target merchant, so that the corresponding prediction model can accurately predict the result of the target merchant's execution of the decision based on the personalized characteristics of the target merchant. That is to say, the technical solution of the embodiment of the present application supports different merchants to better express the personalized characteristics of the corresponding merchants by learning environment characteristics, and can characterize the parameters of the adaptive calculation prediction algorithm based on their own characteristics, thereby achieving personalized prediction effects for various types of merchants in various types of business districts, which is not only flexible but also has higher prediction accuracy.

[0050] The following describes the merchant decision prediction method of the embodiment of the present application in combination with the trained merchant decision prediction model.

[0051] refer to Figure 2A , Figure 2A The exemplary structural diagram of the merchant decision prediction model 20 provided in the embodiment of the present application, the merchant decision prediction model 20 may include an encoding module 201, a re-encoding module 202, a parameter generation algorithm module 203, a feature fusion module 204, and a prediction algorithm module 205.

[0052] Among them, the encoding module 201 can be used to extract the initial merchant representation of the target merchant, the environment representation and the decision representation corresponding to the target merchant, and then output the initial merchant representation and the environment representation to the re-encoding module 202, and output the decision representation to the feature fusion module 204. The re-encoding module 202 can be used to re-encode the initial merchant representation according to the environment representation to obtain the merchant representation, and output the merchant representation to the parameter generation algorithm module 203 and the feature fusion module 204 respectively, so that the parameter generation algorithm module 203 calculates the parameters of the prediction algorithm module 205 based on the merchant representation, and the feature fusion module 204 fuses the decision representation and the merchant representation, and outputs the features to be predicted to the prediction algorithm module 205. The prediction algorithm module 205 can use the parameters generated by the parameter generation algorithm module 203 to predict the features to be predicted output by the feature fusion module 204, and obtain the prediction result of the decision corresponding to the target merchant operation decision representation.

[0053] In some embodiments, the encoding module 201 may encode (embedding) the merchant information of the target merchant based on a preset encoding rule to obtain the initial merchant representation, and encode the business district information where the target merchant is located to obtain the environment representation. Exemplarily, the merchant information of the target merchant may include: part or all of the name, establishment time, scale, product types, prices, merchant ratings, brand influence, advertising, membership system, etc. of the target merchant. The business district information where the target merchant is located may include: part or all of the geographical location of the business district (e.g., city center, residential area, commercial area, near school), consumer traffic, consumer characteristics (e.g., age, gender, income level, consumption habits, etc.), the competitive environment of the target merchant (e.g., the number, type, exposure, etc. of merchants of the same type as the target merchant), etc. Furthermore, each of the above information can be encoded (embedded) into a semantic vector based on a preset encoding rule, and multiple semantic vectors corresponding to the merchant information of the target merchant can be concatenated to obtain the initial merchant representation of the target merchant, while multiple semantic vectors corresponding to the business district information can be concatenated to obtain the environment representation corresponding to the target merchant.

[0054] It should be understood that the representation of each information can be obtained by the encoding module 201 fusing the feature value vector and the feature semantic vector of the corresponding information, and the feature semantic vector can represent the semantics or attributes of the corresponding information.

[0055] Among them, the above-mentioned merchant information and business district information both include discrete information and continuous information. For example, the results corresponding to the product type and whether it is a brand store are two or more definite results, that is, the two pieces of information, product type and whether it is a brand store, are both discrete information, and discrete information includes binary information and multi-value information; the result corresponding to the merchant rating can be multiple values ​​in the continuous rating value within the rating range, that is, the merchant rating is continuous information.

[0056] For example, for binary information, the encoding matrix Can satisfy: , ,in, refers to the binary type representation set, refers to the number of binary type representations, Refers to the vector represented by the binary type, and S refers to the identifier of the corresponding vector. For multi-value type information, the encoding matrix Can satisfy: ,

[0057] ,in, Refers to a multi-value type representation set, It refers to the number of representations of multi-valued types, and L refers to the maximum number of classifications of multi-valued types.

[0058] The decision representation described in step S101 may be obtained by encoding the decision to be operated of the target merchant based on the aforementioned preset encoding rules by the encoding module 201. The decision to be operated of the target merchant may be at least one of the aforementioned preset decisions. In some embodiments, the decision to be operated of the target merchant may be, for example, whether to conduct a promotion. In other embodiments, the decision to be operated of the target merchant may be, for example, whether to initiate a discount activity and increase exposure at the same time. Among them, the process of encoding the decision to be operated of the target merchant may refer to the above-mentioned encoding process of the merchant information and the business district information, which will not be repeated here.

[0059] It should be pointed out that commonly used prediction models (such as TARNet model and Dragonnet model) usually only support training for one decision, so that the prediction model obtained by training also only supports prediction of one corresponding decision, while in the technical solution of the embodiment of the present application, the decision representation can be a representation of at least one decision. It can be seen that the technical solution of the embodiment of the present application supports the use of one prediction model to predict at least one decision, which has a wide coverage.

[0060] Furthermore, after inputting the initial merchant representation and the environmental representation, the re-encoding module 202 may use the semantic vector after encoding each item of information in the merchant information as an initial representation factor of the initial merchant representation, and then the initial merchant representation includes multiple initial representation factors. Similarly, the semantic vector after encoding each item of information in the business district information may be used as an environmental representation factor of the environmental representation, and then the environmental representation includes multiple environmental representation factors. Furthermore, after extracting the initial merchant representation and the environmental representation, the influence coefficients of the multiple environmental representation factors on the multiple initial representation factors may be calculated, and then, for any initial representation factor, the initial representation factor may be re-weighted according to the influence coefficients of each environmental representation factor on the initial representation factor; the re-weighted multiple initial representation factors may be concatenated to obtain the merchant representation.

[0061] Exemplarily, the re-encoding module 202 may calculate the influence coefficients of the multiple environmental representation factors on the multiple initial representation factors based on a gate attention algorithm. Figure 2B As shown, Figure 2B is an exemplary structural diagram of the re-encoding module 202, combined with Figure 2B It can be seen that the recoding module 202 can splice the initial merchant representation and the environment representation to obtain a vector sequence to be recoded, and then calculate the attention value between each vector in the vector sequence based on the attention mechanism in the gated attention algorithm. Any attention value represents the degree of influence between two vectors. Based on this, each attention value can be considered as an influence coefficient. Then, the above attention values ​​are adjusted based on the gating mechanism in the gated attention algorithm, and the re-weighted value of each initial representation factor is calculated according to the adjusted attention values, and then, each initial representation factor is re-weighted according to the corresponding re-weighted value. The gating mechanism can be implemented, for example, by a Sigmoid function.

[0062] It should be pointed out that each of the above-mentioned characterization factors includes an initial weight, which may be the corresponding embedding weight in the embedding process. The reweighting described in the embodiment of the present application may refer to reweighting based on the embedding weights of each initial characterization factor.

[0063] It should be understood that for any initial characterization factor, the re-weighted value of the initial characterization factor is determined according to the degree of influence of other characterization factors on it. Then, in some optional examples, the re-weighted value of the initial characterization factor can be a positive number, that is, in this example, the influence of other characterization factors on the initial characterization factor is relatively large. In other optional examples, the re-weighted value of the initial characterization factor can be a negative number, that is, in this example, other characterization factors have a negative influence on the initial characterization factor.

[0064] It can be seen that by adopting this implementation method, the initial merchant representation of the target merchant is re-encoded according to the market environment representation of the target merchant's environment, which is conducive to incorporating the impact of the target merchant's environment on the target merchant into the target merchant's representation, so that the merchant representation can reflect the personalized characteristics of the target merchant in the environment.

[0065] In some embodiments, after the initial merchant representation is re-encoded according to the environment representation to obtain the merchant representation, the method further includes: extracting the encoding data corresponding to the merchant representation; and calling a parameter generation algorithm to calculate the parameters of the prediction algorithm according to the encoding data.

[0066] The parameter generation algorithm may be Figure 2A The algorithm executed by the parameter generation algorithm module 203 in FIG. 200 and the calculation scenario diagram of the parameter generation algorithm module 203 can be as follows: Figure 2C Reference Figure 2C After inputting the merchant representation, the merchant representation is encoded by multilayer perceptron (MLP) such as nonlinear mapping, feature classification, and dimension reduction. Then, the encoded data processed by MLP is Input parameter generation network (PGN), which generates Calculate the parameters of the prediction algorithm module 205 .

[0067] Figure 2A In They are the parameters of PGN, and the parameter values ​​can be trained.

[0068] In some other embodiments, after the recoding module 202 recodes the initial merchant representation according to the environment representation to obtain the merchant representation, it also includes: the feature fusion module 204 fuses the decision representation and the merchant representation to obtain the feature to be predicted. Specifically, the feature fusion module 204 can select at least one merchant representation factor whose influence on the result corresponding to the decision representation is greater than a preset degree; reweight the at least one merchant representation factor to obtain at least one prediction factor; fuse the decision representation, the merchant representation and the at least one prediction factor to obtain a fused feature; extract the feature to be predicted from the fused feature.

[0069] This will help improve the model's ability to explore the influence relationship between decision representation and merchant representation, so that the extracted features to be predicted are features that can express the influence of decision representation on merchant representation, and thus improve the accuracy of decision prediction results.

[0070] Exemplarily, the feature fusion module 204 may deploy a gate attention algorithm, and through the gate mechanism (e.g., Sigmoid function) in the gate attention algorithm, screen at least one merchant characterization factor whose influence on the result corresponding to the decision representation is greater than a preset degree, and then reweight the at least one merchant characterization factor to obtain at least one prediction factor. In this way, it is helpful to apply the influence of the merchant characterization on the decision representation to the decision representation, so that the obtained prediction factor can reflect the influence of the merchant's personalized characteristics on the decision.

[0071] It should be understood that the architecture of the gate attention algorithm deployed in the feature fusion module 204 is similar to Figure 2B In addition, although the gate attention algorithm is deployed in the feature fusion module 204 and Figure 2B The illustrated algorithm architectures are similar, but the two gate attention algorithms input different representation data, and the corresponding data processing stages are also different. Based on this, the model parameters related to the two gate attention algorithms are different.

[0072] refer to Figure 2D , Figure 2D is an exemplary structural diagram of the feature fusion algorithm module 204, combined with Figure 2D In some embodiments, after the decision representation, the merchant representation and the at least one prediction factor are fused to obtain the fused feature, the feature fusion module 204 can extract the feature to be predicted from the fused feature based on the self-attention algorithm. Specifically, the correlation parameter between the decision representation and each fused feature value in the fused feature can be calculated based on the self-attention algorithm, and then the fused feature value whose correlation parameter is greater than the preset correlation threshold is determined as the feature value of the feature to be predicted, so as to obtain the feature to be predicted.

[0073] Combined with the above description of decision representation, it can be seen that the embodiment of the present application can predict the operational results of at least one decision, that is, the merchant decision prediction model of the embodiment of the present application supports the prediction of multiple decisions, and all decision features of numerical types can be predicted, which not only has a wide coverage but also has good applicability.

[0074] It should be pointed out that, again, Figure 2AIt can be seen that the parameter generation algorithm module 203 and the feature fusion module 204 are two independent algorithm models. Based on this, in some embodiments, after obtaining the merchant representation, the implementation process of calculating the parameters of the prediction algorithm based on the merchant representation and the process of fusing the decision representation and the merchant representation can be executed in parallel.

[0075] The following training model is obtained FIG. 2A to FIG. 2D The process of the model shown is explained.

[0076] See also Figure 3 , Figure 3 This is a schematic diagram of an exemplary scenario of a prediction model for training merchant decisions provided in an embodiment of the present application. Figure 3 The illustrated model to be trained 30 may include an encoding network 301 , a re-encoding network 302 , a parameter generation network 303 , a sample balancing network 304 , a feature fusion network 305 and a prediction network 306 .

[0077] In this implementation scenario, the input information may be merchant sample information, business district sample information, and decision sample information to be predicted. The merchant sample information includes various types of known merchant information and the actual execution results of the corresponding merchant information on known decisions. The decision sample information to be predicted may be any one or more preset decision information. Figure 3 , the encoding network 301 is used to extract semantic vectors from the merchant sample information, the business district sample information and the decision sample information to be predicted, respectively, to obtain the corresponding merchant sample initial representation, business district sample representation and decision sample representation to be predicted, and then output the merchant sample initial representation and the business district sample representation to the re-encoding module 302, and output the decision sample representation to be predicted to the sample balancing network 304 and the feature fusion network 305. The re-encoding network 302 re-encodes the merchant sample initial representation and the business district sample representation to obtain the corresponding merchant sample representation, and outputs the merchant sample representation to the parameter generation network 303, the sample balancing network 304 and the feature fusion network 305 respectively. The parameter generation network 303 calculates the network parameters of the prediction network 306 based on the merchant sample representation. The sample balancing network 304 can be used to calculate the confounder bias generated by the sample from the perspective of the merchant sample representation and the representation of the decision to be predicted, respectively, and apply the corresponding confounder bias to the prediction result of the merchant sample representation, so as to eliminate the confounder bias by weighting the corresponding prediction result with the propensity score. The feature fusion network 305 fuses the representation of the decision to be predicted and the merchant sample representation to obtain feature data for prediction, and then enables the prediction network 306 to process the feature data for prediction and output the prediction result.

[0078] It should be pointed out that Figure 3 The encoding network 301, the re-encoding network 302, the parameter generation network 303, the feature fusion network 305 and the prediction network 306 can be Figure 2A The corresponding algorithm module in the algorithm module is not trained, but Figure 3 For the specific structure and data processing process of the above networks, please refer to FIG. 2A to FIG. 2D The description of the corresponding embodiments will not be repeated here.

[0079] The following describes the training process involved in the embodiment of the present application by taking any merchant sample representation obtained by processing the re-encoding network 302 as the target sample representation.

[0080] The target sample representation is obtained through the encoding network 301 and the re-encoding network 302. After that, the parameter generation network 303 is called to calculate the network parameters of the prediction network according to the target sample representation, and the prediction network 306 calculated with the network parameters is called to generate the prediction result sample of the decision to be predicted using the target sample representation. In parallel, the sample balancing network 304 can be called to generate the first sample feature correction parameter and the second sample feature correction parameter for the decision to be predicted; the correction result of the prediction result sample is calculated according to the first sample feature correction parameter and the second sample feature correction parameter. Further, the loss value of the actual decision result corresponding to the correction result and the target sample representation is calculated. If the loss value does not meet the convergence condition, the parameters of each network included in the model to be trained are adjusted, and the step of obtaining the target sample representation is performed again; if the loss value meets the convergence condition, the model to be trained is determined as the model of the prediction method for executing the merchant decision.

[0081] Among them, the first sample feature correction parameter can correspond to the deviation of the target sample representation in the distribution of different decision values ​​of the decision to be predicted, and the second sample feature correction parameter can correspond to the personalized characteristics and quantity of the target sample representation in multiple merchant sample representations, and the deviation of the covariate of the decision to be predicted.

[0082] Regarding the calculation of the first sample feature correction parameter, for any decision value of the decision to be predicted, calculate the probability distribution of each sub-representation respectively contained in the multiple merchant sample representations at the decision value; calculate the maximum mean difference (Maximum Mean Discrepancy, MMD) of the probability distribution between the decision values ​​of the decision to be predicted, and obtain at least one MMD; determine the at least one MMD as the first sample feature correction parameter.

[0083] Combined with the above description of the decision value, it can be known that the decision value of the decision to be predicted can be a discrete or continuous value. If the decision value of the decision to be predicted is discrete, the decision value of the decision to be predicted can also be a binary or multi-valued value. For example, the prediction decision is "whether to participate in the promotion activity", the corresponding decision value is 1 (indicating participation) or 0 (indicating non-participation), that is, the decision value is a binary type; for another example, the prediction decision is "the model of the new product to be launched", the corresponding decision value is 01 (indicating small size), 10 (indicating medium size) or 11 (indicating large size), that is, the decision value is discrete and multi-valued; for another example, the prediction decision is "merchant rating", the corresponding decision value is a plurality of continuous scores from 1 to 5 points, and the corresponding decision value is a continuous type.

[0084] In some embodiments, if the decision to be predicted includes at least two discrete decision values, the MMD between probability distributions corresponding to any two of the at least two discrete decision values ​​is calculated to obtain the at least one MMD.

[0085] For example, when the decision value of the decision to be predicted is a binary type, the MMD between the probability distributions corresponding to the two decision values ​​is calculated to obtain one MMD. When the decision value of the decision to be predicted is a discrete three-value type, the MMD between the probability distributions corresponding to the two decision values ​​is calculated respectively to obtain two MMDs.

[0086] In some other embodiments, if the decision to be predicted includes multiple continuous decision values, the multiple continuous decision values ​​are sorted according to their sizes; half of the multiple continuous decision values ​​are determined as first-class decision values ​​in the sorted order, and the other half of the multiple continuous decision values ​​are determined as second-class decision values; and the MMD of the probability distribution corresponding to the first-class decision values ​​and the probability distribution corresponding to the second-class decision values ​​are respectively calculated.

[0087] It can be seen that the algorithm model using this implementation method is compatible with the calculation of correction parameters (i.e., tendency score estimation) for discrete decisions and continuous decisions, thereby making the model widely adaptable.

[0088] See again Figure 3 Regarding the calculation of the second sample feature correction parameter, the sample balancing network 304 calculates the predicted probability of the target sample representation executing the decision to be predicted; calculates the balancing weight of the target sample representation based on the predicted probability and the actual execution result of the decision to be predicted by the target sample representation, so as to balance the influence of the balanced multiple merchant sample representations on the decision variable to be predicted; and determines the balancing weight as the second sample feature correction parameter.

[0089] Exemplarily, the sample balancing network 304 can call the Transformer algorithm model to process the above-mentioned multiple merchant sample representations in parallel to understand and classify the above-mentioned multiple merchant sample representations. Then, the prediction network 306 can be called to calculate the predicted probability of each merchant sample representation executing the decision to be predicted, and then the balancing weight is calculated according to the predicted probability and the actual execution result of the target sample representation. .

[0090] And according to the number of merchants of the same type as the target sample representation in multiple merchant sample representations, a re-weighted value of the target sample representation is obtained, and the re-weighted value is used to balance the number of merchant sample representations of this type.

[0091] Can satisfy: ,

[0092]

[0093] in, It refers to the decision value of the decision to be predicted; It refers to the prediction model parameters corresponding to the target sample representation. It refers to the probability that the target sample represents the decision value of executing the decision to be predicted.

[0094] ; It refers to the actual execution result of the target sample representation; It refers to the predicted probability corresponding to the target sample representation.

[0095] Furthermore, the loss value loss can satisfy, for example:

[0096]

[0097] Wherein, h refers to the parameter of the sample balancing network 304, refers to the parameters of the parameter generation network 303, n refers to the total number of merchants of the same type as the merchant sample corresponding to the target sample representation, refers to the reweighted value of the target sample representation, L() refers to the loss function, refers to the prediction network 306, and is the weight, means The corresponding MMD value.

[0098] It can be seen that by adopting this implementation method, by calculating the bias impact on the decision samples and the bias impact on the distribution of samples of various types of merchants, the prediction results of tendency scores in different dimensions are obtained, thereby eliminating the confounding bias generated by samples during the training process from many aspects, so that the merchant decision prediction model obtained by training has better performance and higher prediction accuracy.

[0099] It should be understood that Figures 2A to 3 The illustrated algorithm models are schematic representations of the algorithm models involved in the embodiments of the present application, and do not constitute a limitation on the algorithm models involved in the embodiments of the present application. In the actual implementation process, various algorithm models can also include more or fewer algorithm layers, and the present application does not limit this.

[0100] It should be understood that Figures 2A to 3 The algorithm models and algorithm networks illustrated in the figure can be implemented in the form of hardware or a combination of hardware and computer software. Whether the processing steps of any relevant component are executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Professional and technical personnel can also use different methods to implement the functions described in the above embodiments for specific applications, but such implementation should not be considered to be beyond the scope of this application.

[0101] For example, if the above-mentioned implementation steps can realize corresponding functions through software modules, corresponding to the above-mentioned merchant decision prediction method, the embodiment of the present application can also provide a merchant decision prediction device.

[0102] like Figure 4 As shown, a prediction device for merchant decision is provided, and the prediction device for merchant decision may include a feature extraction module 41, a recoding module 42, a feature fusion module 43 and a prediction module 44. The prediction device for merchant decision can be used to perform the above Figures 1 to 3 Some or all of the operations in .

[0103] For example: a feature extraction module 41 is used to extract the initial merchant representation of the target merchant, the environmental representation and decision representation corresponding to the target merchant, wherein the environmental representation refers to the representation of the business district environment in which the target merchant is located; a recoding module 42 is used to recode the initial merchant representation according to the environmental representation to obtain the merchant representation; a feature fusion module 43 is used to fuse the decision representation and the merchant representation to obtain the feature to be predicted; a prediction module 44 is used to call the prediction algorithm matched with the target merchant to process the feature to be predicted, and obtain the prediction result of the decision of the target merchant corresponding to the decision representation, and the parameters of the prediction algorithm are calculated according to the merchant representation.

[0104] Optionally, the initial merchant representation includes multiple initial representation factors, and the environmental representation includes multiple environmental representation factors; the device also includes a splicing module; the recoding module 42 is also used to calculate the influence coefficients of the multiple environmental representation factors on the multiple initial representation factors respectively; and for any initial representation factor, the initial representation factor is re-weighted according to the influence coefficient of each environmental representation factor on the initial representation factor; the splicing module is used to splice the multiple re-weighted initial representation factors to obtain the merchant representation.

[0105] Optionally, the feature extraction module 41 is further used to extract the coding data corresponding to the merchant representation; the prediction module 44 is further used to call a parameter generation algorithm to calculate the parameters of the prediction algorithm according to the coding data.

[0106] Optionally, the merchant representation includes multiple merchant representation factors, and the feature fusion module 43 is further used to screen at least one merchant representation factor whose influence on the result corresponding to the decision representation is greater than a preset degree; reweight the at least one merchant representation factor to obtain at least one prediction factor; and fuse the decision representation, the merchant representation and the at least one prediction factor to obtain a fused feature; the feature extraction module 41 is also used to extract the feature to be predicted from the fused feature.

[0107] Optionally, the device also includes a calculation module, wherein the calculation module is used to calculate the correlation parameters between the decision representation and each fused feature value in the fused feature; the feature extraction module 41 is also used to determine the fused feature value whose correlation parameter is greater than a preset correlation threshold as the feature value of the feature to be predicted, so as to obtain the feature to be predicted.

[0108] Optionally, the device also includes an acquisition module, a generation module, a parameter adjustment module and a determination module, wherein the acquisition module is used to acquire a target sample representation, and the target sample representation is one of a plurality of pre-set merchant sample representations; the prediction module 44 is also used to call a parameter generation network to calculate network parameters of a prediction network according to the target sample representation, and both the parameter generation network and the prediction network belong to models to be trained; and to call a prediction network calculated with the network parameters to generate a prediction result sample of the target sample representation using a decision to be predicted; the generation module is used to generate a first sample feature correction for the decision to be predicted. Parameters and second sample feature correction parameters; the calculation module is also used to calculate the correction result of the prediction result sample according to the first sample feature correction parameters and the second sample feature correction parameters; and calculate the loss value of the actual decision result corresponding to the correction result and the target sample representation; the parameter adjustment module is used to adjust the parameters of each network included in the model to be trained if the loss value does not reach the convergence condition, and trigger the acquisition module again to execute the acquisition of the target sample representation; the determination module is used to determine the model to be trained as the model of the prediction method for executing the merchant decision if the loss value reaches the convergence condition.

[0109] Optionally, the generation module is further used to calculate, for any decision value of the decision to be predicted, the probability distribution of each sub-representation respectively contained in the multiple merchant sample representations at the decision value; the calculation module is further used to respectively calculate the maximum mean difference MMD of the probability distribution between the decision values ​​of the decision to be predicted, to obtain at least one MMD; the determination module is further used to determine the at least one MMD as the first sample feature correction parameter.

[0110] Optionally, the calculation module is further used to calculate the MMD between the probability distributions corresponding to any two of the at least two discrete decision values ​​if the decision to be predicted includes at least two discrete decision values, so as to obtain the at least one MMD.

[0111] Optionally, the calculation module is also used to sort the multiple continuous decision values ​​according to the sizes of the multiple continuous decision values ​​if the decision to be predicted includes multiple continuous decision values; the determination module is also used to determine half of the multiple continuous decision values ​​as first-class decision values ​​in the sorting order, and determine the other half of the multiple continuous decision values ​​as second-class decision values; the calculation module is also used to respectively calculate the MMD of the probability distribution corresponding to the first-class decision values ​​and the probability distribution corresponding to the second-class decision values.

[0112] Optionally, the calculation module is also used to calculate the predicted probability of the target sample representation executing the decision to be predicted; and to calculate the balance weight of the target sample representation based on the predicted probability and the actual execution result of the decision to be predicted by the target sample representation, so as to balance the influence of the balanced multiple merchant sample representations on the decision variables to be predicted; the determination module is also used to determine the balance weight as the second sample feature correction parameter.

[0113] Understandably, Figure 4 The division of each module is only a division of logical functions. In actual implementation, the functions of the above modules can be integrated into the hardware entity implementation. For example, the functions of the feature extraction module 41, the re-encoding module 42, the feature fusion module 43 and the prediction module 44 can be integrated into the processor implementation, and the function of the acquisition module can be integrated into the transceiver implementation, etc.

[0114] Please refer to Figure 5 , Figure 5 An electronic device is provided, which includes a processor 511, a transceiver 512 and a memory 513, and these components are connected and communicated through a communication bus 514. Among them, the transceiver 512 can be used for sending and receiving merchant information, business district information, and decision information. The memory 513 is used to store program instructions of the electronic device, as well as semantic vectors generated in the process of predicting merchant decisions, etc. When the program instructions are called, the processor 511 executes the above Figures 1 to 3 operation of part or all of the electronic equipment in the

[0115] For the specific implementation process, see Figures 1 to 3 The relevant description in is not repeated here.

[0116] A computer-readable storage medium is also provided in an embodiment of the present application. The computer-readable storage medium stores instructions for predicting merchant decisions. When the instructions are executed on a computer, the computer executes part or all of the steps in the method described in the above-mentioned embodiment.

[0117] The embodiment of the present application also provides a computer program product including instructions for predicting merchant decisions. When the computer program product is executed on a computer, the computer executes part or all of the steps in the method described in the above-mentioned embodiment.

[0118] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.

[0119] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.

[0120] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0121] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.

[0122] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions to enable a computer device (which can be a personal computer, a smart phone or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.

[0123] Although the optional embodiments of the present application have been described, those skilled in the art, once informed of the basic creative concept, may make additional changes and modifications to these embodiments. Therefore, the appended claims are intended to be interpreted as including the preferred embodiment and all changes and modifications falling within the scope of the present application.

[0124] The specific implementation methods described above further illustrate the purpose, technical solutions and beneficial effects of the present application in detail. It should be understood that the above description is only the specific implementation method of the present application and is not intended to limit the scope of protection of the present application. Any modifications, equivalent substitutions, improvements, etc. made on the basis of the technical solutions of the present application should be included in the scope of protection of the present invention.

Claims

1. A prediction method for merchant decision making, characterized in that: The method comprises: Extracting the initial merchant representation of the target merchant, the environment representation and decision representation corresponding to the target merchant, wherein the environment representation refers to the representation of the business district environment where the target merchant is located, and the initial merchant representation is obtained by encoding the merchant information of the target merchant, wherein the merchant information includes at least one of the establishment time, commodity types, prices, merchant ratings, brand influence, advertising placement, and membership system of the target merchant; the business district environment includes at least one of the consumer flow, consumer characteristics, and the competitive environment of the target merchant; the decision representation is used to indicate the decision to be operated by the target merchant; Re-encoding the initial merchant representation according to the environment representation to obtain a merchant representation; Fusion of the decision representation and the merchant representation to obtain features to be predicted; Calling the prediction algorithm matched with the target merchant to process the feature to be predicted, and obtaining the prediction result of the decision corresponding to the decision representation of the target merchant, wherein the parameters of the prediction algorithm are calculated according to the merchant representation; The method further comprises: Obtaining a target sample representation, where the target sample representation is one of a plurality of preset merchant sample representations; Generate a first sample feature correction parameter and a second sample feature correction parameter for the decision to be predicted; Training the to-be-trained model according to the first sample feature correction parameter and the second sample feature correction parameter to obtain a model for executing the prediction method for the merchant decision; The generating a second sample feature correction parameter for the decision to be predicted includes: Calculating the predicted probability of the target sample representing the execution of the decision to be predicted; Calculating a balancing weight of the target sample representation according to the predicted probability and the actual execution result of the target sample representation on the decision to be predicted, so as to achieve a balanced degree of influence of the balanced multiple merchant sample representations on the decision variable to be predicted; The balance weight is determined as the second sample feature correction parameter.

2. The method according to claim 1, characterized in that: The initial merchant representation includes a plurality of initial representation factors, the environment representation includes a plurality of environment representation factors, and the re-encoding the initial merchant representation according to the environment representation to obtain the merchant representation includes: Calculating the influence coefficients of the multiple environmental characterization factors on the multiple initial characterization factors respectively; For any initial characterization factor, re-weight the initial characterization factor according to the influence coefficient of each environmental characterization factor on the initial characterization factor; The merchant representation is obtained by concatenating the re-weighted multiple initial representation factors.

3. The method according to claim 1 or 2, characterized in that: After the initial merchant representation is re-encoded according to the environment representation to obtain the merchant representation, the method further includes: Extracting the encoding data corresponding to the merchant representation; A parameter generation algorithm is called to calculate the parameters of the prediction algorithm based on the encoded data.

4. The method according to claim 1, characterized in that: The merchant representation includes a plurality of merchant representation factors, and the fusion of the decision representation and the merchant representation to obtain the feature to be predicted includes: Screening at least one merchant representation factor having an influence on the result corresponding to the decision representation greater than a preset degree; Re-weighting the at least one merchant characterization factor to obtain at least one prediction factor; fusing the decision representation, the merchant representation, and the at least one prediction factor to obtain a fused feature; The feature to be predicted is extracted from the fused features.

5. The method according to claim 4, characterized in that The extracting the feature to be predicted from the fused features includes: Calculating correlation parameters between the decision representation and each fusion feature value in the fusion feature; The fused feature value whose correlation parameter is greater than a preset correlation threshold is determined as the feature value of the feature to be predicted, so as to obtain the feature to be predicted.

6. The method according to claim 1, characterized in that Also includes: Obtaining a target sample representation, where the target sample representation is one of a plurality of preset merchant sample representations; Calling a parameter generation network to calculate network parameters of a prediction network according to the target sample representation, wherein both the parameter generation network and the prediction network belong to the model to be trained; Calling a prediction network that is calculated using the network parameters to generate a prediction result sample of the target sample representation using the decision to be predicted; Generate a first sample feature correction parameter and a second sample feature correction parameter for the decision to be predicted; Calculate the correction result of the prediction result sample according to the first sample feature correction parameter and the second sample feature correction parameter; Calculating the loss value of the correction result and the actual decision result corresponding to the target sample representation; If the loss value does not reach the convergence condition, adjust the parameters of each network included in the model to be trained, and perform the step of obtaining the target sample representation again; If the loss value reaches the convergence condition, the model to be trained is determined as a model for executing the prediction method for the merchant decision.

7. A prediction device for merchant decision making, characterized in that: The device comprises: A feature extraction module is used to extract the initial merchant representation of the target merchant, the environment representation corresponding to the target merchant, and the decision representation. The environment representation refers to the representation of the business district environment where the target merchant is located; the initial merchant representation is obtained by encoding the merchant information of the target merchant, and the merchant information includes at least one of the establishment time, product types, prices, merchant ratings, brand influence, advertising, and membership system of the target merchant; the business district environment includes at least one of the consumer flow, consumer characteristics, and competitive environment of the target merchant in the business district; the decision representation is used to indicate the decision to be operated by the target merchant; A re-encoding module, configured to re-encode the initial merchant representation according to the environment representation to obtain a merchant representation; A feature fusion module, used for fusing the decision representation and the merchant representation to obtain a feature to be predicted; A prediction module, used for calling the prediction algorithm matched with the target merchant to process the features to be predicted, and obtaining the prediction result of the decision corresponding to the decision representation of the target merchant, wherein the parameters of the prediction algorithm are calculated according to the merchant representation; Also includes training modules, The training module is used to obtain a target sample representation, where the target sample representation is one of a plurality of preset merchant sample representations; Generate a first sample feature correction parameter and a second sample feature correction parameter for the decision to be predicted; Training the to-be-trained model according to the first sample feature correction parameter and the second sample feature correction parameter to obtain a model for executing the prediction method for the merchant decision; The generating a second sample feature correction parameter for the decision to be predicted includes: Calculating the predicted probability of the target sample representing the execution of the decision to be predicted; Calculating a balancing weight of the target sample representation according to the predicted probability and the actual execution result of the target sample representation on the decision to be predicted, so as to achieve a balanced degree of influence of the balanced multiple merchant sample representations on the decision variable to be predicted; The balance weight is determined as the second sample feature correction parameter.

8. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.