Credit card account cancellation prediction model and construction method thereof
By building a credit card account closure prediction model and using the TBPU learning method and LightGBM model, we solved the problem of accurate prediction of account closure behavior in traditional credit card customer management, achieved accurate prediction of credit card customers' account closure tendencies, and improved customer retention rate.
Patent Information
- Application Number
- CN202510761961.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-09
- Publication Date
- 2025-09-16
AI Technical Summary
Traditional credit card customer management methods make it difficult to accurately predict customer account cancellation behavior, resulting in low credit card customer retention rates.
A credit card account closure prediction model is adopted to accurately predict the tendency of credit card customers to closure their accounts through steps such as data preparation, data preprocessing, feature engineering, data screening, model training and prediction evaluation, combined with the TBPU learning method, iterative pseudo-label generation strategy and LightGBM model.
It improves the accuracy and real-time performance of credit card account closure predictions, enhances the effectiveness of customer relationship management, and provides innovative solutions for the financial technology field.
Smart Images

Figure CN120655413A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of prediction models, and in particular to a credit card account cancellation prediction model and a construction method thereof. Background Art
[0002] Traditional customer management relies heavily on empirical judgment and simple statistical analysis, making it difficult to accurately and timely predict credit card customer churn. Therefore, customer churn prediction based on data mining and machine learning technologies is crucial for improving credit card customer retention.
[0003] Therefore, it is necessary to provide a credit card account cancellation prediction model and a construction method thereof to improve the accuracy of credit card account cancellation prediction. Summary of the Invention
[0004] The purpose of the present invention is to provide a credit card account cancellation prediction model and a construction method thereof, so as to improve the accuracy of credit card account cancellation prediction.
[0005] In order to solve the problems existing in the prior art, the present invention provides a credit card account cancellation prediction model, comprising:
[0006] a data preparation module configured to acquire data;
[0007] A data preprocessing module is configured to process outliers and missing values in the data;
[0008] Feature engineering module, including feature screening submodule, feature binning module and feature encoding submodule;
[0009] The data screening module is configured to use the K-NearestNeighbors model to perform similarity analysis on existing customers who have not yet closed their accounts, and define a screening range so that existing customers who have not yet closed their accounts and whose similarity falls within the screening range participate in model training;
[0010] The model training module is configured to use the TBPU learning method, iterative pseudo-label generation strategy, and LightGBM model for training to obtain a credit card account cancellation prediction model, where TBPU stands for Transductive Bagging PU. An out-of-bag prediction strategy is also introduced to generate the final prediction results.
[0011] The prediction evaluation module is configured to evaluate the final prediction results in the following way:
[0012]
[0013] Among them, TP represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; TN represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; FN represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; FP represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; Recall is the recall rate, the F1 score is the harmonic mean of precision and recall, FRP is the false positive rate, and TPR is the true positive rate.
[0014] Optionally, in the credit card account cancellation prediction model, the acquired data includes the customer's basic information, account information, transaction information, and installment information.
[0015] Optionally, in the credit card account cancellation prediction model,
[0016] Basic information includes gender, age, marital status, and education level;
[0017] Account information includes the highest card level, number of cards held, credit limit, maximum account age, activation status, mobile banking binding, WeChat Quick Payment, financial management purchases, customer ID, and six-month activity level;
[0018] Transaction information includes transaction number, transaction amount, number of online transactions, number of offline transactions, consumption level, average monthly consumption transaction amount, average monthly consumption transaction amount, and activity participation;
[0019] Installment information includes the number of installments, installment amount, bill installment term preference, the number of monthly consumer transaction installments, and the monthly consumer transaction installment amount.
[0020] Optionally, in the credit card account cancellation prediction model, in the model training module,
[0021] The TBPU learning method is used to prepare data, defining historical account cancellation customers as positive samples and existing account cancellation customers as unlabeled samples.
[0022] The Bootstrap resampling method is used to randomly sample the positive samples to generate the subset Ps, and a certain proportion of data is randomly selected from the unlabeled samples as the subset Us;
[0023] Use the sampled Ps and Us to train the LightGBM model;
[0024] In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; the LightGBM model of the current training stage is used to predict the out-of-bag prediction samples and generate the prediction probability of the out-of-bag samples;
[0025] Repeat the training and out-of-bag prediction steps several times, and generate the final prediction result by weighted averaging or voting mechanism for all the prediction probabilities obtained in multiple rounds of training.
[0026] The present invention also provides a method for constructing a credit card account cancellation prediction model, comprising the following steps:
[0027] S1: Get data;
[0028] S2: Process outliers and missing values in the data;
[0029] S3: Filter features, bin and encode them;
[0030] S4: Based on the processed features, the K-NearestNeighbors model is used to perform similarity analysis on existing customers who have not yet closed their accounts. A screening range is defined so that existing customers whose similarity falls within the screening range participate in model training.
[0031] S5: Develop a credit card account cancellation prediction model using the TBPU learning method, iterative pseudo-label generation strategy, and LightGBM model for training. TBPU stands for Transductive Bagging PU. An out-of-bag prediction strategy is introduced to generate the final prediction results.
[0032] S6: Evaluate the generated prediction results as follows:
[0033]
[0034] Among them, TP represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; TN represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; FN represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; FP represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; Recall is the recall rate, the F1 score is the harmonic mean of precision and recall, FRP is the false positive rate, and TPR is the true positive rate.
[0035] Optionally, in the method for constructing the credit card account cancellation prediction model, the method of screening features is: screening and reducing the dimension of initial features.
[0036] Optionally, in the method for constructing the credit card account cancellation prediction model, the step of screening existing customers who have not cancelled their accounts to participate in model training is as follows:
[0037] Extract key features from the data of existing customers who have not closed their accounts and construct a feature space. The key features include the customer's transaction behavior, account activity, and credit card usage characteristics.
[0038] The extracted key features were normalized before being input into the K-NearestNeighbors model;
[0039] The Euclidean distance is used to measure the similarity between the customer and the historical account cancellation customers. The calculation formula is as follows:
[0040]
[0041] Among them, d(x,y) represents the similarity between the customer and the historical account-closing customers, x i A vector representing the key features of any category of the customer, y i A vector representing the features of historically closed customers, where n represents the total number of key feature categories.
[0042] Calculate the similarity between the customer and K historical account-closing customers respectively, and take the average of the K similarity values as the comprehensive similarity of the customer;
[0043] Define the screening range so that existing customers whose similarity falls within the screening range can participate in model training.
[0044] Optionally, in the method for constructing the credit card account cancellation prediction model, the training and prediction methods are as follows:
[0045] The TBPU learning method is used to prepare data, defining historical account cancellation customers as positive samples and existing account cancellation customers as unlabeled samples.
[0046] The Bootstrap resampling method is used to randomly sample the positive samples to generate the subset Ps, and a certain proportion of data is randomly selected from the unlabeled samples as the subset Us;
[0047] Use the sampled Ps and Us to train the LightGBM model;
[0048] In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; the LightGBM model of the current training stage is used to predict the out-of-bag prediction samples and generate the prediction probability of the out-of-bag samples;
[0049] Repeat the training and out-of-bag prediction steps several times, and generate the final prediction result by weighted averaging or voting mechanism for all the prediction probabilities obtained in multiple rounds of training.
[0050] Compared with the prior art, the present invention has the following advantages:
[0051] This invention achieves accurate predictions of customers with high account closure intentions through in-depth mining and analysis of customer behavior data. This credit card account closure prediction model, centered on positive sample-unlabeled sample learning, combines dynamic pseudo-label generation and multi-level feature selection to improve prediction accuracy and real-time performance. This provides an innovative solution for customer relationship management in the fintech sector. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 This is a module diagram of the credit card account cancellation prediction model provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0053] The following is a more detailed description of the specific embodiments of the present invention with reference to schematic diagrams. The advantages and features of the present invention will become more apparent from the following description. It should be noted that the drawings are greatly simplified and not to exact scale, and are only used for the purpose of conveniently and clearly illustrating the embodiments of the present invention.
[0054] Hereinafter, if the method described herein includes a series of steps, the order in which the steps are presented herein is not necessarily the only order in which the steps may be performed, and some of the steps described may be omitted and / or some other steps not described herein may be added to the method.
[0055] Traditional customer management relies heavily on empirical judgment and simple statistical analysis, making it difficult to accurately and timely predict credit card customer churn. Therefore, customer churn prediction based on data mining and machine learning technologies is crucial for improving credit card customer retention.
[0056] The present invention aims to solve the problems of low credit card customer churn prediction accuracy and untimely response in traditional solutions, and proposes a credit card account closure prediction model and a construction method thereof.
[0057] In order to solve the problems existing in the prior art, the present invention provides a credit card account cancellation prediction model, such as Figure 1 As shown, including:
[0058] (1) a data preparation module configured to acquire data;
[0059] In one embodiment, the acquired data includes the customer's basic information, account information, transaction information, and installment information, etc. Among them, basic information includes gender, age, marital status, and education level, etc.; account information includes the highest card level, number of cards held, credit limit, maximum account age, whether it is activated, whether it has been bound to mobile banking, whether WeChat quick payment has been opened, financial purchases, customer identification, and half-year activity, etc.; transaction information includes the number of transactions (in the past 6 months), transaction amount (in the past 6 months), number of online transactions (in the past 3 months), number of offline transactions (in the past 3 months), consumption level, average monthly consumption transaction amount (in the past 6 months), average monthly consumption transaction amount (in the past 12 months), and activity participation, etc.; installment information includes the number of installments, installment amount (in the past 1 year), bill installment term preference, number of monthly consumption transaction installments (in the past 6 months), and monthly consumption transaction installment amount (in the past 6 months), etc.
[0060] The selection of these feature dimensions comprehensively covers core information such as the customer's basic situation, account status, transaction behavior, and installment preferences. It can characterize the customer's credit card usage and behavior patterns from multiple angles and provide rich input information for the model.
[0061] (2) a data preprocessing module configured to process outliers and missing values in the data;
[0062] Specifically, the data preprocessing module is mainly responsible for the preliminary description and cleaning of the data. The data quality of each bank varies greatly, so it is necessary to further clean the data features. Cleaning mainly includes the processing of data outliers and missing values. First, the missing ratio of each field in the statistics is counted. For fields with a large missing ratio, the missing ratio is filled according to business experience or the average value. For fields with a small missing ratio, this part of the data is directly removed. Secondly, outliers have a relatively large impact on the model. The present invention mainly adopts the box plot method to identify outliers and remove extreme abnormal data.
[0063] (3) Feature engineering module, including feature screening submodule, feature binning module and feature encoding submodule; to ensure the quality and adaptability of model input data.
[0064] The feature screening submodule mainly screens and reduces the dimension of the initial features through a variety of methods. The present invention is mainly based on the correlation filtering method to calculate the correlation coefficient between features. During the screening process, the focus is on retaining key features with high predictive power for customer account closure tendencies, while removing redundant or noise features. The feature binning module is mainly aimed at continuous features. By establishing a decision tree model for continuous features and target classification variables, the decision tree will traverse all possible splitting points and select the points that minimize data impurity as splitting points. The splitting nodes of the decision tree are used as the binning boundaries of the target features, so that the binning results can better reflect the relationship between features and customer account closure behavior. In addition, feature binning can reduce the impact of outliers on the model and reduce the risk of model overfitting. The feature encoding submodule uses one-hot encoding to discretize discrete variables to retain key information of the data.
[0065] (4) a data screening module configured to use the K-NearestNeighbors model to perform similarity analysis on existing customers who have not yet closed their accounts, and define a screening range so that existing customers who have not yet closed their accounts and whose similarity falls within the screening range participate in model training;
[0066] The data screening module is an important preprocessing step that aims to screen out samples with characteristics that are significantly different from those of historically closed customers from existing customers, so as to improve the training quality of the model and reduce noise interference.
[0067] Specifically, the steps for screening existing customers who have not yet closed their accounts for model training are as follows:
[0068] S41: Extract key features from the data of existing customers who have not cancelled their accounts and construct a feature space. Key features include the customer's transaction behavior (such as consumption frequency and amount changes), account activity (such as the number of active days in the past six months), and credit card usage (such as installment preference and bill payment status).
[0069] S42: The extracted key features are normalized before being input into the K-NearestNeighbors model to ensure that features of different dimensions have the same weight for similarity calculation;
[0070] S43: Similarity can be calculated based on the following methods: Euclidean distance, cosine similarity, and Manhattan distance. The smaller the distance, the more similar the characteristics of the unclosed customer and the closed customer are, and vice versa. The present invention uses Euclidean distance to measure similarity, and its calculation formula is as follows:
[0071]
[0072] Among them, d(x,y) represents the similarity between the customer and the historical account-closing customers, x iA vector representing the key features of any category of the customer, y i A vector representing the features of historically closed customers, where n represents the total number of key feature categories.
[0073] S44: Calculate similarity values between the customer and K historical account-closing customers respectively, and take the average of the K similarity values as the comprehensive similarity of the customer;
[0074] S45: Define the screening range so that existing customers whose similarity falls within the screening range can participate in model training.
[0075] Furthermore, the screening range is defined as follows: Based on the calculation results, the similarity scores of existing customers who have not yet closed their accounts are stratified according to a threshold value. Samples with lower similarity scores are retained as "outlier samples," i.e., customers who have not yet closed their accounts and are significantly different from closed customers. These samples are used for subsequent model training. In the present invention, the top 60% of samples with lower similarity scores are retained for model training.
[0076] Preferably, in practical applications, the screening strategy can be dynamically optimized based on the performance of the credit card account closure prediction model. For example, based on the initial screening, feedback from model training results can be used to further adjust feature weights or similarity screening ranges to improve screening accuracy. Furthermore, the feature space can be expanded to a multi-stage screening process, initially using global features for coarse screening, followed by fine-tuning using key features, thereby gradually improving data purity.
[0077] This data screening module efficiently removes samples from existing customers whose characteristics overly resemble those of closed customers, effectively reducing the noise content in the training data and enhancing the model's ability to identify key features. This not only improves the accuracy and robustness of the credit card account closure prediction model but also provides a clearer customer stratification foundation for the formulation of subsequent intervention strategies.
[0078] (5) Model training module, configured to use the TBPU learning method, iterative pseudo-label generation strategy and LightGBM model for training to obtain a credit card account cancellation prediction model, where TBPU stands for Transductive Bagging PU; and introduce an out-of-bag prediction strategy to generate the final prediction results;
[0079] Furthermore, in the model training module,
[0080] S51: Data is prepared using the TBPU learning method, with historical account closures defined as positive samples and existing accounts that have not been closed defined as unlabeled samples. Based on feature similarity, unlabeled samples may contain both positive and negative samples. Positive and unlabeled samples are normalized to ensure that all features fall within a consistent numerical range. This method fully utilizes unlabeled samples, improving the model's ability to predict customer account closure behavior.
[0081] S52: Using the Bootstrap resampling method, randomly sample from the positive samples to generate a subset Ps, and randomly extract a certain proportion of data from the unlabeled samples as a subset Us; Ps represents the positive samples participating in the training, and Us is a potential negative sample, but its label has not yet been determined.
[0082] S53: Use the sampled Ps and Us to train the LightGBM model; during the training process, it is initially assumed that Us is a negative sample, and the classification performance of the model is optimized based on this assumption.
[0083] S54: In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; the LightGBM model of the current training stage is used to predict the out-of-bag prediction samples and generate the out-of-bag sample prediction probability;
[0084] S55: Repeat the training and out-of-bag prediction steps several times. All prediction probabilities obtained from multiple rounds of training are weighted averaged or voted to generate the final prediction result. The evaluation of the prediction results determines whether to continue training. This weighted average or voting mechanism effectively reduces the effects of overfitting and noise that may be introduced by a single training run, improving prediction stability.
[0085] By deeply combining the TBPU method with the LightGBM model, the present invention significantly improves the accuracy of the credit card account cancellation prediction model in predicting customer account cancellation tendencies while fully mining the unlabeled sample information.
[0086] (6) Prediction evaluation module, configured to evaluate the final prediction results in the following manner:
[0087]
[0088] TP represents the number of customers whose accounts were actually cancelled but the model predicted them to be so; TN represents the number of customers whose accounts were not cancelled but the model predicted them to be so; FN represents the number of customers whose accounts were actually cancelled but the model predicted them to be so; FP represents the number of customers whose accounts were not cancelled but the model predicted them to be so. Recall is the recall rate, also known as the true positive rate, which indicates the model's ability to identify positive classes. It is the proportion of all actual positive classes that the model correctly classifies as positive. The F1 score is the harmonic mean of precision and recall; the larger the value, the better the overall model performance. FPR is the false positive rate, which indicates the proportion of all actual negative samples that were incorrectly classified as positive. TPR is the true positive rate, which indicates the proportion of all actual negative samples that were correctly classified as negative.
[0089] Furthermore, the present invention uses the SHAP package to analyze the feature importance of the credit card account cancellation prediction model to further improve the interpretability and credibility of the model.
[0090] The present invention also provides a method for constructing a credit card account cancellation prediction model, comprising the following steps:
[0091] S1: Get data;
[0092] In one embodiment, the acquired data includes the customer's basic information, account information, transaction information, and installment information, etc. Among them, basic information includes gender, age, marital status, and education level, etc.; account information includes the highest card level, number of cards held, credit limit, maximum account age, whether it is activated, whether it has been bound to mobile banking, whether WeChat quick payment has been opened, financial purchases, customer identification, and half-year activity, etc.; transaction information includes the number of transactions (in the past 6 months), transaction amount (in the past 6 months), number of online transactions (in the past 3 months), number of offline transactions (in the past 3 months), consumption level, average monthly consumption transaction amount (in the past 6 months), average monthly consumption transaction amount (in the past 12 months), and activity participation, etc.; installment information includes the number of installments, installment amount (in the past 1 year), bill installment term preference, number of monthly consumption transaction installments (in the past 6 months), and monthly consumption transaction installment amount (in the past 6 months), etc.
[0093] The selection of these feature dimensions comprehensively covers core information such as the customer's basic situation, account status, transaction behavior, and installment preferences. It can characterize the customer's credit card usage and behavior patterns from multiple angles and provide rich input information for the model.
[0094] S2: Process outliers and missing values in the data;
[0095] Specifically, the main work is to make a preliminary description and clean the data. The data quality of each bank varies, so it is necessary to further clean the data features. Cleaning mainly includes the processing of data outliers and missing values. First, the missing ratio of each field in the statistics is calculated. For fields with a large missing ratio, fill in the data based on business experience or the average value. For fields with a small missing ratio, consider directly eliminating this part of the data. Secondly, outliers also have a relatively large impact on the model. This invention mainly adopts the box plot method to identify outliers and eliminate extreme abnormal data.
[0096] S3: Screen features and perform binning and encoding on them to ensure the quality and adaptability of the model input data.
[0097] Feature screening mainly uses a variety of methods to screen and reduce the dimension of the initial features. The present invention is mainly based on the correlation filtering method to calculate the correlation coefficient between features. During the screening process, the key features with high predictive power for customer account closure tendency are retained, while redundant or noise features are removed. Feature binning is mainly aimed at continuous features. By establishing a decision tree model for continuous features and target classification variables, the decision tree will traverse all possible splitting points and select the points that minimize data impurity as splitting points. The splitting nodes of the decision tree are used as the binning boundaries of the target features, so that the binning results can better reflect the relationship between features and customer account closure behavior. In addition, feature binning can reduce the impact of outliers on the model and reduce the risk of model overfitting. Feature encoding uses one-hot encoding to discretize discrete variables and retain key information of the data.
[0098] S4: Based on the processed features, the K-NearestNeighbors model is used to perform similarity analysis on existing customers who have not yet closed their accounts. A screening range is defined so that existing customers whose similarity falls within the screening range participate in model training.
[0099] Specifically, the steps for screening existing customers who have not yet closed their accounts for model training are as follows:
[0100] S41: Extract key features from the data of existing customers who have not cancelled their accounts and construct a feature space. Key features include the customer's transaction behavior (such as consumption frequency and amount changes), account activity (such as the number of active days in the past six months), and credit card usage (such as installment preference and bill payment status).
[0101] S42: The extracted key features are normalized before being input into the K-NearestNeighbors model to ensure that features of different dimensions have the same weight for similarity calculation;
[0102] S43: Similarity can be calculated based on the following methods: Euclidean distance, cosine similarity, and Manhattan distance. The smaller the distance, the more similar the characteristics of the unclosed customer and the closed customer are, and vice versa. The present invention uses Euclidean distance to measure similarity, and its calculation formula is as follows:
[0103]
[0104] Among them, d(x,y) represents the similarity between the customer and the historical account-closing customers, x i A vector representing the key features of any category of the customer, y i A vector representing the features of historically closed customers, where n represents the total number of key feature categories.
[0105] S44: Calculate similarity values between the customer and K historical account-closing customers respectively, and take the average of the K similarity values as the comprehensive similarity of the customer;
[0106] S45: Define the screening range so that existing customers whose similarity falls within the screening range can participate in model training.
[0107] Furthermore, the screening range is defined as follows: Based on the calculation results, the similarity scores of existing customers who have not yet closed their accounts are stratified according to a threshold value. Samples with lower similarity scores are retained as "outlier samples," i.e., customers who have not yet closed their accounts and are significantly different from closed customers. These samples are used for subsequent model training. In the present invention, the top 60% of samples with lower similarity scores are retained for model training.
[0108] Preferably, in practical applications, the screening strategy can be dynamically optimized based on the performance of the credit card account closure prediction model. For example, based on the initial screening, feedback from model training results can be used to further adjust feature weights or similarity screening ranges to improve screening accuracy. Furthermore, the feature space can be expanded to a multi-stage screening process, initially using global features for coarse screening, followed by fine-tuning using key features, thereby gradually improving data purity.
[0109] S5: Develop a credit card account cancellation prediction model using the TBPU learning method, iterative pseudo-label generation strategy, and LightGBM model for training. TBPU stands for Transductive Bagging PU. An out-of-bag prediction strategy is introduced to generate the final prediction results.
[0110] Specifically, S51: Data is prepared using the TBPU learning method, with historical account closures defined as positive samples and existing accounts that have not been closed defined as unlabeled samples. Based on feature similarity, unlabeled samples may contain both positive and negative samples. Positive and unlabeled samples are normalized to ensure that all features fall within a consistent numerical range. This invention fully utilizes unlabeled samples to enhance the model's ability to predict customer account closure behavior.
[0111] S52: Using the Bootstrap resampling method, randomly sample from the positive samples to generate a subset Ps, and randomly extract a certain proportion of data from the unlabeled samples as a subset Us; Ps represents the positive samples participating in the training, and Us is a potential negative sample, but its label has not yet been determined.
[0112] S53: Use the sampled Ps and Us to train the LightGBM model; during the training process, it is initially assumed that Us is a negative sample, and the classification performance of the model is optimized based on this assumption.
[0113] S54: In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; the LightGBM model of the current training stage is used to predict the out-of-bag prediction samples and generate the out-of-bag sample prediction probability;
[0114] S55: Repeat the training and out-of-bag prediction steps several times. All prediction probabilities obtained from multiple rounds of training are weighted averaged or voted to generate the final prediction result. The evaluation of the prediction results determines whether to continue training. This weighted average or voting mechanism effectively reduces the effects of overfitting and noise that may be introduced by a single training run, improving prediction stability.
[0115] S6: Evaluate the generated prediction results as follows:
[0116]
[0117] TP represents the number of customers whose accounts were actually cancelled but the model predicted them to be so; TN represents the number of customers whose accounts were not cancelled but the model predicted them to be so; FN represents the number of customers whose accounts were actually cancelled but the model predicted them to be so; FP represents the number of customers whose accounts were not cancelled but the model predicted them to be so. Recall is the recall rate, also known as the true positive rate, which indicates the model's ability to identify positive classes. It is the proportion of all actual positive classes that the model correctly classifies as positive. The F1 score is the harmonic mean of precision and recall; the larger the value, the better the overall model performance. FPR is the false positive rate, which indicates the proportion of all actual negative samples that were incorrectly classified as positive. TPR is the true positive rate, which indicates the proportion of all actual negative samples that were correctly classified as negative.
[0118] S7: Feature Importance Analysis
[0119] This paper uses the SHAP package to analyze the feature importance of the credit card account closure prediction model to further enhance the model's interpretability and credibility. SHAP values quantify the impact of each feature on the likelihood of account closure and visualize the positive and negative contributions of each feature to the prediction results. This helps banks more intuitively understand the key factors driving customer behavior and provides a scientific basis for developing personalized intervention strategies.
[0120] In summary, compared with the prior art, the present invention has the following advantages:
[0121] This invention achieves accurate predictions of customers with high account closure intentions through in-depth mining and analysis of customer behavior data. This credit card account closure prediction model, centered on positive sample-unlabeled sample learning, combines dynamic pseudo-label generation and multi-level feature selection to improve prediction accuracy and real-time performance. This provides an innovative solution for customer relationship management in the fintech sector.
[0122] The above description is merely a preferred embodiment of the present invention and does not limit the present invention in any way. Any person skilled in the art who, without departing from the scope of the present invention, makes any equivalent substitution, modification, or other changes to the technical solution and technical content disclosed in the present invention shall be deemed to be within the scope of the present invention and still fall within the scope of protection of the present invention.
Claims
1. A credit card account cancellation prediction model, characterized by: include: a data preparation module configured to acquire data; A data preprocessing module is configured to process outliers and missing values in the data; Feature Engineering Module, Includes feature screening submodule, feature binning module and feature encoding submodule; The data screening module is configured to use the K-NearestNeighbors model to perform similarity analysis on existing customers who have not yet closed their accounts, and define a screening range so that existing customers who have not yet closed their accounts and whose similarity falls within the screening range participate in model training; The model training module is configured to use the TBPU learning method, iterative pseudo-label generation strategy, and LightGBM model for training to obtain a credit card account cancellation prediction model, where TBPU stands for Transductive Bagging PU. An out-of-bag prediction strategy is also introduced to generate the final prediction results. The prediction evaluation module is configured to evaluate the final prediction results in the following way: Among them, TP represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; TN represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; FN represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; FP represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; Recall is the recall rate, the F1 score is the harmonic mean of precision and recall, FRP is the false positive rate, and TPR is the true positive rate.
2. The credit card account cancellation prediction model according to claim 1, wherein: The data obtained includes the customer's basic information, account information, transaction information and installment information.
3. The credit card account cancellation prediction model according to claim 2, wherein: Basic information includes gender, age, marital status, and education level; Account information includes the highest card level, number of cards held, credit limit, maximum account age, activation status, mobile banking binding, WeChat Quick Payment, financial management purchases, customer ID, and six-month activity level; Transaction information includes transaction number, transaction amount, number of online transactions, number of offline transactions, consumption level, average monthly consumption transaction amount, average monthly consumption transaction amount, and activity participation; Installment information includes the number of installments, installment amount, bill installment term preference, the number of monthly consumer transaction installments, and the monthly consumer transaction installment amount.
4. The credit card account cancellation prediction model according to claim 1, wherein: In the model training module, The TBPU learning method is used to prepare data, defining historical account cancellation customers as positive samples and existing account cancellation customers as unlabeled samples. The Bootstrap resampling method is used to randomly sample the positive samples to generate the subset Ps, and a certain proportion of data is randomly selected from the unlabeled samples as the subset Us; Use the sampled Ps and Us to train the LightGBM model; In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; Use the LightGBM model in the current training stage to predict the out-of-bag prediction samples and generate the out-of-bag sample prediction probability; Repeat the training and out-of-bag prediction steps several times, and generate the final prediction result by weighted averaging or voting mechanism for all the prediction probabilities obtained in multiple rounds of training.
5. A method for constructing a credit card account cancellation prediction model, characterized in that: The following steps are involved: S1: Get data; S2: Process outliers and missing values in the data; S3: Filter features, bin and encode them; S4: Based on the processed features, the K-NearestNeighbors model is used to perform similarity analysis on existing customers who have not yet closed their accounts. A screening range is defined so that existing customers whose similarity falls within the screening range participate in model training. S5: Develop a credit card account cancellation prediction model using the TBPU learning method, iterative pseudo-label generation strategy, and LightGBM model for training. TBPU stands for Transductive Bagging PU. An out-of-bag prediction strategy is introduced to generate the final prediction results. S6: Evaluate the generated prediction results as follows: Among them, TP represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; TN represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; FN represents the number of customers who were actually cancelled but were predicted by the model to be cancelled; FP represents the number of customers who were actually not cancelled but were predicted by the model to be cancelled; Recall is the recall rate, the F1 score is the harmonic mean of precision and recall, FRP is the false positive rate, and TPR is the true positive rate.
6. The method for constructing a credit card account cancellation prediction model according to claim 5, wherein: The method of filtering features is to filter and reduce the dimension of the initial features.
7. The method for constructing a credit card account cancellation prediction model according to claim 5, wherein: The steps for screening existing customers who have not yet closed their accounts for model training are as follows: Extract key features from the data of existing customers who have not closed their accounts and construct a feature space. The key features include the customer's transaction behavior, account activity, and credit card usage characteristics. The extracted key features were normalized before being input into the K-NearestNeighbors model; The Euclidean distance is used to measure the similarity between the customer and the historical account cancellation customers. The calculation formula is as follows: Among them, d(x,y) represents the similarity between the customer and the historical account-closing customers, x i A vector representing the key features of any category of the customer, y i A vector representing the features of historically closed customers, where n represents the total number of key feature categories. Calculate the similarity between the customer and K historical account-closing customers respectively, and take the average of the K similarity values as the comprehensive similarity of the customer; Define the screening range so that existing customers whose similarity falls within the screening range can participate in model training.
8. The method for constructing a credit card account cancellation prediction model according to claim 7, wherein: The training and prediction methods are as follows: The TBPU learning method is used to prepare data, defining historical account cancellation customers as positive samples and existing account cancellation customers as unlabeled samples. The Bootstrap resampling method is used to randomly sample the positive samples to generate the subset Ps, and a certain proportion of data is randomly selected from the unlabeled samples as the subset Us; Use the sampled Ps and Us to train the LightGBM model; In each round of training, samples that are not sampled into Ps and Us are used as out-of-bag prediction samples; Use the LightGBM model in the current training stage to predict the out-of-bag prediction samples and generate the out-of-bag sample prediction probability; Repeat the training and out-of-bag prediction steps several times, and generate the final prediction result by weighted averaging or voting mechanism for all the prediction probabilities obtained in multiple rounds of training.