Bank customer risk dynamic assessment and early warning method based on multi-source data fusion
By integrating multi-source data and using a deep learning model based on the Transformer architecture, the problems of data lag and insufficient adaptability in traditional bank customer risk assessment methods have been solved, enabling real-time and accurate risk warning and assessment, and improving the bank's risk management capabilities.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JIANGSU SUNING BANK CO LTD
- Filing Date
- 2026-01-27
- Publication Date
- 2026-06-02
Smart Images

Figure CN122134451A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of bank customer risk assessment technology, specifically to a method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion. Background Technology
[0002] In a complex and ever-changing financial environment, bank customer risk exhibits diverse and dynamic characteristics. Traditional risk assessment methods primarily rely on limited static data within banks, such as basic customer information and historical transaction records, which are insufficient to comprehensively and in real-time reflect customer risk status. With the rapid development of financial markets, customer behavior has become more complex, and market volatility has intensified. Traditional models relying solely on historical data and simple rules are unable to capture risk changes in a timely manner, resulting in significant early warning lags. For example, when the economic situation suddenly changes or customer behavior patterns shift drastically in a short period, traditional models cannot quickly adjust their assessment results. Traditional post-loan risk warnings lag by an average of two quarters in a dynamic environment, and static scoring card models have a misjudgment rate exceeding 20% during economic downturns. This lag in early warnings leads banks to take action only after risks have occurred, resulting in potential losses.
[0003] Furthermore, existing models based on data mining and machine learning, while attempting to incorporate new data and technologies, still suffer from numerous limitations. Regarding data sources, most models integrate only limited external data, failing to fully utilize rich external information such as social media and e-commerce platforms, resulting in incomplete customer risk profiles. In terms of model adaptability, facing rapid changes in the market environment and customer behavior, models lack adaptive adjustment mechanisms, making it difficult to maintain long-term stable accuracy. Moreover, these models are insufficient in handling the dynamic relationships of complex risk factors and cannot effectively cope with the intertwined effects of multi-dimensional risks. Therefore, this paper designs a method that uses Transformer + Reinforcement Learning + Multi-Source Data Fusion to achieve dynamic and personalized risk warnings, addressing the problems of lagging model updates, insufficient data dimensions, and poor interpretability in existing models. Summary of the Invention
[0004] The purpose of this invention is to address the shortcomings of existing technologies by providing a method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion.
[0005] To achieve the above objectives, this invention provides a method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion, comprising: Collect the latest multi-source data and preprocess the multi-source data; The preprocessed multi-source data is input into the trained dynamic risk assessment model to obtain scores for multiple indicators. The indicator score is calculated based on the scores of multiple indicators and a pre-constructed risk warning indicator system. The indicator score is then compared with the warning threshold. When the warning threshold is exceeded, a warning signal is issued.
[0006] Furthermore, the multi-source data includes internal data and external data. The internal data includes customer transaction data and basic information, while the external data includes macroeconomic data, social media data, and e-commerce platform data. The internal data is extracted periodically using ETL tools through the bank's internal business system interface; the macroeconomic data is obtained through the API interface of the data provider; and the social media and e-commerce platform data are collected using web crawling technology after authorization from the customer.
[0007] Furthermore, the dynamic risk assessment model adopts a deep learning model based on the Transformer architecture and combined with attention mechanism and time series analysis technology as its architecture; it is trained using reinforcement learning algorithm combined with adaptive learning rate adjustment algorithm, and transfer learning technology is introduced.
[0008] Furthermore, the Transformer architecture includes a 6-layer encoder and a 6-layer decoder. Each layer of the encoder consists of a multi-head self-attention mechanism and a feedforward neural network. Each layer of the decoder adds a multi-head cross-attention mechanism to the encoder structure to enhance the ability to capture the interaction relationship between customer risk factors.
[0009] Furthermore, the output of the encoder is represented as: ; ; in, For the encoder output, For splicing operations, For the output of the i-th attention head, i=1,2,…,s, To output the projection matrix, The output of a single attention head. To query the vector matrix, The key vector matrix, It is a value vector matrix. For activation function, The transpose symbol for a matrix. Key vector matrix The dimension; Furthermore, the output of the decoder is represented as: ; in, This is the output of the decoder. This is the query vector matrix generated based on the historical risk assessment result sequence Y. The key vector matrix generated from the encoder output. This is the value vector matrix generated based on the encoder's output.
[0010] Furthermore, in the training of the dynamic risk assessment model, the reinforcement learning algorithm uses the risk assessment error as a reward signal. When the assessment error is less than a preset threshold, a positive reward is given, and otherwise a negative reward is given. The policy network of the dynamic risk assessment model is updated through the Q-learning algorithm, so that the dynamic risk assessment model is continuously optimized in the direction of reducing the assessment error.
[0011] Furthermore, the policy update formula for the Q-learning algorithm is as follows: ; in, Let the action value function be... For the assignment and update operation, γ is the discount factor, s is the current parameter state of the dynamic risk assessment model, a is the parameter adjustment action to adjust the attention weights, and s′ is the parameter state of the updated dynamic risk assessment model. This refers to the immediate feedback obtained when the state transitions from s to s′. Let Q be the maximum Q value among all possible actions a' under the new state s'.
[0012] Furthermore, the risk warning indicator system includes indicators such as credit risk, market risk, liquidity risk, and operational risk. Warning thresholds are set using historical data statistical analysis, industry standard comparison, and expert experience judgment. The indicator weights are determined by combining the analytic hierarchy process (AHP) and the entropy weight method.
[0013] Beneficial effects: 1. By integrating multi-source and multi-dimensional data, this invention can comprehensively and deeply depict the risk characteristics of bank customers, avoiding the one-sidedness of assessment caused by single data. Combining an advanced Transformer architecture deep learning model and various optimization algorithms, the model can accurately capture the dynamic changes of customer risk factors, significantly improving the accuracy of risk assessment.
[0014] 2. The real-time risk warning mechanism of this invention can quickly issue an alert the moment a customer's risk indicators reach the warning threshold, giving banks sufficient time to take risk response measures and effectively reduce risk losses. The establishment of a feedback mechanism enables the model to continuously learn and optimize, further improving the accuracy and timeliness of the warning.
[0015] 3. The reinforcement learning, online learning, and transfer learning techniques employed in this invention enable the model to quickly adapt to changes in the market environment and customer behavior, maintaining good performance without requiring extensive retraining. The model's architecture is highly scalable, allowing for easy integration of new risk factors and data sources.
[0016] 4. This invention automates and intelligently manages risk assessment and early warning, significantly reducing manual intervention and improving the efficiency and accuracy of bank risk management. Simultaneously, it provides scientific and reliable data support for bank decision-making, helping banks optimize resource allocation, rationally formulate credit policies, enhance overall risk management capabilities, and strengthen their competitiveness in complex financial markets. Attached Figure Description
[0017] Figure 1 This is a flowchart illustrating the method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion, according to an embodiment of the present invention. Detailed Implementation
[0018] The present invention will be further illustrated below with reference to the accompanying drawings and specific embodiments. These embodiments are implemented based on the technical solutions of the present invention, and it should be understood that these embodiments are only used to illustrate the present invention and are not intended to limit the scope of the present invention.
[0019] like Figure 1 As shown, this embodiment of the invention provides a method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion, including: The system collects the latest multi-source data and preprocesses it. This multi-source data includes internal and external data. Internal data includes customer transaction data and basic information, while external data includes macroeconomic data, social media data, and e-commerce platform data. Internal data is extracted periodically using ETL tools through the bank's internal business system interface. Macroeconomic data is obtained through data provider API interfaces, such as monthly updates of the latest macroeconomic indicators through data interfaces with official institutions like the National Bureau of Statistics. Social media and e-commerce platform data are collected using web crawling technology after customer authorization. Transaction data includes account statements, loan repayment details, and credit card spending details. Customer basic information includes age, occupation, income, and asset-liability structure. Macroeconomic data includes GDP growth rate, interest rate fluctuations, and inflation rate. Social media data includes social relationships, interests, and consumer discussions. E-commerce platform data includes purchase categories, frequency, and amount. A distributed storage architecture can be adopted, using the Hadoop Distributed File System (HDFS) to store massive amounts of collected data. Parallel data processing is achieved through the Spark distributed computing framework to improve data processing efficiency.
[0020] The above preprocessing method is as follows: Data cleaning techniques are used to remove noise, missing values, and outliers from the collected data. For missing values, a multiple imputation method is used, combining the time series characteristics and correlations of the data to make reasonable inferences and imputations; for outliers, density-based spatial clustering algorithms (DBSCAN) and other techniques are used for identification and correction.
[0021] The preprocessed multi-source data is input into the trained dynamic risk assessment model to obtain scores for multiple indicators. Specifically, the dynamic risk assessment model of this application adopts a deep learning model based on the Transformer architecture combined with attention mechanism and time series analysis technology as its architecture; reinforcement learning algorithms combined with adaptive learning rate adjustment algorithms (such as Adagrad, Adadelta, etc.) are used for training to accelerate model convergence and improve training efficiency. Transfer learning technology is also introduced, using model parameters trained in other financial fields (such as securities market risk assessment, insurance customer risk analysis, etc.) as initial parameters, and fine-tuning them with specific data for bank customer risk assessment, reducing training time and data requirements, and improving the generalization ability of the dynamic risk assessment model in bank customer risk assessment scenarios. A dynamic model update mechanism can also be established to monitor the market environment, customer behavior and new data in real time, and update model parameters using online learning technology. When major market events (such as significant interest rate adjustments, major industry policy changes, etc.) occur or customer behavior shows significant abnormalities, the model update process is automatically triggered. Using online learning technology, the latest data is integrated into the model training in real time, and model parameters are adjusted in a timely manner to ensure that the model can always accurately reflect the current risk status of customers. The Transformer architecture effectively processes long-sequence data, capturing the complex dependencies of customer risk factors over time. Its attention mechanism enables the dynamic risk assessment model to automatically focus on the most important features and time segments for risk assessment, improving accuracy. For example, when analyzing the time series of customer transaction records, the dynamic risk assessment model can focus on the timing of abnormal transactions and their related characteristics before and after them, accurately identifying risks. The Transformer architecture in the dynamic risk assessment model comprises a 6-layer encoder and a 6-layer decoder. Each encoder layer consists of a multi-head self-attention mechanism and a feedforward neural network, while each decoder layer adds a multi-head cross-attention mechanism to the encoder structure to enhance the ability to capture the interactions between customer risk factors.
[0022] The core computational logic of the Transformer architecture and reinforcement learning is as follows: Self-attention weight calculation: Let the customer risk feature sequence at time t be... The query vector matrix is obtained through linear transformation. Key vector matrix Value vector matrix The output of a single attention head is The 8-head attention outputs are concatenated and linearly transformed to obtain the encoder's final output. .in, For splicing operations, For the output of the i-th attention head, i=1,2,…,s, To output the projection matrix, For activation function, The transpose symbol for a matrix. Key vector matrix Dimensions.
[0023] Cross-attention weight calculation: The decoder takes the historical risk assessment result sequence Y (length = 12 months) as input, and the cross-attention layer generates a query vector matrix using Y. The encoder output is used to generate a key vector matrix. Sum value vector matrix The calculation logic is as follows: Furthermore, the K value corresponding to macroeconomic environmental characteristics (such as PMI and interest rates) is multiplied by a weighting coefficient of 1.2 to enhance the capture of environmental impacts.
[0024] Before training the dynamic risk assessment model, multi-source data is collected. After preprocessing the collected multi-source data, data fusion technology is used to convert data from different formats and sources into a format suitable for model input, based on unique customer identifiers (such as ID card numbers, unified social credit codes, etc.), and the relationships between the data are constructed. Knowledge graph technology is used to integrate internal customer information, external macroeconomic information, industry information, and social e-commerce behavior information to form a comprehensive and three-dimensional customer risk knowledge graph, intuitively displaying the relationship between customers and various risk factors. During the training of the dynamic risk assessment model, stochastic gradient descent algorithm and its variants are used to adjust parameters. The training data is divided into training and test sets proportionally, the data is standardized, and hyperparameters are optimized through cross-validation.
[0025] In the training of a dynamic risk assessment model, reinforcement learning algorithms use risk assessment error as a reward signal. When the assessment error is less than a preset threshold, a positive reward is given; otherwise, a negative reward is given. The policy network of the dynamic risk assessment model is updated through the Q-learning algorithm, so that the dynamic risk assessment model is continuously optimized in the direction of reducing assessment error.
[0026] The policy update formula for the Q-learning algorithm is:
[0027] in, Let the action value function be... For the assignment and update operation, γ is the discount factor, s is the current parameter state of the dynamic risk assessment model, a is the parameter adjustment action to adjust the attention weights, and s′ is the parameter state of the updated dynamic risk assessment model. This refers to the immediate feedback obtained when the state transitions from s to s′. Let Q be the maximum Q value among all possible actions a' under the new state s'.
[0028] The risk warning indicator system calculates scores based on multiple indicators and a pre-built risk warning indicator system. These scores are then compared to warning thresholds, and a warning signal is issued when a threshold is exceeded. The system includes indicators for credit risk, market risk, liquidity risk, and operational risk. Warning thresholds are set using historical data statistical analysis, industry standard comparisons, and expert judgment. Indicator weights are determined using a combination of the analytic hierarchy process (AHP) and entropy weighting. Specifically, credit risk indicators include the number of overdue payments, changes in credit score, debt-to-income ratio, and probability of debt default; market risk indicators include portfolio market value fluctuations, interest rate sensitivity gap, and exchange rate risk exposure; liquidity risk indicators include cash flow status, current asset ratio, and capital turnover cycle; and operational risk indicators include internal transaction error rate, number of violations, and system failure frequency.
[0029] The core of setting the weights for the indicator system using the Analytic Hierarchy Process (AHP) is to transform subjective judgments into quantifiable weights through a process of "problem decomposition → judgment matrix construction → weight calculation → consistency verification." For example, regarding the overdue payment frequency indicator in credit risk, by analyzing the distribution of historical defaulting customer overdue data and combining it with the industry's average overdue tolerance, a warning threshold of three consecutive overdue payments is set. Using AHP and the entropy weight method, bank risk management experts are invited to score the importance of each indicator, and combined with data entropy values, the weight of the credit risk indicator in the overall risk assessment is determined to be 0.4. The specific steps are as follows: ① Establish a hierarchical structure model Decompose the decision problem into the goal layer, the criterion layer (indicator layer), and the alternative layer (if any).
[0030] Objective level: The core objective of decision-making (such as "customer risk assessment").
[0031] Criteria layer: Key indicators that affect the objectives (such as "transaction data", "economic data", "behavioral data").
[0032] Solution layer: The specific objects to be evaluated (such as different customers). If only the indicator weights need to be determined, this can be omitted.
[0033] ② Construct the judgment matrix For indicators at the same level, relative importance is determined by pairwise comparison, and represented by a numerical scale of 1-9 (1 represents equal importance, 9 represents extreme importance, and the middle value is transitional), forming a judgment matrix A=(aij)n×n (n is the number of indicators).
[0034] Scale rules: a_{ij}=1: Indicators i and j are equally important; a_{ij}=3: i is slightly more important than j; a_{ij}=5: i is significantly more important than j; a_{ij}=7: i is significantly more important than j; a_{ij}=9: i is extremely more important than j; If the importance of i to j is a_{ij}, then a_{ji} = 1 / a_{ij} (e.g., if a_{ij} = 3, then a_{ji} = 1 / 3).
[0035] Example: Construct a judgment matrix for "transaction data (1), economic data (2), and behavioral data (3)", as detailed in Table 1: Table 1: Judgment Matrix
[0036] ③ Calculate the weight of the indicators The relative weights of each indicator are calculated using a judgment matrix, often employing the eigenvalue method (or simplified calculations such as the sum method or root method). Normalization process: Sum the elements of each column of the judgment matrix, and then divide each element by the sum of its column to obtain the normalized matrix.
[0037] Calculate the weights: Average the elements of each row of the normalized matrix to obtain the initial weights w_i for each indicator.
[0038] For example, taking the above 3×3 matrix as an example, the calculated weights may be: transaction data 0.16, economic data 0.54, and behavioral data 0.30 (the specific weights need to be calculated according to the formula).
[0039] ④ Consistency check The judgment matrix may contain logical contradictions (such as "A is more important than B, B is more important than C, but C is more important than A"), and its rationality needs to be verified through consistency checks. Calculate the consistency index (CI): CI = (λmax - n) / (n - 1), where λmax is the largest eigenvalue of the judgment matrix (which can be estimated by matrix multiplication), and n is the number of indicators.
[0040] Find the average random consistency index RI: Fixed values (e.g., RI=0.58 when n=3; RI=0.90 when n=4, which can be obtained from a table).
[0041] Calculate the consistency ratio (CR): CR = CI / RI. If CR < 0.1, the consistency of the judgment matrix is acceptable; otherwise, the judgment matrix needs to be adjusted.
[0042] ⑤ Determine the final weights If the consistency check passes, the weights calculated in step ③ are the final results; if they fail, the judgment matrix needs to be readjusted (the scale of the pairwise comparisons needs to be modified), and steps ③-④ need to be repeated until the requirements are met.
[0043] This application also provides system architecture and compliance design: The system architecture comprises six layers, from bottom to top: the data acquisition layer (deploying ETL tools, API interfaces, and web crawlers), the data processing layer (a 4-node Spark cluster, each node with 16 cores and 64GB of memory), the risk knowledge graph layer (Neo4j graph database, 5 partitions, 2 replicas), the model layer (Transformer models quantized to INT8 precision), the real-time alert layer (Kafka + Flink, parallelism = 8), and the application layer (risk alert console and decision support system). The risk knowledge graph layer deploys a multi-dimensional relational query engine, supporting combined queries of "entity-relationship-attribute" with a response time ≤100ms.
[0044] Real-time performance metrics must meet the following requirements: data acquisition latency ≤ 50ms (Kafka message queue partitions = 10), risk assessment P95 latency ≤ 200ms (Flink stream processing batch size = 64), single-node QPS ≥ 500, and online model update time ≤ 10s (only updating the top 2 Transformer parameters, parameter count < 50,000).
[0045] Compliance Design: Sensitive data is transmitted using the national cryptographic algorithm SM4 (key length = 128 bits) and distributed using SM2 asymmetric encryption (public key is public, private key is stored in hardware encryption device); sensitive customer information is desensitized using "SHA-256 hash with salt + partial mask", salt value length = 16 bits, and stored independently in offline encryption device; full-process operation logs record the operator, time, content, and device IP according to GB / T20984-2022 standard, and the logs are retained for ≥6 years, supporting the export of audit reports as required by regulatory authorities; before external data collection, the authorization process is recorded through "customer electronic authorization letter + AntChain evidence storage", and the evidence storage hash value is uploaded to the blockchain information service filing platform of the State Internet Information Office.
[0046] Once a risk indicator exceeds a threshold, an early warning signal is immediately issued to the bank's risk management department and relevant personnel through multiple channels, including SMS, email, and pop-up windows in the bank's internal risk management system. Simultaneously, different colors and prompts are used to differentiate risk levels (e.g., high, medium, low) for easy identification and handling by staff. A feedback mechanism can also be established, whereby the effectiveness of measures taken by bank staff based on the warning information is fed back to the dynamic risk assessment model. The dynamic risk assessment model further optimizes its parameters based on the feedback results, improving the accuracy of risk assessment and early warning. For example, if the bank takes measures such as increasing collateral or prematurely recalling a loan for a high-risk customer, the dynamic risk assessment model will track subsequent changes in the customer's risk, analyze the effectiveness of the measures, and use the relevant information to improve the model. Causal inference techniques are used to analyze the causal relationship between risk response measures and changes in customer risk, providing a stronger basis for model optimization. Example 1:
[0047] 1. Case Background Taking corporate client A of a commercial bank as an example, this client is engaged in the manufacturing industry and has been established for 5 years. It has loan business with the bank. Recently, its industry has been greatly affected by macroeconomic fluctuations. The bank needs to conduct dynamic risk assessment and early warning for this client in order to prevent potential risks.
[0048] 2. Data Collection and Integration Implementation 2.1 Internal Data Collection: Through the bank's internal business system interface, using the KettleETL tool, extract customer A's transaction data from the previous day at midnight every day, including loan repayment details (monthly repayment amount for the past 6 months, whether it is overdue, etc.), account balance changes, and records of financial transactions with other companies; at the same time, extract customer A's basic information, such as registered capital, legal representative information, and financial statement data (balance sheet, profit and loss statement, and cash flow statement data for the past 3 years), and store this data in the bank's data warehouse.
[0049] 2.2 External Data Acquisition: A cooperation agreement was signed with Wind Information to obtain macroeconomic data monthly through its API interface, such as the manufacturing PMI index, changes in loan interest rates, and fluctuations in raw material prices; with authorization from Client A, the Scrapy web crawling framework was used to collect industry dynamic data (such as changes in market demand, competitor information, etc.) of the manufacturing industry in which Client A operates from industry information platforms, and to obtain Client A's business registration change information, administrative penalty records, etc. from the enterprise credit information disclosure system.
[0050] 2.3 Data Cleaning and Integration: The collected data was cleaned using the OpenRefine tool. Three transaction records for Client A were found to have missing counterparty information. Time-series regression was used to fill in the missing information, combined with the counterparty patterns of previous and subsequent transactions. The 3σ principle was used to identify one unusual large expenditure record, which was verified to be a normal equipment purchase by Client A. This data was retained but marked as a special transaction. Based on Client A's Unified Social Credit Code, internal financial data was linked and integrated with external industry dynamics data and credit information. Knowledge graph technology was used to construct a risk knowledge graph for Client A, visually demonstrating its relationship with the macroeconomy, industry conditions, and its own financial situation.
[0051] 3. Training and optimization implementation of dynamic risk assessment model 3.1 Data Preparation: Data from the past three years for Customer A was extracted from the integrated data set as a sample. Simultaneously, data from 200 other companies in the same industry during the same period were selected as supplementary training data, divided into training and testing sets in a 7:3 ratio. Customer financial indicators (debt-to-equity ratio, net profit margin, etc.), transaction characteristics (timeliness of repayment, frequency of cash flow, etc.), and external environmental factors (industry prosperity, interest rate changes, etc.) were used as input features. Whether the company experienced overdue payments or a business crisis was used as a label. The data was standardized so that all feature data fell within the [0,1] range.
[0052] 3.2 Model Construction and Initialization: A risk assessment model based on the Transformer architecture was built, comprising a 6-layer encoder and a 6-layer decoder. Each encoder layer consists of an 8-head self-attention mechanism and a feedforward neural network. Using transfer learning techniques, the parameters of the Transformer model trained in securities market industry risk assessment were used as initial parameters. These parameters were then fine-tuned to suit the characteristics of risk assessment for manufacturing enterprises, adjusting the weight distribution of the self-attention mechanism to enhance its focus on enterprise financial indicators and industry dynamics.
[0053] 3.3 Model Training: The model was trained using the training set data, employing the Adam optimizer with an initial learning rate of 0.001, 500 iterations, and a batch size of 32. During training, when the model's prediction of customer A's risk level deviated significantly from the actual situation (e.g., a slight delinquency in a certain period), the reinforcement learning algorithm treated this deviation as a negative reward, adjusting the weights of features related to that period's repayment record in the model; when the prediction was accurate, a positive reward was given. Hyperparameters were optimized through cross-validation, ultimately determining that 400 iterations resulted in optimal model performance.
[0054] 3.4 Model Evaluation and Optimization: The model was evaluated using test set data, achieving an accuracy of 88%, a recall of 85%, an F1 score of 86.5%, and an AUC of 0.89, outperforming traditional models. To further improve the accuracy of evaluating medium-sized manufacturing enterprises like Customer A, a two-layer Transformer encoder was added, and the learning rate decay strategy was adjusted, increasing the model's AUC to 0.91.
[0055] 4. Establishment and Implementation of Risk Early Warning Indicator System 4.1 Indicator Selection and Weight Determination: For Client A, the following indicators were selected: credit risk indicators (number of overdue payments, debt-to-equity ratio, current ratio), market risk indicators (tolerance for raw material price fluctuations, changes in product market share), and liquidity risk indicators (net cash flow, accounts receivable turnover). Five bank risk management experts were invited to score each indicator using the Analytic Hierarchy Process (AHP). Objective weights were calculated using the entropy weight method, ultimately determining the weights for credit risk indicators to be 0.45, market risk indicators to be 0.3, and liquidity risk indicators to be 0.25.
[0056] 4.2 Warning Threshold Setting: Based on the analysis of customer A's historical data and industry standards, the following warning thresholds are set: overdue payment times ≥ 2 times is the credit risk warning threshold; asset-liability ratio ≥ 60% is the warning threshold; raw material price fluctuation tolerance rate ≤ -10% is the market risk warning threshold; and net cash flow being negative for 3 consecutive months is the liquidity risk warning threshold.
[0057] 4.3 Risk Warning Implementation: Real-time data collection for Customer A and calculation of various indicator values. In the 6th month, it was found that the number of overdue payments reached 2, the asset-liability ratio was 62%, triggering a credit risk warning; the raw material price fluctuation tolerance rate was -8%, which did not reach the market risk threshold; and the net cash flow was negative for 2 consecutive months, approaching the liquidity risk threshold. The overall assessment was medium to high risk, and an orange warning signal was issued.
[0058] 5. Implementation of real-time risk warning and feedback mechanism 5.1 Real-time Monitoring and Early Warning: The system acquires customer A's transaction data in real time through a Kafka message queue and Flink stream processing framework. When an orange alert is triggered, the system immediately sends an SMS alert to the bank's account manager: "Customer A (Unified Social Credit Code XXX) has two overdue payments, a debt-to-asset ratio of 62%, and a medium-to-high credit risk. Please follow up promptly." Simultaneously, an alert pop-up appears in the bank's internal system, displaying details of various indicators and a risk trend chart.
[0059] 5.2 Feedback and Model Optimization: The account manager conducted a risk assessment of Client A and found that its cash flow was tight due to rising raw material prices. The manager adjusted the repayment plan. One month later, Client A's repayment situation improved, and its debt-to-equity ratio decreased to 58%. This result was fed back to the model, which used causal inference techniques to analyze the causal relationship between the adjusted repayment plan and the reduced risk. The model then adjusted relevant parameters for assessing the repayment ability of similar companies facing cash flow difficulties, improving the accuracy of subsequent early warnings by 3%.
[0060] Through practical application to customer A, the model was able to accurately assess their risk status and issue an early warning two months in advance, helping the bank to take timely measures and avoid potential losses, thus verifying the practicality and effectiveness of the invention. Example 2:
[0061] 1. Basic Experimental Information Experimental subjects: A full customer sample of a state-owned bank from 2021 to 2023, totaling 1.2 million customers (900,000 individual customers and 300,000 corporate customers), covering 8 industries including manufacturing, service, and retail, with customer size ranging from micro-enterprises (annual revenue < 1 million) to large enterprises (annual revenue > 1 billion).
[0062] Experimental period: Model training period of 6 months (January-June 2023), and effect verification period of 6 months (July-December 2023). Comparison methods: traditional scoring card (logistic regression), XGBoost model, and the method of this invention; Core assessment dimensions: risk differentiation capability, early warning accuracy, efficiency indicators, and stability indicators.
[0063] 2. For detailed experimental data on the core effects, please refer to Table 2: Table 2: Comparison of Core Effects Evaluation indicators unit Method of the present invention Traditional scoring card (logistic regression) XGBoost model The improvement of this invention compared to XGBoost Improvement of this invention vs. traditional scorecard Risk differentiation ability - - - - - - AUC value (test set) - 0.92 0.76 0.84 +9.5% +21.1% KS value (test set) - 0.69 0.47 0.58 +19.0% +46.8% Early warning accuracy - - - - - - F1 value - 0.90 0.69 0.80 +12.5% +30.4% Accuracy % 86.2 72.5 80.1 +7.6% +18.9% Recall rate % 94.3 65.8 80.5 +19.6% +43.3% efficiency indicators - - - - - - Training time for millions of customers Hour 4.2 2.1 3.6 -38.9% (More efficient) +100.0% (Sacrificing accuracy for efficiency is reasonable) Delay in single-customer assessment (P95) millisecond 185 520 290 -36.2% (more real-time) -64.4% Single-node QPS times / second 520 380 450 +15.6% +36.8% Online model update time Second 8.5 - (No online updates) 25.3 -66.4% - Stability Indicators - - - - - - 6-month AUC volatility % 2.3 8.5 5.1 -54.9% (More stable) -72.9% Maximum monthly AUC decline % 3.1 9.8 6.5 -52.3% -68.4% 3. For detailed experimental data on the effects of multi-industry segmentation, please refer to Table 3: Table 3: Results of Multi-Industry Segmentation Industry type Number of customers (in ten thousand) AUC value of this invention Recall rate of this invention (%) XGBoost Recall Rate (%) Improvement percentage after industry adaptation adjustment (%) Typical early warning case effects manufacturing 8.2 0.93 95.1 81.2 +17.1 Identifying a machinery company's liquidity risk two months in advance prevented a loan loss of 5 million yuan. service industry 6.5 0.91 93.6 79.8 +17.3 A restaurant business triggers an alert when its customer traffic drops by 30%, and there are no breaches of contract after 3 months. Retail 5.8 0.90 92.8 78.5 +18.2 E-commerce customer orders plummeted by 40%, prompting a warning 1.5 months in advance. micro and small enterprises 7.3 0.88 90.2 75.3 +19.8 A small food processing enterprise saw a 25% decrease in tax invoicings, prompting an early warning three months in advance. large enterprises 2.2 0.94 96.5 83.6 +15.4 A related party of a certain group company defaulted on its payment, and the company issued a warning 2.5 months in advance. Experimental data description Data source: The experimental data are all from the bank's real business system. Internal data such as customer transaction records and credit records account for 70%, while external data such as third-party tax data and e-commerce platform data account for 30%. All data has been anonymized (in accordance with GB / T35273-2020 "Information Security Technology - Personal Information Security Specification").
[0064] Comparison of method parameters: Traditional scoring cards use 5 core features (income, debt, number of overdue payments, credit inquiries, and assets); the XGBoost model is set with tree depth = 8, learning rate = 0.01, and number of iterations = 1000, using the same feature set (32 features) as the method of this invention to ensure fairness.
[0065] Industry adaptation adjustment basis: After adding supply chain node data to the manufacturing industry, the feature dimensions expanded from 32 to 45; after replacing the macro indicator with the service industry PMI, the dynamic correction response speed of the threshold improved by 30%; after adjusting the reward function parameters for micro and small enterprises, the recall rate in data sparse scenarios improved by 8.2%.
[0066] Significance verification: The AUC difference between the present invention and the XGBoost model (p=0.002<0.05) and the traditional scorecard (p=0.001<0.05) was verified by t-test, proving that the improvement in performance is statistically significant.
[0067] The above description is merely a preferred embodiment of the present invention. It should be noted that for those skilled in the art, other parts not specifically described are existing technology or common knowledge. Several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion, characterized in that, include: Collect the latest multi-source data and preprocess the multi-source data; The preprocessed multi-source data is input into the trained dynamic risk assessment model to obtain scores for multiple indicators. The indicator score is calculated based on the scores of multiple indicators and a pre-constructed risk warning indicator system. The indicator score is then compared with the warning threshold. When the warning threshold is exceeded, a warning signal is issued.
2. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 1, characterized in that, The multi-source data includes internal data and external data. The internal data includes customer transaction data and basic information, while the external data includes macroeconomic data, social media data, and e-commerce platform data. The internal data is extracted periodically using ETL tools through the bank's internal business system interface; the macroeconomic data is obtained through the API interface of the data provider; and the social media and e-commerce platform data are collected using web crawling technology after authorization from the customer.
3. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 1, characterized in that, The dynamic risk assessment model adopts a deep learning model based on the Transformer architecture and combined with attention mechanism and time series analysis technology as its architecture; it is trained using reinforcement learning algorithm combined with adaptive learning rate adjustment algorithm, and transfer learning technology is introduced.
4. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 3, characterized in that, The Transformer architecture includes a 6-layer encoder and a 6-layer decoder. Each layer of the encoder consists of a multi-head self-attention mechanism and a feedforward neural network. Each layer of the decoder adds a multi-head cross-attention mechanism to the encoder structure to enhance the ability to capture the interaction between customer risk factors.
5. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 4, characterized in that, The output of the encoder is represented as follows: ; ; in, For the encoder output, For splicing operations, For the output of the i-th attention head, i=1,2,…,s, To output the projection matrix, The output of a single attention head. To query the vector matrix, The key vector matrix, It is a value vector matrix. For activation function, The transpose symbol for a matrix. Key vector matrix Dimensions.
6. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 5, characterized in that, The output of the decoder is represented as follows: ; in, This is the output of the decoder. This is the query vector matrix generated based on the historical risk assessment result sequence Y. The key vector matrix generated from the encoder output. This is the value vector matrix generated based on the encoder's output.
7. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 3, characterized in that, In the training of the dynamic risk assessment model, the reinforcement learning algorithm uses the risk assessment error as a reward signal. When the assessment error is less than a preset threshold, a positive reward is given, and otherwise a negative reward is given. The policy network of the dynamic risk assessment model is updated through the Q-learning algorithm, so that the dynamic risk assessment model is continuously optimized in the direction of reducing the assessment error.
8. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 7, characterized in that, The policy update formula for the Q-learning algorithm is as follows: ; in, Let the action value function be... For the assignment and update operation, γ is the discount factor, s is the current parameter state of the dynamic risk assessment model, a is the parameter adjustment action to adjust the attention weights, and s′ is the parameter state of the updated dynamic risk assessment model. This refers to the immediate feedback obtained when the state transitions from s to s′. Let Q be the maximum Q value among all possible actions a' under the new state s'.
9. The method for dynamic assessment and early warning of bank customer risk based on multi-source data fusion according to claim 1, characterized in that, The risk warning indicator system includes indicators such as credit risk, market risk, liquidity risk, and operational risk. Warning thresholds are set using historical data statistical analysis, industry standard comparison, and expert experience judgment. The indicator weights are determined by combining the analytic hierarchy process (AHP) and the entropy weight method.