Payment risk identification method and apparatus, and electronic device
By building a deep learning model based on payment data sets, the problems of low accuracy of payment risk identification and poor applicability of the model in the prior art are solved, and higher accuracy of payment risk identification is achieved.
Patent Information
- Application Number
- CN202411843217.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-13
- Publication Date
- 2025-04-15
AI Technical Summary
In the prior art, deep learning models have limited generalization capabilities when facing new payment environments or new payment risk behaviors, resulting in low accuracy in payment risk identification and poor model applicability.
By obtaining the target payment data, training the initial model based on the payment data set, and building a payment risk identification model. The model includes a convolutional neural network, a recurrent neural network and multiple hidden layers. Through feature analysis and task-oriented network parameter configuration, the generalization ability of the model is improved.
The technical effect of improving the accuracy of payment risk identification has been achieved, and the problem of low accuracy of payment risk identification and poor applicability of the model has been solved.
Smart Images

Figure CN119831598A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of financial technology, and in particular to a payment risk identification method, device and electronic equipment. Background Art
[0002] With the popularity and development of mobile payment, wallet payment has become an indispensable part of people's lives. However, the payment risk problem that comes with it has gradually emerged. In order to improve the security of the payment system and user trust, it is necessary to establish an efficient risk identification model (or risk assessment model). However, the deep learning model in related technologies has limited generalization ability when facing new payment environments or new payment risk behaviors, resulting in low payment risk identification accuracy and poor model applicability.
[0003] To address the above-mentioned problems, no effective solution has been proposed yet. Summary of the invention
[0004] The embodiments of the present invention provide a payment risk identification method, device and electronic device to at least solve the technical problems of low payment risk identification accuracy and poor model applicability existing in the related art.
[0005] According to one aspect of an embodiment of the present invention, a payment risk identification method is provided, comprising: obtaining target payment data; based on the target payment data, using a payment risk identification model to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on data features of the payment data set, the payment data set includes multiple groups of payment data, and risk identification results corresponding to the multiple groups of payment data respectively.
[0006] According to another aspect of an embodiment of the present invention, a payment risk identification device is also provided, including: a data acquisition module for acquiring target payment data; a risk identification module for obtaining a payment risk identification result of the target payment data by adopting a payment risk identification model based on the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on data features of the payment data set, and the payment data set includes multiple groups of payment data, and risk identification results corresponding to the multiple groups of payment data respectively.
[0007] According to another aspect of an embodiment of the present invention, there is also provided an electronic device, comprising one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement any one of the payment risk identification methods.
[0008] In an embodiment of the present invention, target payment data is obtained; based on the target payment data, a payment risk identification model is adopted to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data, and the risk identification results corresponding to the multiple groups of payment data, respectively, thereby achieving the purpose of training and constructing a model according to the data features of the training data (i.e., multiple groups of payment data), and accurately identifying payment risks based on the trained payment risk identification model, thereby achieving the technical effect of improving the accuracy of payment risk identification, and further solving the technical problems of low payment risk identification accuracy and poor model applicability existing in the related art. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of this application. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings:
[0010] Figure 1 is a flow chart of a payment risk identification method according to an embodiment of the present invention;
[0011] Figure 2 is a flowchart of an optional initial model construction according to an embodiment of the present invention;
[0012] Figure 3 is a schematic diagram of a payment risk identification device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0013] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of the present invention.
[0014] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0015] First, to facilitate understanding of the embodiments of the present invention, some terms or nouns involved in the present invention are explained below:
[0016] The generalization ability of deep learning models refers to the ability of deep learning models to maintain the general laws and features they have learned when faced with new and unseen data.
[0017] Payment Risk Assessment refers to the process of evaluating and analyzing various risks that may arise in the payment process.
[0018] Integration of Multiple Activation Functions refers to the method of using multiple different types of activation functions simultaneously in a deep learning model and fusing them together to improve the expressiveness and generalization ability of the model.
[0019] According to an embodiment of the present invention, a method embodiment of payment risk identification is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0020] Figure 1 is a flow chart of a payment risk identification method according to an embodiment of the present invention. Figure 1 As shown, the method comprises the following steps:
[0021] Step S102, obtaining target payment data;
[0022] In step S102, by collecting and organizing the target payment data to be evaluated, input information is provided for subsequent payment risk identification based on the payment risk identification model, thereby ensuring that the payment risk identification model can perform risk assessment based on real-time or the latest data, thereby improving the timeliness and accuracy of identification.
[0023] Optionally, the payment data includes parameter values corresponding to multiple characteristic parameters of the payment transaction, wherein the multiple characteristic parameters may include but are not limited to transaction amount, transaction time, transaction location, transaction frequency, payment method, transaction product or service information, transaction device information, transaction account information, etc.
[0024] Step S104, based on the target payment data, adopt a payment risk identification model to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on the payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
[0025] In step S104 of the present application, the construction of the payment risk identification model is based on the payment data set, which means that the model is trained on the basis of a large amount of real payment data to learn the recognition pattern of payment risks. The initial model adopted is constructed based on the data characteristics of the payment data set, which means that the design of the initial model is based on an in-depth understanding and analysis of the payment data, and can better capture the commonalities and differences of payment risks. The multiple groups of payment data in the payment data set and their corresponding risk identification results can provide rich training samples for the model, helping the payment risk identification model learn how to distinguish between normal transactions and risky transactions.
[0026] Optionally, the payment risk identification model can be understood as a payment risk assessment model, and the corresponding payment risk identification result can be understood as a payment risk assessment result, which is used to evaluate and identify payment risks.
[0027] In an optional embodiment, when the payment risk identification model includes a convolutional neural network, a recurrent neural network, and multiple hidden layers, the payment risk identification model is used based on the target payment data to obtain a payment risk identification result of the target payment data, including: using a convolutional neural network to extract spatial features in the target payment data; using a recurrent neural network to extract time series features in the target payment data; using multiple hidden layers to process the spatial features and time series features to obtain a payment risk identification result.
[0028] Optionally, the Convolutional Neural Network (CNN) in the payment risk identification model focuses on the spatial features in the payment data through convolution operations, for example, the combination relationship between different transaction features, and can extract meaningful patterns from the multi-dimensional structure of the payment data. CNN can capture local dependencies in the data and is particularly effective in identifying payment risks based on spatial distributions such as geographic location and commodity type. Recurrent Neural Network (RNN) is good at processing sequence data and can capture time-dependent features in payment data, such as transaction time, transaction frequency, user behavior sequence, etc. The memory property of RNN enables it to consider transaction history, which is crucial for identifying abnormal payment patterns based on time series (such as sudden large transactions, non-working hours transactions, etc.). Multiple hidden layers allow the model to perform deep feature learning, and through hierarchical abstraction and combination, the payment risk identification model can learn more complex and deeper feature representations in the payment data. This helps the payment risk identification model understand the complexity of transaction data and improves the payment risk identification model's ability to identify new risks.
[0029] In an optional embodiment, when the payment risk identification model also includes an attention layer, a batch normalization layer and an output layer, multiple hidden layers are used to process spatial features and time series features to obtain payment risk identification results, including: using multiple hidden layers to perform feature extraction processing on spatial features and time series features to obtain multiple feature representations, wherein the multiple feature representations correspond one-to-one to the multiple hidden layers; using the attention layer to weight the multiple feature representations to obtain weighted feature representations; using the batch normalization layer to process the weighted feature representation to obtain a normalized feature representation; based on the normalized feature representation, using the output layer to obtain the payment risk identification result.
[0030] Optionally, the attention layer in the payment risk identification model can focus the model's attention on key features in the payment data by assigning different weights to different feature representations, eliminating or reducing the interference of irrelevant features. This helps improve the recognition accuracy of the model, especially in scenarios where the payment data contains a large amount of non-critical information or noise. The batch normalization layer can reduce the scale difference between features through normalization processing, accelerate the model convergence speed, and improve the training stability. By normalizing the feature representation, the trained payment risk identification model can better handle the input of different payment data, reduce the risk of overfitting caused by inconsistent feature distribution, and thus improve the generalization ability of the payment risk identification model. The output layer is responsible for converting the processed feature representation into the final result of payment risk identification, such as risk probability or risk category. By using appropriate activation functions (such as Sigmoid for binary classification and Softmax for multi-class classification), the output layer can provide clear risk assessment results, which facilitates the payment system to make corresponding risk management and decisions.
[0031] In an optional embodiment, before obtaining the payment risk identification results of the target payment data by using a payment risk identification model based on the target payment data, the method also includes: performing feature analysis on multiple groups of payment data to obtain data features of the multiple groups of payment data; determining the task types of the risk identification results corresponding to the multiple groups of payment data, wherein the task type is any one of the following: binary classification task, multi-classification task, regression task; determining network layer parameters based on data features and task types; and constructing an initial model based on a convolutional neural network, a recurrent neural network, and network layer parameters.
[0032] Optionally, by performing feature analysis on multiple groups of payment data, the structure, distribution, correlation and complexity of the data can be understood. Feature analysis helps to identify which data features are critical for payment risk identification, such as transaction amount, transaction frequency, geographic location, etc. The implementation of this step can ensure that the payment risk identification model can fully consider the actual situation of the data during the design phase, and help to build a payment risk identification model that is more in line with the characteristics of payment data. For example, the determination of the task type (binary classification, multi-classification, regression) affects the output form and training objectives of the payment risk identification model. Binary classification tasks are suitable for determining whether a transaction is risky; multi-classification tasks can identify different types of payment risks; regression tasks can be used to predict the degree of risk or loss. Clarifying the task type helps to select the appropriate model architecture and loss function to ensure that the output of the payment risk identification model matches the payment risk identification requirements. Based on the data features and task type, the parameters of the network layer (such as convolutional layer, recurrent layer and hidden layer), such as the number of layers, number of nodes, activation function, etc., can be determined. The optimization of network parameters is the core link in the design of payment risk identification model. Reasonable parameter configuration can improve the learning ability and generalization ability of the model, avoid overfitting and underfitting problems, and thus improve the accuracy and efficiency of payment risk identification. According to the feature analysis, task type and network layer parameter selection, an initial model suitable for payment risk identification is constructed. The combination of CNN and RNN, combined with specific network layer parameters, can enable the model to more effectively capture the spatial and temporal relationships in payment data and improve the ability to identify payment risks. The construction of the initial model is the basis for subsequent training and optimization, which can ensure that the model can learn the patterns and strategies of risk identification from the payment data set. Through the above targeted model design, more accurate identification results can be achieved, the risk of misjudgment and missed judgment can be reduced, and the security of payment and user experience can be improved.
[0033] In an optional embodiment, feature analysis is performed on multiple groups of payment data to obtain data features of the multiple groups of payment data, including: determining feature dimensions of the multiple groups of payment data; performing density analysis on the multiple groups of payment data to obtain feature density; performing sparsity analysis on the multiple groups of payment data to obtain sparsity indicators, wherein data features include feature dimensions, feature density and sparsity indicators.
[0034] Optionally, feature dimension refers to the length of the feature vector, that is, the number of features contained in the payment data. Determining the feature dimension helps understand the complexity and information content of the data, and is crucial for the design of the input layer of the model. Low dimensions may mean missing information, while high dimensions may increase the difficulty of model training and waste computing resources. By analyzing the feature dimension, the design of the model input layer can be optimized to ensure that the trained payment risk identification model can efficiently process payment data. Feature density can reflect the distribution of data in the feature space. High-density data means that the feature values are more concentrated, while low-density data means that the feature values are more sparsely distributed. Feature density analysis helps identify whether there are a large number of missing values or non-informative features in the data. Understanding feature density can help design more reasonable data preprocessing strategies, such as filling missing values, removing noise or non-informative features, thereby improving the training efficiency and prediction performance of the payment risk identification model. The sparsity index measures the sparsity of the feature vector in the payment data, that is, the proportion of non-zero elements in the feature vector. Payment data may be highly sparse due to factors such as user behavior patterns and transaction types. Data with high sparsity may contain a large number of zero values or inactive features, which will increase the complexity of model training and may lead to inadequate patterns learned by the model. By calculating the sparsity index, targeted strategies can be adopted to process sparse data, such as feature selection, dimensionality reduction, or sparse optimization algorithms, to improve the payment risk identification model's ability to process sparse payment data.
[0035] In summary, through detailed feature analysis (feature dimension, feature density, sparsity index), in-depth insights at the data level are provided for the construction of payment risk identification models. The results of feature analysis can guide the selection and adjustment of model architecture, ensuring that the model can effectively process specific payment data sets and avoid performance problems caused by improper model design. Preprocessing strategies (such as filling missing values and removing non-informative features) can reduce the computational burden of model training, accelerate model convergence, and reduce the risk of overfitting. By processing sparsity and non-informative features, the model can maintain good generalization performance in a wider range of payment scenarios, and can make accurate identifications even in the face of new payment risks with different feature distributions.
[0036] In an optional embodiment, network layer parameters are determined based on data features and task types, including: determining input layer parameters based on data features, wherein the input layer parameters include at least the initial number of nodes of the input layer; determining hidden layer parameters based on data features and task types, wherein the hidden layer parameters include at least the initial number of nodes and activation functions corresponding to multiple hidden layers respectively; determining output layer parameters based on task types, wherein the output layer parameters include at least the initial number of nodes of the output layer, and the network layer parameters include input layer parameters, hidden layer parameters, and output layer parameters.
[0037] Optionally, the initial number of nodes in the input layer is determined based on the characteristic dimensions of the payment data, which means that the model can receive and process all relevant payment features. Reasonable setting of the input layer parameters can ensure that the model does not lose information due to incomplete input data, while avoiding unnecessary computational burden. The determination of the hidden layer parameters (including the number of nodes and the selection of activation functions) is based on in-depth analysis of data characteristics and task types. The task type (such as binary classification or multi-classification recognition of payment risks) affects the structure of the hidden layer, while the data characteristics (such as sparsity, nonlinear relationship) guide the selection of activation functions. Reasonable hidden layer parameter configuration enables the model to more effectively learn the inherent patterns and complex relationships of payment data, and improve the accuracy and robustness of recognition. The determination of the output layer parameters (such as the number of nodes) is based on the task type, ensuring that the output form of the payment risk identification model after training matches the requirements of payment risk identification. For example, for binary classification tasks, the output layer usually has only one node to indicate whether the transaction is risky; for multi-classification tasks, the number of nodes in the output layer is the same as the number of risk categories; for regression tasks, the output layer may directly output a continuous value. The correct configuration of the output layer parameters can ensure that the payment risk identification model outputs clear and direct results, which is convenient for risk management and decision-making of the payment system. Through data analysis and task-oriented parameter configuration, a more sophisticated and customized network architecture is provided for the payment risk identification model.
[0038] In the above methods, the network parameters determined based on data characteristics and task types make the structure of the payment risk identification model more reasonable, can make full use of data information, reduce redundancy and computational waste in the training process, and improve the training efficiency and reasoning speed of the model. Reasonable configuration of network layer parameters helps the model better capture the key features in payment data, improve the accuracy and efficiency of payment risk identification, reduce false positives and false negatives, and enhance the generalization ability of the model, so that it can maintain stable performance when processing different payment scenarios and data distributions. By automatically determining network parameters according to data characteristics and task types in the model design stage, the workload of subsequent model adjustments can be reduced, blind trial and error and excessive parameter adjustment can be avoided, and the construction process of the trained payment risk identification model can be made more scientific and efficient. The determined network parameters can also help the model to efficiently use computing resources and avoid the waste of computing resources caused by unreasonable model structure, which is particularly important for scenarios that require real-time processing of a large number of payment transactions.
[0039] Optionally, an appropriate activation function can be selected according to the specific task to be solved (such as classification task, regression task, etc.) and the characteristics of the input data. The activation function may include, but is not limited to, a modified linear activation function ReLU, Sigmoid, Tanh, a leaky modified linear activation function Leaky ReLU, a hyperbolic tangent function Tanh, etc., and each activation function has different effects on data distribution and nonlinear modeling. The multiple hidden layers may include a first hidden layer, a second hidden layer, and a last hidden layer, wherein the first hidden layer, as the starting layer of the neural network, can select the ReLU function as the activation function. This is because ReLU can provide better results in most cases, and the calculation speed is also faster. The middle hidden layer, as the middle layer of the deep network, can select an activation function different from the first hidden layer, such as Tanh or Leaky ReLU. These activation functions can provide better performance when processing different features and data distributions. The last hidden layer, as a hidden layer close to the output layer, can select an appropriate activation function according to the output requirements of the specific task and data. For example, for classification tasks, Sigmoid or Softmax is used as the activation function of the last layer; for regression tasks, linear activation (without activation function) can be directly output or Tanh can be used. By fusing multiple activation functions, the appropriate activation function is dynamically selected according to different data types and features, so that the model can adapt to data distribution and features more flexibly in different scenarios. The above method can be understood as a mechanism for adaptive activation function, which enables the model to automatically select the appropriate activation function according to the characteristics of the input data. This method can improve the adaptability and generalization ability of the model while reducing the workload of manual parameter adjustment. Combining the attention mechanism and activation function optimization, the model can automatically learn and focus on important features in the input data, thereby improving the generalization ability and performance of the model.
[0040] In an optional embodiment, before obtaining the payment risk identification result of the target payment data by using the payment risk identification model based on the target payment data, the method further includes: for each training stage of training the initial model based on the payment data set, obtaining the training indicators corresponding to each training stage, wherein the training indicators include at least one of the following: the loss function value, the training set accuracy, and the verification set accuracy obtained in the corresponding training stage, each training stage includes a training stage based on the training set and a verification stage based on the verification set, and the payment data set includes a training set and a verification set; based on the training indicators, pruning the multiple hidden layers included in the initial model so that the number of nodes included in the multiple hidden layers is updated during the training of the initial model.
[0041] Optionally, at each stage of model training, training indicators are obtained and monitored, including loss function value, training set accuracy, and validation set accuracy. These indicators can reflect the learning state and generalization ability of the model during the training process. By monitoring these indicators, the training effect and potential problems of the payment risk recognition model, such as whether it is overfitting or underfitting, can be timely understood. According to the obtained training indicators, multiple hidden layers in the model are pruned. Pruning refers to removing or reducing redundant nodes and connections in the network without affecting the performance of the model to reduce the complexity of the model and the demand for computing resources. This pruning strategy based on training indicators can identify unimportant or redundant parts of the model, thereby optimizing the model structure. During the model training process, the number of nodes in the hidden layer is dynamically updated so that the model can adjust its complexity according to the actual effect of the training stage. This method allows the model to maintain a high complexity in the early stage of training to fully learn the data characteristics, and to reduce redundant nodes through pruning in the later stage of training, thereby improving the generalization ability and computing efficiency of the model.
[0042] In the above methods, pruning technology can remove unnecessary calculation paths, reduce the computing resources required for payment risk identification model training, and accelerate model convergence. Pruning can reduce the risk of overfitting, so that the payment risk identification model can perform better on unseen data (such as the validation set), and improve the accuracy and reliability of payment risk identification. Dynamically adjust the number of hidden layer nodes to ensure that the model maintains the most appropriate complexity at different training stages, avoid the payment risk identification model being too simple or too complex after training, and achieve a balance between performance and efficiency. It can be understood that the above method is a method of adaptive network structure, which automatically adjusts the number of network layers and nodes according to the characteristics and complexity of the input data. The obtained payment risk identification model can handle different types of data and tasks more effectively and achieve better performance in different scenarios. By automatically deleting redundant nodes and connections in the network, the number of parameters and computational complexity of the model can be reduced, while maintaining the performance and generalization ability of the payment risk identification model.
[0043] Optionally, in addition to the case where the number of hidden layer nodes is adjusted by automated methods or manual intervention in the process of model training by real-time monitoring of the model's performance indicators (such as the loss function or the accuracy of the validation set). The data features of the input payment data can also be analyzed before or during model training. This may include, but is not limited to, the dimensions, sparsity, and distribution of the calculated features. The analysis of these feature parameters can provide important clues about the complexity of the data and the appropriate model structure. Further predefined rules or strategies are designed to dynamically adjust the number of hidden layer nodes based on the results of the feature analysis. For example, the number of hidden layer nodes can be increased or decreased based on factors such as the size of the feature dimension and the sparsity of the data.
[0044] In an optional embodiment, when the initial model includes a convolutional neural network, a recurrent neural network, multiple hidden layers, an attention layer, and a batch normalization layer in sequence, before obtaining the payment risk identification result of the target payment data by adopting a payment risk identification model based on the target payment data, the method also includes: obtaining a feature representation of the output of the attention layer during training the initial model; and updating the normalization parameters of the batch normalization layer based on the feature representation of the output of the attention layer.
[0045] It should be noted that batch normalization (Batch Normalization, BN) in the relevant technology usually applies a unified normalization coefficient to the input of each layer, but this method may not fully take into account the actual importance changes of each feature in model training. The dynamic weight normalization strategy introduced by this embodiment dynamically adjusts the normalization parameters according to the feature distribution of each batch of data (i.e., the feature representation output by the attention layer). Specifically, for each feature parameter, the mean and variance are dynamically calculated according to its distribution in the current batch of data (i.e., the feature representation output by the attention layer), instead of using fixed historical statistics. According to the results of the feature importance evaluation, the weighted combination of the mean and variance of each feature parameter is dynamically calculated, and the attention mechanism is introduced. Specifically, the following formula can be used to calculate the mean and variance of dynamic normalization:
[0046]
[0047] Among them, x ij is the i-th feature value of the j-th sample in the current batch of data (i.e., the feature representation output by the attention layer), a ij is the weight calculated by the attention mechanism, and n is the batch size.
[0048] Optionally, based on the dynamic weight normalization, the strategy of feature importance weighting can be combined to adjust the normalization coefficient of each feature parameter according to its contribution to the model output. The above method can increase the attention of the payment risk identification model to important features, thereby improving the generalization ability and accuracy of the model. Specifically, based on the payment data set, feature selection or gradient-based methods can be used to evaluate the contribution of each feature parameter to the model performance. The dynamically calculated normalization parameter is further multiplied by the feature importance weighting coefficient to adjust the normalization process of each feature to make the impact of important features more significant.
[0049] In summary, in each training batch, the normalization parameters can be dynamically calculated based on the actual feature distribution of the current batch data. Combined with the feature importance evaluation results, the normalization parameters are weighted and adjusted to ensure that the payment risk identification model after training pays more attention to the changes and impacts of important features.
[0050] Optionally, different activation functions, such as ReLU, Sigmoid, Tanh, etc., can be used in each hidden layer of the network, and the outputs of different activation functions can be weighted and fused in combination with the attention mechanism to combine the advantages of each activation function, so that the payment risk identification model can more flexibly adapt to different data distributions and characteristics, so as to improve the flexibility and generalization ability of the payment risk identification model.
[0051] Optionally, after initial model training using a large-scale payment dataset, the performance and generalization ability of the payment risk identification model can be evaluated using methods such as cross-validation.
[0052] Through the above steps S102 to S104, it is possible to train and construct a model based on the data characteristics of the training data (i.e., multiple groups of payment data), and accurately identify payment risks based on the trained payment risk identification model, thereby achieving the technical effect of improving the accuracy of payment risk identification, and further solving the technical problems of low payment risk identification accuracy and poor model applicability existing in related technologies.
[0053] Based on the above embodiments and optional embodiments, the present invention proposes an optional payment risk identification method implementation method, the method comprising:
[0054] S1, structural design of the initial neural network model (i.e., initial model) with adaptive structure, Figure 2 is a flowchart of an optional initial model construction according to an embodiment of the present invention, wherein the initial neural network model includes an input layer, a convolutional neural network (CNN), a recurrent neural network (RNN), multiple hidden layers, an output layer, etc., wherein:
[0055] The input layer is used to receive input data (ie, payment data) and determine the number of nodes in the input layer according to the characteristic dimensions of the input data.
[0056] Convolutional neural network (CNN) is used as the basic network structure to extract spatial features in payment data.
[0057] Recurrent Neural Network (RNN) is used to process time series features in payment data, such as transaction time, frequency, etc.
[0058] Design multiple hidden layers, each with an adaptive number of nodes and activation function. The number of nodes and activation function of the hidden layer are dynamically adjusted according to the characteristics and complexity of the input data.
[0059] The output layer is determined according to the requirements of the task. It can be one neuron (for binary classification tasks), multiple neurons (for multi-classification tasks), or continuous value output (for regression tasks).
[0060] The number of nodes in each hidden layer can be adaptively adjusted according to the following methods: feature analysis is performed on the input data to calculate indicators such as feature dimension, density, and sparsity. The number of nodes in each hidden layer is dynamically adjusted based on the feature analysis results and the predefined adjustment strategy. For example, the number of nodes can be determined based on the size of the feature dimension or the sparsity of the data. During the model training process, the number of nodes in the hidden layer is dynamically adjusted based on the actual training effect and the feedback information of the validation set. For example, the optimal number of nodes can be determined through cross-validation or early stopping strategy.
[0061] The normalization parameters can also be adjusted dynamically according to the feature distribution of each batch of data.
[0062] S2, based on the payment data set, train the initial neural network model to obtain a payment risk assessment model (i.e., a payment risk identification model), wherein the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
[0063] S3, obtaining target payment data;
[0064] S4, based on the target payment data, adopts the payment risk identification model to obtain the payment risk identification result of the target payment data.
[0065] It should be noted that this embodiment is based on a deep learning algorithm, and improves the generalization ability of the payment risk assessment model (i.e., payment risk identification model) in the wallet payment field by optimizing innovations in network structure, training strategy, and activation function. Specifically, it includes the following aspects: 1) Network structure optimization: Design a deep learning network structure that is more suitable for payment risk assessment tasks. Taking into account the characteristics and complexity of payment data, optimize the number of layers, number of nodes, and connection methods of the network to improve the expression ability and generalization ability of the model. 2) Training strategy optimization: Adopt effective training strategies, such as batch normalization, learning rate scheduling and other technologies, to optimize the training process of the model, accelerate model convergence and improve generalization ability. 3) For batch normalization, the model is optimized by setting dynamic calculation normalization parameters. After optimization, it can better adapt to the dynamic changes of data characteristics while ensuring the stability of model training, thereby improving the generalization ability and effect of the payment risk identification model.
[0066] This embodiment aims to improve the adaptability of the payment risk identification model to different payment scenarios and payment risks by optimizing the deep learning model, especially the innovation of network structure, training strategy, activation function, etc. By enhancing the generalization ability of the model, it can better adapt to new payment environments and new payment risks, thereby improving the security of the payment system and user experience. The purpose of this embodiment is to provide a more generalized and adaptable payment risk identification model for the wallet payment field, and to provide more reliable payment security for payment platforms and financial institutions.
[0067] In this embodiment, a payment risk identification device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the terms "module" and "device" can implement a combination of software and / or hardware for a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0068] According to an embodiment of the present invention, there is also provided an apparatus embodiment for implementing the above payment risk identification method. Figure 3 is a schematic diagram of the structure of a payment risk identification device according to an embodiment of the present invention. Figure 3 As shown, the payment risk identification device includes: a data acquisition module 300, a risk identification module 302, wherein:
[0069] A data acquisition module 300 is used to acquire target payment data;
[0070] The risk identification module 302 is connected to the data acquisition module 300, and is used to obtain the payment risk identification result of the target payment data based on the target payment data by adopting the payment risk identification model; wherein the payment risk identification model is obtained by training the initial model based on the payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data and the risk identification results corresponding to the multiple groups of payment data.
[0071] In an embodiment of the present invention, a data acquisition module 300 is set up to acquire target payment data; a risk identification module 302 is connected to the data acquisition module 300, and is used to obtain a payment risk identification result of the target payment data based on the target payment data by adopting a payment risk identification model; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data, respectively, so as to achieve the purpose of training and constructing a model according to the data features of the training data (i.e., multiple groups of payment data), and accurately identifying payment risks based on the trained payment risk identification model, thereby achieving the technical effect of improving the accuracy of payment risk identification, and further solving the technical problems of low payment risk identification accuracy and poor model applicability existing in the related technology.
[0072] It should be noted that the above modules can be implemented by software or hardware. For example, for the latter, it can be implemented in the following ways: the above modules can be located in the same processor; or the above modules can be located in different processors in any combination.
[0073] It should be noted that the data acquisition module 300 and the risk identification module 302 correspond to steps S102 to S104 in the embodiment, and the examples and application scenarios implemented by the modules and the corresponding steps are the same, but are not limited to the contents disclosed in the embodiment. It should be noted that the modules as part of the device can be run in a computer terminal.
[0074] It should be noted that the optional or preferred implementation of this embodiment can refer to the relevant description in the embodiment, which will not be repeated here.
[0075] The above-mentioned payment risk identification device may also include a processor and a memory. The above-mentioned data acquisition module 300, risk identification module 302, etc. are all stored in the memory as program modules, and the processor executes the above-mentioned program modules stored in the memory to realize corresponding functions.
[0076] The processor includes a kernel, which retrieves the corresponding program module from the memory. The kernel may be one or more. The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. The memory includes at least one memory chip.
[0077] According to an embodiment of the present application, an embodiment of a non-volatile storage medium is also provided. Optionally, in this embodiment, the non-volatile storage medium includes a stored program, wherein when the program is executed, the device where the non-volatile storage medium is located is controlled to execute any of the payment risk identification methods.
[0078] Optionally, in this embodiment, the non-volatile storage medium may be located in any computer terminal in a computer terminal group in a computer network, or in any mobile terminal in a mobile terminal group, and the non-volatile storage medium includes a stored program.
[0079] Optionally, when the program is running, the device where the non-volatile storage medium is located is controlled to perform the following functions: obtaining target payment data; based on the target payment data, using a payment risk identification model to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
[0080] According to an embodiment of the present application, an embodiment of a processor is also provided. Optionally, in this embodiment, the processor is used to run a program, wherein the program executes any one of the payment risk identification methods when it is run.
[0081] According to an embodiment of the present application, an embodiment of a computer program product is also provided, which, when executed on a data processing device, is suitable for executing a program that initializes any one of the payment risk identification method steps described above.
[0082] Optionally, the above-mentioned computer program product, when executed on a data processing device, is suitable for executing a program initialized with the following method steps: obtaining target payment data; based on the target payment data, using a payment risk identification model to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on the payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data, and risk identification results corresponding to the multiple groups of payment data.
[0083] An embodiment of the present invention provides an electronic device, which includes a processor, a memory, and a program stored in the memory and executable on the processor. When the processor executes the program, the following steps are implemented: obtaining target payment data; based on the target payment data, using a payment risk identification model to obtain a payment risk identification result of the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
[0084] The above sequence of the embodiments of the present invention is for description only and does not represent the superiority or inferiority of the embodiments.
[0085] In the above embodiments of the present invention, the description of each embodiment has its own emphasis. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0086] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. Among them, the device embodiments described above are only schematic. For example, the division of the above modules can be a logical function division. There may be other division methods in actual implementation, such as multiple modules 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 through some interfaces, modules or indirect coupling or communication connection of modules, which can be electrical or other forms.
[0087] The modules described above as separate components may or may not be physically separated, and the components shown as modules may or may not be physical modules, that is, they may be located in one place or distributed on multiple modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the present embodiment.
[0088] In addition, each functional module in each embodiment of the present invention may be integrated into one processing module, or each module may exist physically separately, or two or more modules may be integrated into one module. The above integrated modules may be implemented in the form of hardware or in the form of software functional modules.
[0089] If the above-mentioned integrated module is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable non-volatile storage medium. Based on this understanding, the technical solution of the present invention 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. The computer software product is stored in a non-volatile storage medium, including a number of instructions to enable a computer device (which can be a personal computer, server or network device, etc.) to perform all or part of the steps of the various embodiments of the present invention. The aforementioned non-volatile storage medium includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.
[0090] The above are only preferred embodiments of the present invention. It should be pointed out that, for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A payment risk identification method, characterized in that: include: Get target payment data; Based on the target payment data, a payment risk identification model is used to obtain a payment risk identification result of the target payment data; Among them, the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
2. The method according to claim 1, characterized in that In the case where the payment risk identification model includes a convolutional neural network, a recurrent neural network, and multiple hidden layers, based on the target payment data, the payment risk identification model is adopted to obtain a payment risk identification result of the target payment data, including: Using the convolutional neural network to extract spatial features in the target payment data; Using the recurrent neural network to extract time series features in the target payment data; The spatial features and the time series features are processed using the multiple hidden layers to obtain the payment risk identification result.
3. The method according to claim 2, characterized in that In the case where the payment risk identification model further includes an attention layer, a batch normalization layer, and an output layer, the multiple hidden layers are used to process the spatial features and the time series features to obtain the payment risk identification result, including: Using the multiple hidden layers to perform feature extraction processing on the spatial features and the time series features to obtain multiple feature representations, wherein the multiple feature representations correspond one-to-one to the multiple hidden layers; Using the attention layer to perform attention weighting on the multiple feature representations to obtain weighted feature representations; The batch normalization layer is used to process the weighted feature representation to obtain a normalized feature representation; based on the normalized feature representation, the output layer is used to obtain the payment risk identification result.
4. The method according to claim 1, characterized in that: Before obtaining the payment risk identification result of the target payment data by using the payment risk identification model based on the target payment data, the method further includes: Performing feature analysis on the multiple groups of payment data to obtain data features of the multiple groups of payment data; Determine the task type of the risk identification results corresponding to the multiple groups of payment data, wherein the task type is any one of the following: a binary classification task, a multi-classification task, and a regression task; Determining network layer parameters based on the data characteristics and the task type; The initial model is constructed based on the convolutional neural network, the recurrent neural network and the network layer parameters.
5. The method according to claim 4, characterized in that The performing feature analysis on the multiple sets of payment data to obtain data features of the multiple sets of payment data includes: Determining characteristic dimensions of the multiple groups of payment data; Performing density analysis on the multiple groups of payment data to obtain feature density; The multiple groups of payment data are separated by sparsity to obtain a sparsity index, wherein the data feature includes the feature dimension, the feature density and the sparsity index.
6. The method according to claim 4, characterized in that The determining of network layer parameters based on the data characteristics and the task type includes: Based on the data features, determining input layer parameters, wherein the input layer parameters at least include the initial number of nodes in the input layer; Determine hidden layer parameters based on the data features and the task type, wherein the hidden layer parameters include at least the number of initial nodes and activation functions corresponding to the multiple hidden layers respectively; Based on the task type, output layer parameters are determined, wherein the output layer parameters at least include the initial number of nodes in the output layer, and the network layer parameters include the input layer parameters, the hidden layer parameters, and the output layer parameters.
7. The method according to any one of claims 1 to 6, characterized in that Before obtaining the payment risk identification result of the target payment data by using the payment risk identification model based on the target payment data, the method further includes: For each training stage of training the initial model based on the payment data set, obtaining a training indicator corresponding to each training stage, wherein the training indicator includes at least one of the following: a loss function value, a training set accuracy rate, and a validation set accuracy rate obtained in the corresponding training stage, each training stage includes a training stage based on a training set and a validation stage based on a validation set, and the payment data set includes the training set and the validation set; Based on the training index, a plurality of hidden layers included in the initial model are pruned so that the number of nodes included in the plurality of hidden layers is updated during the training of the initial model.
8. The method according to any one of claims 1 to 6, characterized in that: When the initial model includes a convolutional neural network, a recurrent neural network, a plurality of hidden layers, an attention layer, and a batch normalization layer in sequence, before obtaining a payment risk identification result of the target payment data by using a payment risk identification model based on the target payment data, the method further includes: In the process of training the initial model, obtaining a feature representation of the output of the attention layer; Based on the feature representation output by the attention layer, a normalization parameter of the batch normalization layer is updated.
9. A payment risk identification device, characterized in that: include: A data acquisition module, used to acquire target payment data; A risk identification module is used to obtain a payment risk identification result of the target payment data by adopting a payment risk identification model based on the target payment data; wherein the payment risk identification model is obtained by training an initial model based on a payment data set, wherein the initial model is constructed based on the data features of the payment data set, and the payment data set includes multiple groups of payment data and risk identification results corresponding to the multiple groups of payment data.
10. An electronic device, characterized in that: It includes one or more processors and a memory, wherein the memory is used to store one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors implement the payment risk identification method described in any one of claims 1 to 8.