Financial risk intelligent early warning method and system

By using multi-source time-series data fusion and feature weighting, the problem of insufficient accuracy in financial risk prediction in existing technologies is solved, achieving stable and accurate prediction of corporate financial risks, and applicable to scenarios such as corporate internal auditing and bank credit granting.

CN122222757APending Publication Date: 2026-06-16SHANDONG KAIWEN COLLEGE OF SCI & TECH
View PDF -1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-04-02
Publication Date
2026-06-16

AI Technical Summary

Technical Problem

Existing methods for predicting corporate financial risks are unable to simultaneously reflect the dynamic impact of macroeconomic fluctuations and industry cyclical changes, resulting in large fluctuations in risk assessment results and insufficient prediction accuracy. In particular, they are unable to distinguish between long-term trends and short-term cyclical fluctuations in cyclical industries.

Method used

A multi-source time-series data fusion method is adopted. The trend term and periodic term are decomposed by the Informer model. The enhanced long short-term memory network (E-LSTM) and periodic convolution extraction network (P-CNN) are combined to calculate the Nelson coefficient for feature weighting. Finally, a fully connected neural network is used to output the comprehensive financial risk evaluation score.

Benefits of technology

It improves the accuracy and stability of financial risk forecasting, can reflect cyclical industry changes and market fluctuation trends in a timely manner, and the output risk assessment results are quantifiable and comparable, making them suitable for scenarios such as corporate internal auditing, bank credit granting, and regulatory risk control.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122222757A_ABST
    Figure CN122222757A_ABST
Patent Text Reader

Abstract

The application provides a financial risk intelligent early warning method and system, belongs to the technical field of financial risk early warning based on a mathematical model, and through multi-source fusion of internal financial indexes of enterprises and external macro indexes of industries, a unified time sequence data input system is constructed, the interaction influence of enterprise operation conditions and external economic environment can be comprehensively reflected, and the limitation that traditional risk assessment only depends on static financial ratios is overcome; dynamic alignment is conducted on multi-source data by using a unified time window, the timeliness and consistency of model input are improved, the risk prediction result can more timely reflect periodic industry changes and market fluctuation trends; the enterprise risk level can be described in a continuous interval of 0 to 1, the sensitivity of the model to risk changes is reserved, and the risk early warning management of a unified standard can be realized in the scenes of internal audit of enterprises, bank credit and supervision and risk control, and the practicability and popularization value of the method are enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of financial risk early warning technology based on mathematical models, and specifically to a financial risk intelligent early warning method and system. Background Technology

[0002] Existing methods for predicting corporate financial risk are mostly based on single-dimensional financial indicators or static regression models, making it difficult to simultaneously reflect the dynamic impact of macroeconomic fluctuations and industry cyclical changes on a company's financial status. Due to differences in sampling frequency and time windows between internal financial indicators and external industry indicators, existing methods are prone to feature mismatch and information redundancy when integrating multi-source time-series data, resulting in significant fluctuations in risk assessment results and insufficient prediction accuracy. Especially in cyclical industries, corporate financial performance is often simultaneously affected by both long-term trends and short-term cyclical fluctuations; traditional models cannot distinguish and model these two factors, making it difficult to output stable risk assessment results. Summary of the Invention

[0003] The purpose of this invention is to provide a financial risk intelligent early warning method that can integrate multiple time-series indicators under a unified time window, distinguish and extract trend and cyclical features, and perform fusion weighting based on feature stability, so as to improve the accuracy and stability of financial risk prediction and solve at least one of the technical problems existing in the above-mentioned background technology.

[0004] To achieve the above objectives, the present invention adopts the following technical solution:

[0005] In a first aspect, the present invention provides a method for intelligent early warning of financial risks, comprising the following steps:

[0006] S1. Obtain multi-source time-series data of the target company. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the company belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. Align the internal financial indicators and external indicators according to a unified time window and perform standardization processing.

[0007] S2. Input the standardized data into the first Informer model, use a multi-head attention mechanism to decompose the input sequence into a trend term and a periodic term, perform sliding window averaging on the trend term to enhance stability, and perform frequency domain filtering on the periodic term to extract seasonal fluctuations.

[0008] S3. Input the trend term into the Enhanced Long Short-Term Memory (E-LSTM) network to extract long-term trend features, and input the periodic term into the Periodic Convolution Extraction Network (P-CNN) to capture short-term periodic features, and output the trend prediction vector and the periodic prediction vector.

[0009] S4. Calculate the Nelson coefficients corresponding to the trend prediction vector and the cycle prediction vector to characterize their fluctuation stability in the time dimension; input the Nelson coefficients as attention allocation factors into the feature fusion module to form attention weights, and perform weighted fusion of the trend prediction vector and the cycle prediction vector to obtain a comprehensive feature vector.

[0010] S5. Input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period of time. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

[0011] As a further limitation of the first aspect of the present invention, the external indicators also include the industry supply-demand ratio change rate and / or the industry cyclical index; the external indicators and the internal financial indicators maintain the same sampling frequency to form a unified input time window.

[0012] Secondly, this invention provides a financial risk intelligent early warning system, comprising:

[0013] The data acquisition and preprocessing module is used to acquire multi-source time-series data of the target enterprise. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the enterprise belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. The internal financial indicators and external indicators are aligned and standardized according to a unified time window.

[0014] The time series decomposition module is used to input the standardized data into the first Informer model, and to decompose the input sequence into a trend term and a periodic term using a multi-head attention mechanism. The trend term is processed by sliding window averaging to enhance stability, and the periodic term is processed by frequency domain filtering to extract seasonal fluctuations.

[0015] The feature extraction module is used to input the trend term into the enhanced long short-term memory network (E-LSTM) to extract long-term trend features, input the periodic term into the periodic convolutional extraction network (P-CNN) to capture short-term periodic features, and output trend prediction vector and periodic prediction vector.

[0016] The feature weighting module is used to calculate the Nelson coefficients corresponding to the trend prediction vector and the period prediction vector to characterize their fluctuation stability in the time dimension; the Nelson coefficients are used as attention allocation factors and input into the feature fusion module to form attention weights, and the trend prediction vector and the period prediction vector are weighted and fused to obtain a comprehensive feature vector.

[0017] The risk output module is used to input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

[0018] Thirdly, the present invention also provides a computer device, comprising:

[0019] processor;

[0020] Memory, which stores computer programs;

[0021] When the computer program is executed by the processor, it implements the deep learning-based financial risk early warning method as described in the first aspect.

[0022] The beneficial effects of this invention are as follows: By integrating internal financial indicators with external macroeconomic indicators, a unified time-series data input system is constructed, comprehensively reflecting the interaction between the company's operating conditions and the external economic environment, overcoming the limitations of traditional risk assessment that relies solely on static financial ratios. This method utilizes a unified time window to dynamically align multi-source data, improving the timeliness and consistency of model input. This allows risk prediction results to more promptly reflect cyclical industry changes and market fluctuations, significantly improving prediction accuracy and response speed. By inputting weighted feature vectors into a fully connected neural network to output a comprehensive financial risk score, and combining this with threshold partitioning to classify risk levels, the risk assessment results become quantifiable, comparable, and traceable. This structure can characterize the company's risk level within a continuous range of 0 to 1, preserving the model's sensitivity to risk changes while facilitating standardized risk warning management in scenarios such as internal auditing, bank lending, and regulatory risk control, enhancing the method's practicality and promotional value.

[0023] The advantages of additional aspects of the invention will be set forth more clearly in the following description or will be learned by practice of the invention. Attached Figure Description

[0024] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0025] Figure 1 This is a flowchart of the intelligent early warning method for financial risks according to an embodiment of the present invention.

[0026] Figure 2 This is a functional framework diagram of the intelligent early warning system for financial risks described in an embodiment of the present invention.

[0027] Figure 3 This is a functional framework diagram of the computer device according to an embodiment of the present invention. Detailed Implementation

[0028] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0029] To facilitate understanding of the present invention, the present invention will be further explained and described below with reference to the accompanying drawings and specific embodiments. However, the specific embodiments do not constitute a limitation on the embodiments of the present invention.

[0030] Those skilled in the art should understand that the accompanying drawings are merely schematic diagrams of embodiments, and the components in the drawings are not necessarily essential for implementing the present invention.

[0031] Please refer to Figure 1 This embodiment discloses a financial risk intelligent early warning method, aiming to intelligently assess and predict corporate financial conditions through a deep learning structure. The method takes multi-source time-series data as input, and through steps such as data fusion, feature weighting, neural network calculation, and comprehensive score output, forms a quantifiable risk early warning result, including the following steps:

[0032] S1. Obtain multi-source time-series data of the target company. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the company belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. Align the internal financial indicators and external indicators according to a unified time window and perform standardization processing.

[0033] S2. Input the standardized data into the first Informer model, use a multi-head attention mechanism to decompose the input sequence into a trend term and a periodic term, perform sliding window averaging on the trend term to enhance stability, and perform frequency domain filtering on the periodic term to extract seasonal fluctuations.

[0034] S3. Input the trend term into the Enhanced Long Short-Term Memory (E-LSTM) network to extract long-term trend features, and input the periodic term into the Periodic Convolution Extraction Network (P-CNN) to capture short-term periodic features, and output the trend prediction vector and the periodic prediction vector.

[0035] S4. Calculate the Nelson coefficients corresponding to the trend prediction vector and the cycle prediction vector to characterize their fluctuation stability in the time dimension; input the Nelson coefficients as attention allocation factors into the feature fusion module to form attention weights, and perform weighted fusion of the trend prediction vector and the cycle prediction vector to obtain a comprehensive feature vector.

[0036] S5. Input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period of time. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

[0037] According to one embodiment of the present invention, the "target enterprise" refers to the entity being analyzed that requires risk assessment. This can be a listed company, a non-listed medium-sized enterprise, a core enterprise in the supply chain, or other legal entities with operational activities and financial data records. The "multi-source time-series data" of the target enterprise includes two main components: internal financial indicators and external industry indicators. Internal financial indicators refer to accounting, cash flow, or operational efficiency data generated by the enterprise itself, such as the debt-to-equity ratio, revenue growth rate, accounts receivable turnover rate, and the ratio of net operating cash flow to net profit. These indicators reflect the enterprise's internal financial structure and operational health. External industry indicators reflect the macroeconomic environment and cyclical influencing factors of the industry in which the enterprise operates, such as commodity price indices, industry average financing rates, quarterly GDP growth rates, producer price index (PPI), or total social financing. This type of data is usually published by government departments or industry databases and can reflect the overall trend of industry prosperity and financing environment. By simultaneously collecting internal and external data, the model can establish a dynamic link between individual enterprise performance and changes in the macroeconomic environment, avoiding biases caused by single-dimensional prediction.

[0038] According to one embodiment of the present invention, after acquiring multi-source time-series data, standardization and synchronization processing are first required. "Time-series data" refers to a sequence of indicators arranged chronologically and recorded continuously. Different data sources may have inconsistent sampling frequencies or time alignment errors. For example, corporate financial statement data may be updated quarterly, while industry indicators may be released monthly or weekly. To ensure the effectiveness of subsequent analysis, the system adopts a unified time window mechanism to resample all data to a fixed time interval, such as merging data by quarter or month, and using interpolation or moving average methods to fill time gaps. This process is called "time alignment," and its key technical point is to maintain the relative trend consistency of the time series, rather than merely pursuing absolute numerical synchronization.

[0039] According to an embodiment of the present invention, in step S2, after data preprocessing is completed, the model enters the feature layer construction stage. The core of this stage is to establish a "correlation matrix R" to measure the degree of linear dependence between different features. The correlation matrix is ​​a symmetric matrix, where the element R(i,j) represents the Pearson correlation coefficient between feature i and feature j. The Pearson correlation coefficient ranges from -1 to +1, with positive values ​​indicating positive correlation, meaning that when one feature value increases, the other feature value also tends to increase; negative values ​​indicate negative correlation, meaning that the two features change in opposite directions; and values ​​close to 0 indicate no significant linear correlation. By calculating the correlation coefficients pairwise for all features, an n×n matrix structure can be obtained, where n is the number of input feature dimensions. The correlation matrix is ​​not only used to measure the correlation between features but also to guide the subsequent feature weighting and attention allocation process, serving as the core intermediate structure of the entire method.

[0040] According to one embodiment of the present invention, in step S4, based on the results of the correlation matrix, the system weights each feature according to its correlation strength with the target variable (i.e., the enterprise risk label). This "feature weighting" is not a traditional manual weighting, but is automatically completed through a calculated "attention allocation factor." The attention allocation factor is a set of parameters in a neural network structure that dynamically allocates the importance of input information, used to highlight features with high influence and weaken noisy features. Essentially, it is a set of learnable coefficients that are continuously updated based on the feedback from the loss function during model training. The related "attention weight" refers to the instantaneous numerical expression of this factor at a specific sample or time step, reflecting the degree of attention the model pays to each feature under the current input conditions. In other words, the attention allocation factor is a structural parameter, while the attention weight is a dynamic output result. The difference between the two is that one is used for parameter learning, and the other is used for actual inference.

[0041] According to one embodiment of the present invention, in step S4, during the feature weighting stage, the initial weights of each feature are automatically calculated based on the statistical results of the correlation matrix R, and a mechanism for distinguishing between positive and negative correlations is introduced. "Positively correlated features" refer to features that change in the same direction as the enterprise's risk level. For example, when an enterprise's debt ratio increases, its current ratio decreases, or its gross profit margin declines, these indicators are often accompanied by an increase in risk; therefore, they are positively correlated features. Conversely, "negatively correlated features" refer to indicators whose risk decreases when their values ​​increase, such as increased operating cash flow, improved return on net assets, and increased total asset turnover. These indicators have a protective effect on the enterprise's robustness and are therefore negatively correlated features. In this embodiment, the portion of the correlation matrix with a positive Pearson coefficient is classified as the positively correlated feature set, and the portion with a negative coefficient is classified as the negatively correlated feature set. Based on this division, the system adopts different strategies in the feature weighting stage: linear enhancement weighting is used for positively correlated features to amplify their influence weights proportionally, thereby improving the model's sensitivity to potential risk factors; while a residual suppression mechanism is used for negatively correlated features, that is, a reverse residual term is introduced when updating the weights to suppress their excessive amplification effect and ensure the model's stability under negative signals.

[0042] According to one embodiment of the present invention, in the trend and cycle prediction vector fusion stage, the model uses a feature fusion module to weightedly synthesize the two types of vectors into a comprehensive feature vector. In actual operation, redundant information may exist between different indicators, especially in high-dimensional feature spaces, where multiple sets of variables may exhibit strong linear dependencies. Therefore, the present invention introduces a correlation matrix R before feature fusion and performs soft thresholding on it to remove redundant channels. The processed matrix retains only channel features highly correlated with risk output, thereby reducing the computational burden on the model and improving feature expression efficiency.

[0043] According to one embodiment of the present invention, after feature weighting, a comprehensive feature vector is generated in step S4. This comprehensive feature vector can be understood as a new set of representations after weighted correction of the original input features, which simultaneously retains the information of the original financial data and the model's adjustment of risk sensitivity. At this time, the comprehensive feature vector is input into a fully connected neural network layer. A fully connected neural network is one of the most common feedforward neural network structures, consisting of an input layer, one or more hidden layers, and an output layer. The neurons in each layer are fully connected to all neurons in the previous layer, and the connection weights are continuously optimized during training through a backpropagation algorithm to minimize prediction error. In this embodiment, the role of the fully connected neural network is to extract nonlinear relationships from the comprehensive weighted feature vector and output a continuous value as the comprehensive financial risk score of the enterprise. This comprehensive score is between 0 and 1, representing the model's risk assessment result for the enterprise in the future. The closer the score is to 1, the higher the risk; the closer it is to 0, the lower the risk. For ease of application, the score is divided into several risk intervals, such as 0–0.33 for low risk, 0.34–0.66 for medium risk, and 0.67–1.00 for high risk. The threshold division can be automatically adjusted based on historical sample distribution or industry standards, making the risk levels of different enterprises comparable. Through this structural design, the model can output results that are both continuous and meaningful for classification, enabling the visualization and quantitative analysis of risk trends.

[0044] According to one embodiment of the present invention, during the training phase of the model, a supervised learning approach is adopted, using historical enterprise sample data as the training set, which includes known financial risk labels, such as whether the enterprise has defaulted, is in financial distress, or has experienced a rating downgrade. The model continuously adjusts the attention allocation factor, fully connected layer weights, and bias terms by minimizing the loss function between the predicted score and the true label, thereby improving prediction accuracy. Commonly used loss functions are binary cross-entropy or mean squared error, with the specific choice depending on the type of risk label. After training, the model can perform real-time risk prediction on newly input enterprise data and output a comprehensive score and risk level.

[0045] In practical applications of one or more embodiments, to ensure the stability and adaptability of the method under different data quality, industry cycles, and market conditions, multi-level extensions and optimizations have been performed on each module. Several typical exceptions are described below.

[0046] According to one embodiment of the present invention, during the multi-source time-series data acquisition stage, there are situations where the update frequency of external indicators for some enterprises or industries does not match their internal financial data. For example, enterprise financial indicators are usually released quarterly, while external indicators such as commodity price indices or financing rates are often updated monthly. To address this, the present invention employs a unified time window mechanism, using interpolation, moving average, and time alignment algorithms to map high-frequency external data to the same time step as internal data, thereby achieving consistent sampling frequencies. This mechanism effectively avoids the mismatch problem of different source data in the time dimension, enabling subsequent model training and trend decomposition to be performed under a unified benchmark. Furthermore, for situations with significant differences in industry characteristics (e.g., the consumer industry with weak cyclicality), the system allows for dynamic adjustment of the external indicator set through parameter configuration, allowing selection of whether to enable the industry supply-demand ratio change rate or the industry cyclical index, enabling the model to flexibly adapt to different types of enterprises. This feature corresponds to the content described in claim 2, and its core function is to ensure the time consistency and indicator representativeness of the input data structure during multi-source fusion.

[0047] According to one embodiment of the present invention, during the first Informer model processing stage, some enterprise data may contain sudden noise or abnormal peaks, such as short-term fluctuations caused by financial statement adjustments, seasonal purchases, or policy loans. To avoid outliers affecting the decomposition of trend and periodic terms, the present invention introduces a multi-scale convolution module at the input of the Informer to achieve multi-level noise suppression. This module simultaneously applies convolution kernels of different scales to the input sequence, thereby smoothing outliers in the time domain while preserving key change features. The data after multi-scale convolution processing then enters a multi-head attention mechanism to achieve accurate decomposition of trend and periodic terms.

[0048] According to one embodiment of the present invention, by introducing a consolidation gate structure, the memory unit can adaptively adjust the information retention ratio based on historical volatility. The consolidation gate establishes a dynamic equilibrium mechanism: when the indicator fluctuates significantly, the model tends to shorten the memory period to prevent excessive accumulation of abnormal fluctuations; when the indicator is stable over a long period, the consolidation gate extends the memory period to preserve its trend characteristics. This gating mechanism dynamically calculates weights based on historical volatility at each time step, and in conjunction with the residual connection mechanism, effectively avoids the gradient vanishing problem common in deep temporal networks, enabling the model to maintain learning ability and stability over long time series. The dynamic adjustment coefficient γ of the consolidation gate... t The financial characteristics of companies exhibit differentiated under different market conditions. In highly volatile market scenarios, such as periods of sharp macroeconomic fluctuations or sustained increases in raw material prices, the correlation between the financial characteristics of companies becomes significantly stronger.

[0049] According to one embodiment of the present invention, to enable the model to accurately learn key features under these conditions, this embodiment constructs an adaptive update rule for γt by introducing a Pearson correlation coefficient and a sliding entropy mechanism. When the Pearson correlation coefficient between the current input feature and the historical trend is higher than a preset threshold ρ0, the model automatically increases the state retention rate of that feature, thereby enhancing trend memory. When the sliding entropy of the feature increases, i.e., information uncertainty increases, the system automatically reduces the gating weight to prevent abnormal fluctuations from misleading the model's memory. This mechanism endows E-LSTM with strong robustness, enabling it to stably output long-term trend features even in highly volatile market environments.

[0050] According to one embodiment of the present invention, to further optimize the weighting strategy, an adjustment coefficient λ, λ∈[0,1], is introduced into the weight generation function. This coefficient is adaptively updated during the training phase based on the changing trend of the prediction error. Specifically, when the model's prediction error increases, the value of λ decreases, making the weight distribution more conservative and preventing excessive bias towards a certain feature vector; when the prediction error decreases, the value of λ increases, enhancing the weight of high-contribution features. This dynamic adjustment mechanism based on error feedback enables the model to continuously learn the optimal weighting strategy during the training phase, improving its resistance to abnormal external indicator disturbances.

[0051] According to one embodiment of the present invention, a grading mechanism is designed to enable dynamic fine-tuning of risk scores based on historical samples. Specifically, the system first calculates an empirical distribution based on historical default samples to determine initial threshold ranges for high, medium, and low risk. Subsequently, combining real-time prediction errors with industry averages, an adaptive fine-tuning algorithm is used to adjust the thresholds. For example, when the overall industry default rate rises, the system automatically lowers the high-risk threshold to maintain the sensitivity of risk level classification; when industry risk weakens, the system raises the threshold to reduce false alarm rates. The final grading standard is typically that a score ≥ 0.75 corresponds to the high-risk range, between 0.4 and 0.75 is the medium-risk range, and below 0.4 is the low-risk range, but this boundary can be flexibly adjusted according to industry cycles.

[0052] Overall, the intelligent financial risk early warning method mentioned in one or more embodiments demonstrates significant advantages when dealing with multi-source heterogeneous data. Through Informer's trend cycle decomposition, E-LSTM's consolidation gate mechanism, and P-CNN's local feature extraction, the model can distinguish and model long-term and short-term fluctuations. Through Nelson coefficient-driven attention weighting and λ adjustment mechanisms, the model possesses adaptive feature fusion capabilities. Through a dynamic threshold grading mechanism, the risk output results have flexible interpretability. These modules work synergistically, enabling the model to maintain stability and prediction accuracy even in various exceptional scenarios.

[0053] According to one embodiment of the present invention, in a specific financial processing scenario, the target company is assumed to be Company A, a medium-sized equipment manufacturing enterprise whose main products include industrial parts and machinery, belonging to a typical cyclical industry. Over the past three years, the company has experienced adverse factors such as fluctuations in raw material prices, rising financing costs, and reduced downstream orders. The finance department hopes to use an intelligent model to predict risk trends for the next two quarters in order to formulate financing and inventory strategies in advance. In this example, the system first obtains multi-source time-series data for Company A for the past twelve quarters. Internal data includes financial indicators such as debt-to-equity ratio, current ratio, net profit margin, operating cash flow, accounts receivable turnover days, inventory turnover rate, and interest coverage ratio. These indicators are all derived from the company's accounting system and publicly available financial statements, possessing high accuracy and time-series completeness. External data is obtained from industry databases and macroeconomic statistics, including metal raw material price indices, industry average financing rates, PPI, quarterly GDP growth rates, and credit market risk premiums. External indicators are sampled monthly and converted to quarterly frequencies using a moving average method to synchronize with internal data.

[0054] In this embodiment, during the data import phase, the system first performs missing value detection and outlier handling. For indicators with occasional missing values, linear interpolation is used to fill in the missing values; for sample points with abnormal volatility, correction is performed using the three-standard-deviation principle. Subsequently, time synchronization and standardization operations are performed to ensure that the dimensions of each indicator are consistent and the numerical ranges are similar. After processing, a structured time series matrix is ​​formed, with the horizontal axis representing the time series and the vertical axis representing the feature dimensions, totaling fifteen indicators.

[0055] In this embodiment, the model calculates the Pearson correlation coefficient between features on the preprocessed data, generating a correlation matrix R. Analysis reveals a significant positive correlation between the debt-to-equity ratio and the enterprise risk label (correlation coefficient 0.78), a significant negative correlation between net operating cash flow and the risk label (-0.65), a slight negative correlation between the current ratio and the risk label (-0.42), a positive correlation between the raw material price index and the risk label (0.58), and a strong positive correlation between the industry financing rate and the risk label (0.72). Based on these statistical relationships, the model automatically divides each feature into positively correlated and negatively correlated feature sets, and generates an initial attention allocation factor accordingly.

[0056] In this embodiment, during the weighting stage, the model employs linear enhancement weighting for positively correlated features. For example, the original weight of the debt-to-equity ratio, 0.08, is increased to 0.12 after weighting to enhance its sensitivity to risk signals; the industry financing rate is increased from 0.05 to 0.09. Simultaneously, a residual suppression mechanism is used for negatively correlated features. For instance, the weight of operating cash flow is reduced from 0.11 to 0.08, and a reverse residual term is added to ensure that its suppression effect remains stable in the model without being excessively weakened. After this stage, the system obtains a weighted feature vector, where the influence of each indicator has been dynamically adjusted based on its economic significance and historical statistical performance.

[0057] In this embodiment, the weighted feature vector is input into a fully connected neural network for nonlinear mapping and risk score prediction. The neural network comprises three layers: an input layer, a hidden layer, and an output layer. The output layer is a single node that outputs a comprehensive risk score between 0 and 1 using the sigmoid function. This is common knowledge in the field and will not be elaborated further. During the training phase, the model uses data from the past three years (twelve quarters) as samples. The corresponding true risk label is determined based on whether the company has experienced cash flow disruptions, rating downgrades, or debt defaults. Iterative training is performed using the Adam optimization algorithm, with the loss function being binary cross-entropy.

[0058] In this embodiment, the latest quarterly data is input into the model, and the output comprehensive risk score is 0.78. According to the grading rules, a score ≥0.75 is judged as a high-risk range, and the system automatically generates a "high-risk" label, which is marked in red on the visualization interface. By tracking the contribution weight of each feature, the model found that the main driving factors for the increase in risk include the continuous rise in the debt-to-equity ratio (weight contribution ratio 21%), the widening of industry financing interest rates (18%), and the significant decline in operating cash flow (17%). This result suggests that the vulnerability of the enterprise's financial structure is concentrated in external financing dependence and tight cash flow. To further verify the interpretability of the model, the system compared the prediction results of the previous quarter. The risk score in the previous quarter was 0.62, which was in the medium-risk range, while it rose to 0.78 in this quarter, indicating that the enterprise's risk level has increased significantly in the short term. By analyzing the changes in the correlation matrix, it can be seen that the overall influence of external indicators on the model has increased, especially the fluctuation of industry financing interest rates, which has become the main risk amplifier. Based on this, corporate management adjusted their financing strategies, locking in loan interest rates in advance and reducing short-term debt, resulting in a slight decrease in the risk score (from 0.78 to 0.71) observed in the next cycle. This change demonstrates the forward-looking and actionable value of the model's predictions.

[0059] This embodiment can also be used for cross-industry comparisons. Under the same economic environment, the system made predictions for five manufacturing companies, and the results showed that the risk scores ranged from 0.42 to 0.79, with Company A ranking second highest. By comparing their positive and negative correlation feature sets, it can be found that although the debt-to-equity ratios of the companies are similar, their cash flow volatility varies greatly, and Company A has a higher risk exposure in terms of inventory backlog and accounts receivable. This comparative analysis based on multi-source time-series data allows risk warnings to move beyond static indicators and dynamically reflect the relative risk levels of different companies in the same period.

[0060] Compared to traditional financial forecasting methods, this embodiment or other embodiments offer three advantages. First, by introducing external macroeconomic indicators at the data level, it can capture industry-wide risk factors, thus avoiding biased assessments based solely on internal company data. Second, at the feature processing level, it employs a correlation matrix and attention weighting mechanism, enabling the model to adapt to high-dimensional heterogeneous data, automatically identifying key features and dynamically allocating weights. Finally, at the output layer, by combining a comprehensive score with risk labels, it achieves a unification of continuous and hierarchical processing, enabling both trend tracking and risk classification decisions. Through the synergistic effect of these mechanisms, the risk labels output by the model not only reflect the current state but also predict the direction of change in the next one to two quarters.

[0061] Specifically, please refer to Figure 2 In one specific embodiment, a financial risk intelligent early warning system is provided, comprising:

[0062] The data acquisition and preprocessing module is used to acquire multi-source time-series data of the target enterprise. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the enterprise belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. The internal financial indicators and external indicators are aligned and standardized according to a unified time window.

[0063] The time series decomposition module is used to input the standardized data into the first Informer model, and to decompose the input sequence into a trend term and a periodic term using a multi-head attention mechanism. The trend term is processed by sliding window averaging to enhance stability, and the periodic term is processed by frequency domain filtering to extract seasonal fluctuations.

[0064] The feature extraction module is used to input the trend term into the enhanced long short-term memory network (E-LSTM) to extract long-term trend features, input the periodic term into the periodic convolutional extraction network (P-CNN) to capture short-term periodic features, and output trend prediction vector and periodic prediction vector.

[0065] The feature weighting module is used to calculate the Nelson coefficients corresponding to the trend prediction vector and the period prediction vector to characterize their fluctuation stability in the time dimension; the Nelson coefficients are used as attention allocation factors and input into the feature fusion module to form attention weights, and the trend prediction vector and the period prediction vector are weighted and fused to obtain a comprehensive feature vector.

[0066] The risk output module is used to input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period of time. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

[0067] Throughout the implementation process, the system architecture can be deployed on a server or cloud computing platform. Input data is received by the data interface module, the preprocessing module handles time alignment and standardization, the feature analysis module calculates the correlation matrix and outputs weighting factors, the neural network calculation module performs feedforward and backpropagation operations, and the final output module pushes the comprehensive score and risk level to a visualization interface or the enterprise's internal risk control system. The modules interact through standard API interfaces, ensuring a clear structure and scalability. It can run independently within an enterprise's internal financial system or interface with a financial institution's credit assessment system or industry monitoring platform to achieve batch enterprise risk monitoring. In terms of deployment, the model can run on a server or cloud platform, receiving real-time data updates through API interfaces to achieve automated, periodic risk prediction. The overall operation is stable, and risk score calculation can be completed within seconds after data updates, making it suitable for dynamic financial monitoring of medium and large enterprises.

[0068] Specifically, please refer to Figure 3 One specific embodiment discloses a computer device comprising:

[0069] processor;

[0070] Memory, which stores computer programs;

[0071] When the computer program is executed by the processor, the deep learning-based financial risk early warning method is implemented.

[0072] While the specific embodiments of the present invention have been described above in conjunction with the accompanying drawings, this is not intended to limit the scope of protection of the present invention. Those skilled in the art should understand that, based on the technical solutions disclosed in the present invention, various modifications or variations that can be made by those skilled in the art without creative effort should be included within the scope of protection of the present invention.

Claims

1. A method for intelligent early warning of financial risks, characterized in that, include: S1. Obtain multi-source time-series data of the target company. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the company belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. Align the internal financial indicators and external indicators according to a unified time window and perform standardization processing. S2. Input the standardized data into the first Informer model, use a multi-head attention mechanism to decompose the input sequence into a trend term and a periodic term, perform sliding window averaging on the trend term to enhance stability, and perform frequency domain filtering on the periodic term to extract seasonal fluctuations. S3. Input the trend term into the Enhanced Long Short-Term Memory (E-LSTM) network to extract long-term trend features, and input the periodic term into the Periodic Convolution Extraction Network (P-CNN) to capture short-term periodic features, and output the trend prediction vector and the periodic prediction vector. S4. Calculate the Nelson coefficients corresponding to the trend prediction vector and the cycle prediction vector to characterize their fluctuation stability in the time dimension; input the Nelson coefficients as attention allocation factors into the feature fusion module to form attention weights, and perform weighted fusion of the trend prediction vector and the cycle prediction vector to obtain a comprehensive feature vector. S5. Input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period of time. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

2. The intelligent early warning method for financial risks according to claim 1, characterized in that, The external indicators mentioned therein also include the industry supply-demand ratio change rate and / or the industry cyclical index. The external indicators and the internal financial indicators are kept consistent in sampling frequency to form a unified input time window.

3. The intelligent early warning method for financial risks according to claim 1, characterized in that, The first Informer model uses multi-scale convolution to suppress noise during the input phase.

4. The intelligent early warning method for financial risks according to claim 1, characterized in that, The enhanced long short-term memory network is equipped with a consolidation gate to adaptively adjust the memory state at each time step based on historical volatility, so as to balance the proportion of long-term and short-term memory, and to prevent gradient vanishing through a residual connection mechanism.

5. The intelligent early warning method for financial risks according to claim 4, characterized in that, The dynamic adjustment coefficient γ of the consolidation gate t Based on the joint determination of historical volatility and the correlation of input features, when the Pearson correlation coefficient of the current input feature is higher than the preset threshold ρ0, the weight of the feature in memory state update is increased; the consolidation gate weight is dynamically constrained through the sliding entropy mechanism to improve the robustness and generalization ability of the model under high volatility market conditions.

6. The intelligent early warning method for financial risks according to claim 1, characterized in that, In step S4, when the trend prediction vector and the period prediction vector are weighted and fused, a correlation matrix R is constructed to represent the cross-correlation strength between the trend prediction vector and the period prediction vector. In the correlation matrix R, the feature set with a positive correlation coefficient that exceeds the threshold is a positively correlated feature, and the feature set with a negative correlation coefficient that exceeds the threshold is a negatively correlated feature. Linear enhancement weighting is applied to the positively correlated features, and a reverse residual suppression mechanism is applied to the negatively correlated features. The attention weights are automatically grouped according to the sign of the Pearson correlation coefficient.

7. The intelligent early warning method for financial risks according to claim 1 or 6, characterized in that, The attention weights are generated by an attention weight generation function, which introduces an adjustment coefficient λ∈[0,1], which is adaptively updated based on the prediction error.

8. The intelligent early warning method for financial risks according to claim 1, characterized in that, The comprehensive risk assessment score is then converted into risk labels through a grading mechanism: a score ≥ 0.75 corresponds to a high-risk range, a score between 0.4 and 0.75 corresponds to a medium-risk range, and a score < 0.4 corresponds to a low-risk range. The grading threshold can be dynamically adjusted based on historical default samples to adapt to different industry characteristics.

9. A financial risk intelligent early warning system, characterized in that, include: The data acquisition and preprocessing module is used to acquire multi-source time-series data of the target enterprise. The multi-source time-series data includes internal financial indicators and external indicators related to the cyclical industry to which the enterprise belongs. External indicators include at least commodity price indices, industry average financing rates, and quarterly GDP growth rates. The internal financial indicators and external indicators are aligned and standardized according to a unified time window. The time series decomposition module is used to input the standardized data into the first Informer model, and to decompose the input sequence into a trend term and a periodic term using a multi-head attention mechanism. The trend term is processed by sliding window averaging to enhance stability, and the periodic term is processed by frequency domain filtering to extract seasonal fluctuations. The feature extraction module is used to input the trend term into the enhanced long short-term memory network (E-LSTM) to extract long-term trend features, input the periodic term into the periodic convolutional extraction network (P-CNN) to capture short-term periodic features, and output trend prediction vector and periodic prediction vector. The feature weighting module is used to calculate the Nelson coefficients corresponding to the trend prediction vector and the period prediction vector to characterize their fluctuation stability in the time dimension; the Nelson coefficients are used as attention allocation factors and input into the feature fusion module to form attention weights, and the trend prediction vector and the period prediction vector are weighted and fused to obtain a comprehensive feature vector. The risk output module is used to input the comprehensive feature vector into the fully connected layer of the first neural network and output the comprehensive financial risk evaluation score of the target enterprise in the future period. The score is between 0 and 1 and is divided into high risk, medium risk and low risk ranges according to the threshold.

10. A computer device, characterized in that, include: processor; Memory, which stores computer programs; When the computer program is executed by the processor, it implements the intelligent early warning method for financial risks as described in any one of claims 1 to 8.