A financial abnormal data analysis method and system based on artificial intelligence
Through dynamic data flow diagrams and causal reasoning models based on artificial intelligence, the adaptability and interpretability problems of existing financial anomaly detection are solved, accurate and real-time financial anomaly prediction and analysis are achieved, and the efficiency of financial management and decision-making support are improved.
Patent Information
- Application Number
- CN202510241058.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-03
- Publication Date
- 2025-09-26
- Estimated Expiration
- 2045-03-03
AI Technical Summary
Existing financial anomaly detection methods lack adaptability when faced with dynamically changing financial environments and complex causal relationships, resulting in inaccurate anomaly predictions, poor real-time performance, and lack of explainability, making it difficult to support effective decision-making.
Using an AI-based approach combined with the incremental learning mechanism of real-time machine learning, we build an adaptive causal reasoning model through dynamic data flow graphs and causal reasoning. We use a sliding time window to update the model and perform real-time anomaly detection and prediction of financial data.
It achieves accurate and real-time anomaly detection and prediction of complex financial data, provides transparent decision support, enhances the system's ability to respond to emergencies, and improves the efficiency and accuracy of financial management.
Smart Images

Figure CN119762259B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of artificial intelligence, and in particular relates to an artificial intelligence-based financial abnormal data analysis method and system. Background Art
[0002] Detecting anomalies in financial data is a core task in corporate financial management, risk control, and auditing. With the increasing complexity of the global economic and market environment, the types of financial risks facing enterprises are becoming increasingly diverse and difficult to predict. Traditional financial anomaly detection methods often rely on manually set rules, fluctuation detection based on statistical models, or basic machine learning models. While these methods have been effective in some scenarios, they exhibit significant limitations when faced with increasingly complex and dynamically changing financial data. Traditional methods often rely on preset rules or thresholds and are unable to adapt to changing financial environments and market conditions. For example, rule-based anomaly detection methods often assume that the patterns of financial data fluctuations are static, making them unable to adapt to changes in a company's business, external economic fluctuations, and sudden market events. While statistical model-based anomaly detection methods, such as standard deviation and moving average, can detect unusual fluctuations in financial data to a certain extent, they ignore the underlying causal relationships between data, fail to effectively explain the underlying causes of anomalies, and often produce a high number of false positives or false negatives. Furthermore, while machine learning-based anomaly detection methods can, to a certain extent, uncover nonlinear relationships in data, many models still lack sufficient interpretability, making it difficult for financial analysts and decision makers to understand and respond to detected anomalies. This is especially true when a company's financial data is impacted by complex external factors (such as policy changes and market fluctuations) and internal changes (such as management decision-making changes and operational strategy adjustments). Existing anomaly detection methods are unable to accurately grasp these complex causal relationships, resulting in ineffective anomaly predictions or delayed responses.
[0003] Therefore, while existing technologies have been effective in identifying some simple financial anomalies, they often struggle when faced with dynamically changing financial environments and the complex causal relationships between data. Most existing methods rely on static models or rule-based approaches, lacking the ability to dynamically update and adapt. In the absence of an explanation for the underlying causes behind anomalies, the early warning information provided by many existing methods is often vague, making it difficult for managers to make timely and effective decisions. At the same time, existing financial anomaly analysis systems still lack a deep understanding and understanding of the complex causal relationships behind corporate financial data, which limits companies' ability to prevent potential financial risks. Therefore, there is an urgent need for a new solution that can overcome the shortcomings of existing technologies and provide more accurate, real-time, and explainable financial anomaly detection and prediction. Summary of the Invention
[0004] This invention aims to design an artificial intelligence-based financial anomaly data analysis method and system. By incorporating the incremental learning mechanism of real-time machine learning, this method successfully overcomes the shortcomings of existing technologies in anomaly detection in dynamic financial environments, providing a more accurate, real-time, and interpretable financial anomaly prediction and analysis solution. These innovations not only improve the efficiency of financial anomaly detection but also enhance the system's ability to respond to complex financial issues, providing more reliable data support for financial decision-making.
[0005] In order to achieve the above object, a first aspect of the present invention provides a method for analyzing abnormal financial data based on artificial intelligence, the method comprising the following steps:
[0006] S101. Collect the financial data to be identified, construct a dynamic data flow graph based on the financial data, and introduce a causal reasoning method into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. When new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph.
[0007] S102. Based on the dynamic data flow graph, a causal inference model of the dynamic data flow graph is constructed using an adaptive causal inference method based on a sliding time window. In the causal inference model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to form the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed.
[0008] S103. Build an anomaly detection model and a prediction model. When a real-time data stream is input, extract the causal inference feature of each node from the causal influence of adjacent nodes in the dynamic data flow graph based on the key features of the real-time data stream, and represent the causal influence score of the node.
[0009] The anomaly detection model determines whether an anomaly occurs based on the causal influence score and its historical distribution, and the prediction model makes predictions for future moments based on the current node;
[0010] S104: Generate an anomaly warning and decision support report based on the output results of the anomaly detection model and the prediction model;
[0011] S105. Adaptively optimize the anomaly detection model and the prediction model, and calculate the deviation between the current anomaly detection model and the current prediction model and the historical anomaly detection model and the historical prediction model. When the deviation exceeds a preset threshold, the model update is triggered, and the anomaly warning and decision support report is updated at the same time to generate the latest anomaly warning and decision support report.
[0012] Furthermore, the dynamic data flow graph is represented as ,in, Represents the node set at time t, each node Represents a financial indicator, Represents the edges connecting these nodes, and the edges represent the dependencies between indicators;
[0013] The dynamic data flow graph is constructed as follows:
[0014] Each financial indicator All as a node , so the node set , each node represents a specific financial indicator;
[0015] Initially establish edge sets based on the correlation between financial indicators ; Among them, the correlation between the financial indicators is the node and The Pearson correlation coefficient between them is used to construct preliminary edges based on the Pearson correlation coefficient:
[0016] If the absolute value of the Pearson correlation coefficient is greater than the set threshold, then at the node and Establish a preliminary boundary between , , indicating a strong correlation between the two financial indicators.
[0017] Furthermore, the introduction of the causal reasoning method to optimize the edge weights of the dynamic data flow graph includes:
[0018] Estimate the causal relationship between two financial indicators through Granger causality analysis, including:
[0019] For two financial indicators and If the financial indicators Financial indicators Has significant predictive power, then financial indicators Financial indicators have causal influence;
[0020] The significant predictive ability is determined based on Granger causality analysis.
[0021] Furthermore, in S1, when the financial environment changes, the edges and weights in the dynamic data flow graph are dynamically adjusted by calculating new causal relationships each time and combining correlations. The weight changes of the edges in the graph are controlled by dynamic adjustment items, so that the graph structure can adapt to changes in real-time data.
[0022] Furthermore, in the causal reasoning model, when a node enters, a causal chain is generated for each node to describe the path of anomaly propagation:
[0023] For each node , starting from this node, along the edge in the dynamic data flow graph Trace back and find all the nodes that affect it, forming a causal chain , which describes the chain from other indicators to The causal transmission path;
[0024] For each causal path , assign a weight to it , where the weight is the product of the weights of all edges on the path:
[0025] Sort all causal paths and select the top K strongest causal chains for subsequent anomaly detection;
[0026] In the causal inference model that uses the adaptive causal inference method based on sliding time windows to construct a dynamic data flow graph, the financial data in the time series is divided into sliding windows of length T, and the data in each window is represented as ,in, Representation node For time series data at time t, the reasoning goal of setting causal relationships is to estimate the causal impact between various indicators through a regression model:
[0027] Assume that within the window T, the indicator Subject to indicators The causal effect of is modeled through regression models;
[0028] The causal relationship is quantified in each regression, and an L1 regularization term is introduced to suppress insignificant regression coefficients, thereby making the model more sparse and removing redundant causal paths.
[0029] Furthermore, before building the anomaly detection model and prediction model, a sliding window mechanism is first used to monitor the changes in real-time data and extract key features. For each node , from adjacent nodes Extract the causal influence of , represents the causal influence score of the node.
[0030] Furthermore, the anomaly detection model is constructed as follows:
[0031] Collection Node Historical data, including nodes The mean and standard deviation of the past W moments, combined with the node The causal effect of the node is calculated by analyzing the standard deviation of the absolute difference between the causal effect and the mean. If the anomaly score is greater than the anomaly threshold, the node is considered There is an anomaly;
[0032] The prediction model is constructed as follows:
[0033] The causal strength estimated by the regression model is used as the node For Node The prediction coefficient of the node is used to establish a multivariate time series prediction model based on the causal relationship diagram and historical data. The observation values at time t are weighted and corrected using the prediction error to obtain the final node The predicted value of ; where the prediction error follows a normal distribution;
[0034] At the same time, regularization terms are introduced into the anomaly detection model and the prediction model to prevent overfitting of the model and optimize its adaptability to historical data;
[0035] The update mechanism of the anomaly detection model and prediction model is as follows:
[0036] Whenever the system detects new data or anomalies, the anomaly detection model and the prediction model automatically adjust the weighting coefficients of causal influence , prediction coefficient and the threshold for anomaly scoring , so that the prediction and detection effects can adapt to new data patterns.
[0037] Furthermore, the S104 specifically includes:
[0038] A. Generation of abnormal warning report:
[0039] Based on the anomaly score of each node, the degree of anomaly of each node is calculated, which is measured based on the ratio of the anomaly score to the historical standard deviation of the node;
[0040] According to the abnormality level of each node, the nodes are divided into different abnormality levels, including mild, moderate and severe abnormalities;
[0041] Use a sliding window approach to calculate the duration of an abnormal event:
[0042] In the past W time steps, if the node If the anomaly score of a node exceeds a certain threshold continuously, the anomaly is considered to be persistent. Based on the causal graph model, the impact of the anomaly on other related nodes is evaluated.
[0043] By calculating the influence propagation between nodes, evaluating nodes Whether the abnormality will affect other key financial indicators;
[0044] B. Decision support report generation:
[0045] Based on predicted future values , showing the forecast trend of each financial indicator in the future, including the forecast value and the corresponding confidence interval;
[0046] C. Combine the anomaly score, anomaly degree, and predicted future value to assess the risk level of the overall financial system through indicator function analysis;
[0047] D. Provide specific response recommendations to decision makers based on risk levels.
[0048] Furthermore, the deviation calculation is the mean absolute deviation of the anomaly scores at time t and t-1; when the mean absolute deviation exceeds a preset threshold, the update of the anomaly detection model and the prediction model is automatically triggered.
[0049] In a second aspect of the present invention, a financial abnormality data analysis system based on artificial intelligence is provided, the system comprising the following modules:
[0050] The financial data collection module is used to collect the financial data to be identified and construct a dynamic data flow graph based on the financial data. The causal reasoning method is introduced into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. When new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph.
[0051] The dynamic data flow graph construction module is used to construct a causal reasoning model of the dynamic data flow graph based on the dynamic data flow graph using an adaptive causal reasoning method based on a sliding time window. In the causal reasoning model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to construct the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed.
[0052] The risk warning module is used to build anomaly detection models and prediction models. When there is real-time data stream input, it extracts the causal inference features of each node from the causal influence of adjacent nodes in the dynamic data flow graph based on the key features of the real-time data stream, and represents the causal influence score of the node.
[0053] The anomaly detection model determines whether an anomaly occurs based on the causal influence score and its historical distribution, and the prediction model makes predictions for future moments based on the current node;
[0054] A report generation module, configured to generate anomaly warning and decision support reports based on the output results of the anomaly detection model and the prediction model;
[0055] The system optimization module is used to adaptively optimize the anomaly detection model and prediction model, and calculate the deviation between the current anomaly detection model and the current prediction model and the historical anomaly detection model and the historical prediction model. When the deviation exceeds a preset threshold, the model update is triggered, and the anomaly warning and decision support report is updated at the same time to generate the latest anomaly warning and decision support report.
[0056] The beneficial technical effects of the present invention are at least as follows:
[0057] The present invention solves several problems existing in existing technologies for financial anomaly detection by combining causal reasoning, data flow graphs, and real-time machine learning techniques. First, to address the limitations of existing technologies in dealing with dynamic financial data, the present invention uses an adaptive causal reasoning method to model and analyze the complex relationships between financial data, and is able to dynamically capture changes in the causal relationships between data. For example, by constructing a dynamic data flow graph, the system can flexibly respond to the influence of factors such as market changes and adjustments to internal business strategies of the enterprise, thereby achieving real-time and accurate anomaly detection. This innovation effectively overcomes the shortcomings of traditional methods that are unable to adapt to complex financial environments and rapidly changing market conditions.
[0058] Secondly, existing financial anomaly detection methods often lack an effective explanation of the causes of anomalies, resulting in insufficient financial analysis and decision-making support. To address this issue, the present invention introduces a causal reasoning model, combined with a data flow diagram, to comprehensively analyze the causal chain behind anomalies and accurately reveal the root causes of abnormal data. This not only improves the accuracy of anomaly detection, but also provides transparent decision-making support for financial managers, helping them understand the specific context in which the anomaly occurred and take effective measures to intervene and adjust. This innovation addresses the shortcomings of traditional methods in terms of explanatory power and causal analysis, enabling financial managers to make more informed decisions.
[0059] Finally, to address the limitations of traditional models in terms of dynamic updating and learning, this paper introduces an incremental learning mechanism based on real-time machine learning, ensuring that the system can be updated and adjusted at any time based on new financial data. This adaptive learning mechanism enables the model to reflect new trends and patterns in real time as the data stream changes, effectively responding to emergencies or market fluctuations. Through incremental learning, the system not only maintains high prediction accuracy but also prevents model obsolescence when the data environment changes, thereby significantly improving the real-time and adaptability of anomaly detection.
[0060] Therefore, this invention successfully overcomes the shortcomings of existing technologies in anomaly detection in dynamic financial environments by combining adaptive causal reasoning and data flow graph models with the incremental learning mechanism of real-time machine learning. It provides a more accurate, real-time, and interpretable financial anomaly prediction and analysis solution. These innovations not only improve the efficiency of financial anomaly detection but also enhance the system's ability to respond to complex financial problems, providing more reliable data support for financial decision-making. BRIEF DESCRIPTION OF THE DRAWINGS
[0061] The present invention is further described with reference to the accompanying drawings. However, the embodiments in the accompanying drawings do not constitute any limitation to the present invention. A person skilled in the art can obtain other drawings based on the following drawings without creative effort.
[0062] Figure 1 This is a flow chart of an artificial intelligence-based financial abnormal data analysis method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0063] The following describes embodiments of the present invention in detail. Examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended only to explain the present invention and are not to be construed as limiting the present invention.
[0064] In one or more embodiments, Figure 1 As shown, the present invention discloses an artificial intelligence-based financial abnormal data analysis method, which includes the following steps:
[0065] S101, collect the financial data to be identified, and build a dynamic data flow graph based on the financial data, and introduce a causal reasoning method into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. Whenever new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph; wherein, the dynamic data flow graph ,in Represents the node set at time t, each node Represents a financial indicator, Represents the edges connecting these nodes, and the edges represent the dependencies between indicators.
[0066] Specifically, build a dynamic, time-series financial data flow diagram , extracting information from multiple dimensions and financial indicators, and clearly describing the temporal dependencies and causal relationships between each financial indicator in a graph. This step provides basic input for subsequent anomaly detection and reasoning analysis.
[0067] The input is a financial dataset ,in represents the i-th financial indicator (e.g., revenue, expenditure, profit, liabilities, etc.), which is recorded in time series, such as daily, monthly, or quarterly. N represents the number of financial indicators.
[0068] Furthermore, to ensure temporal consistency of the data, all indicators were first timestamped to ensure consistent time granularity across indicators. Missing values were filled using interpolation, and outliers were removed using the 3 standard deviation rule (or using the upper and lower quartiles).
[0069] In order to eliminate the dimensional impact between different financial indicators, each indicator Perform standardization. The standardization formula is:
[0070] ;
[0071] in, For indicators The mean of For indicators The standard deviation of .
[0072] Furthermore, a dynamic data flow diagram is constructed based on financial data ,in Represents the node set at time t, each node Represents a financial indicator, Represents the edges connecting these nodes, and the edges represent the dependencies between indicators.
[0073] Node definition: Each financial indicator (After preprocessing) are all treated as a node , so the node set , each node represents a specific financial indicator, such as revenue, profit, liabilities, etc.
[0074] Initial edge establishment: Initially establish edges based on the correlation between financial indicators. .set up for and The Pearson correlation coefficient is: ;
[0075] like (set threshold), then at the node and Establish a preliminary boundary between , indicating a strong correlation between the two financial indicators.
[0076] Furthermore, in the initial establishment of Based on this, we further introduce causal relationship modeling and optimize edge weights The traditional correlation method cannot directly express the causal relationship between financial indicators, so it is necessary to introduce causal reasoning methods to optimize edge weights.
[0077] Furthermore, the steps of causal relationship modeling are:
[0078] Granger Causality analysis is used to estimate the causal relationship between financial indicators. and ,if right Has significant predictive power (i.e. The historical value can be significantly improved prediction accuracy), then right Has a causal impact.
[0079] Assume that Granger causality strength is , then the weight The initial value of can be set to: ;
[0080] in, is an indicator function, if the correlation Greater than the set threshold , then the causal strength is introduced as the edge weight, otherwise the weight is 0.
[0081] Furthermore, in order to avoid overfitting and increase the stability of the model, an L1 regularization term is added to the causal strength To constrain: ;
[0082] in, is the regularization strength coefficient. Through this regularization, redundant edges and weakly correlated causal relationships are reduced, making the data flow graph more streamlined and focusing on the most relevant financial indicators.
[0083] Furthermore, to ensure that the data flow graph can adapt to changes in the financial environment, a time sliding window mechanism is adopted. A fixed-length time window T is set (for example, the financial data of the past 12 months), and the window continues to slide forward as time progresses.
[0084] Whenever new financial data flows in, the graph is updated using the data in the sliding window. For example, the graph at the current time t Based on the data in the window, the correlation and causal relationship between all indicators are calculated and a new .
[0085] Due to changes in the financial environment, the causal relationship between certain financial indicators may change. Therefore, the edges and weights in the graph are dynamically adjusted by calculating the new causal relationship each time and combining the correlation.
[0086] In particular, the introduction of dynamic adjustment items To update the weights: ;
[0087] in, To adjust the coefficient, the weight changes of the edges in the graph are controlled by dynamic adjustment items, so that the graph structure can adapt to the changes of real-time data.
[0088] Furthermore, through the above steps, the dynamic financial data flow graph at time t is output ,The graph contains the temporal dependency and causal relationship between financial indicators.,The weight of the edge in the graph represents the causal strength and correlation between,the financial indicators. As a time-series data flow graph, it will serve as the input for subsequent steps (such as anomaly detection, risk prediction, and causal reasoning), supporting subsequent higher-level analysis.
[0089] S102. Based on the dynamic data flow graph, an adaptive causal reasoning method based on a sliding time window is used to construct a causal reasoning model of the dynamic data flow graph. In the causal reasoning model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to form the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed.
[0090] Specifically, in step S101, the present invention obtains a financial data flow diagram through dynamic modeling ,in It is a node set containing various financial indicators. Represents the edge set between nodes, edge weight Represents the preliminary correlation between the two financial indicators. In order to conduct an in-depth analysis of the causal relationship between these indicators, the goal of this step is to build a more accurate causal network based on this preliminary correlation information and dynamically update the financial flow diagram.
[0091] Therefore, the input of step S102 is , each node represents the financial indicators at time t, and each edge Representation node and The present invention further uses an adaptive causal reasoning method to quantize the edges in ,improve their causal relationships.
[0092] Furthermore, in order to improve the data flow graph To improve the causal reasoning capability of the data, the present invention adopts an adaptive causal reasoning method based on a sliding time window. Specifically, the present invention divides the financial data in the time series into sliding windows of length T, and the data in each window is represented as: ,in, Representation node Time series data at time t. In order to establish a more accurate causal inference model, the present invention sets the reasoning goal of the causal relationship as estimating the causal influence between various indicators through a regression model.
[0093] Assume that within the window T, the indicator Subject to indicators The present invention models the causal influence of , which is modeled by a regression model:
[0094] ;
[0095] in, is the regression coefficient, indicating right The effect after a lag of k steps, is the error term, which is assumed to be normally distributed.
[0096] In order to quantify the causal relationship in each regression, this paper introduces an L1 regularization term to suppress insignificant regression coefficients, thereby making the model more sparse and removing redundant causal paths:
[0097] ;
[0098] in, is the L1 norm regularization term, is the regularization strength, which controls the sparsity of causal influences.
[0099] Furthermore, in the causal inference model, the present invention calculates the regression coefficient To quantify the causal relationship between financial indicators, these regression coefficients constitute the causal strength To update the edge weights in the data flow graph , the present invention adopts an update strategy based on regression results:
[0100] ;
[0101] in, is the causal strength estimated from the above regression model, is a smoothing factor that controls the degree of integration of new causal information and historical information. is the edge weight at the previous moment.
[0102] In addition, in order to remove redundant edges and reduce the impact of noise, the present invention sets an edge weight threshold ,like Below this threshold, edges are removed , making the data flow diagram more concise and focusing on important causal relationships:
[0103] ;
[0104] Furthermore, in order to further enhance the abnormal prediction capability of financial data, the present invention generates a causal chain for each node. , describing the path of abnormal propagation. The specific steps are as follows:
[0105] For each node , the present invention starts from it and follows the edge of the data flow graph Trace back and find all nodes that directly or indirectly affect it This forms a causal chain. , which describes the chain from other indicators to causal transmission path.
[0106] For each causal path , the present invention assigns a weight , which is the product of the weights of all edges on the path:
[0107] ;
[0108] in, Reflects the shift from other indicators to the combined impact.
[0109] All causal paths are sorted and the top K strongest causal paths are selected for subsequent anomaly detection.
[0110] Furthermore, through the above causal reasoning and optimization steps, the present invention obtains an optimized causal data flow graph , which includes the following improvements:
[0111] is the edge set after causal reasoning optimization, where the edge weight It reflects the strength of causal relationship between financial indicators. In the graph, some irrelevant or weakly related edges are removed, which enhances the simplicity of the graph. For each node Multiple causal propagation paths are generated, providing a reliable basis for anomaly detection and early warning.
[0112] Finally, step S102 outputs a data flow graph based on causal relationship optimization This graph provides key support for subsequent anomaly detection and prediction. This step provides a more detailed and highly interpretable financial data flow graph through precise causal reasoning and dynamic adjustment.
[0113] S103. Construct an anomaly detection model and a prediction model. When there is a real-time data stream input, according to each node corresponding to the key features of the real-time data stream, the causal inference features of the node are extracted from the causal influence of the adjacent nodes of the dynamic data flow graph to represent the causal influence score of the node. The anomaly detection model determines whether an anomaly occurs based on the causal influence score and its historical distribution, and the prediction model makes predictions for future moments based on the current node.
[0114] Specifically, the input comes from step S102: is the data flow graph after causal relationship optimization, For nodes causal inference characteristics.
[0115] The goal is to build a model that can detect anomalies and predict trends based on this causal inference feature and historical data. To this end, the present invention first defines a time window W, which represents the length of the historical data to be processed. Represents a historical data set within a window, where each element Represents the financial indicators at time tk Observed values.
[0116] Furthermore, in this step, based on the causal diagram and the input data stream , the present invention adopts a sliding window mechanism to monitor the changes of real-time data and extract key features. , the present invention starts from the adjacent nodes Extract the causal influence of , represents the causal influence score of the node.
[0117] In order to capture the dynamic relationships in the data flow, the present invention uses the following formula to calculate the causal influence of each node:
[0118] ;
[0119] in, is the weight coefficient, indicating that the node right The degree of impact, is the edge weight of the causal relationship, is the node at time t-1 This formula is based on the transmission of causal flow, which transfers the causal relationship between nodes through Translated into the impact on changes in financial data at the current moment.
[0120] Furthermore, the anomaly detection model is constructed:
[0121] Anomaly detection is the key goal of this step. In order to identify anomalies in real-time data, the present invention compares the causal influence of each node. and its historical distribution to determine whether an anomaly occurs. Assume that node The mean of the historical data in the past W moments is , the standard deviation is , the present invention calculates the abnormality score of each node by the following formula:
[0122] ;
[0123] in, and Represents nodes respectively The mean and standard deviation within the historical window. The degree to which current causal effects deviate from the historical normal range. , then the node Considered to be abnormal.
[0124] This abnormal score This model reflects whether each node's behavior is inconsistent with its historical pattern, thereby determining whether financial indicators are experiencing abnormal fluctuations. This scoring model can effectively identify anomalies caused by economic fluctuations or operational errors by dynamically detecting causal influences.
[0125] Furthermore, the prediction model is constructed:
[0126] In addition to anomaly detection, the financial system also needs to have the ability to accurately predict future trends. Here, the present invention establishes a multivariate time series prediction model based on the causal relationship graph and historical data to predict the future time t+1 node In order to fully utilize the causal influence between nodes, the present invention designs the following causal prediction formula:
[0127] ;
[0128] in, is a node For Node The prediction coefficient of is a node The observed value at time t, is the prediction error, assuming it obeys normal distribution. In order to ensure the accuracy of the prediction results, the present invention will gradually update the prediction coefficients through the regression model. , and adjusts its adaptive weights through the training process of historical data.
[0129] This prediction formula combines historical data with causal relationships to predict the future value of financial indicators, providing data support for decision makers. The prediction results help financial personnel forewarn of potential problems and take countermeasures.
[0130] Furthermore, in order to improve the stability and robustness of the model, the present invention introduces a regularization term , which is used to prevent the model from overfitting and optimize its adaptability to historical data. The form of this regularization term is:
[0131] ;
[0132] in, is a regularization parameter that controls the balance between model complexity and fitting accuracy. By introducing the regularization term, the present invention can avoid overfitting due to data noise while ensuring that the model can flexibly adapt to complex financial data.
[0133] In addition, the present invention designs an abnormal enhancement mechanism by scoring the abnormality of the model Weighting is performed to increase the weight of outliers so that the model can respond more sensitively to major anomalies. Specifically, for nodes whose anomaly scores exceed the threshold, , the present invention enhances its influence on prediction and anomaly scoring, reflecting the impact of these abnormal nodes on the entire financial data system.
[0134] Furthermore, in the end, the model outputs two results:
[0135] Anomaly detection results: For each node , output anomaly score ,if , then mark the node as an abnormal node.
[0136] Future prediction results: For each node , output the predicted value at the future time t+1 , so that decision makers can predict future trends.
[0137] Through these outputs, the system can monitor financial data in real time, identify potential abnormal fluctuations in advance, and predict future financial trends based on causal models. This feedback mechanism helps finance personnel take timely remedial measures to mitigate risks.
[0138] Understandably, in real applications, financial data is constantly changing, and the model needs to have adaptive capabilities to adjust its prediction and anomaly detection mechanisms. Whenever the system detects new data or anomalies, the model automatically adjusts the weighting coefficients of causal influence. , prediction coefficient and the threshold for anomaly scoring , so that the prediction and detection effects can adapt to new data patterns. The update mechanism takes the following form:
[0139] ;
[0140] ;
[0141] in, is the smoothing factor for causal effects, is the learning rate of the prediction coefficient, For nodes Through this dynamic adjustment mechanism, the system can adapt to the changing financial environment and maintain the effectiveness of real-time monitoring and forecasting.
[0142] Through the design of step S103, the system can detect anomalies and predict trends in real-time financial data streams through causal relationships. Combining innovative causal impact analysis, anomaly scoring mechanisms, and adaptive forecasting models, financial decision makers can promptly identify abnormal fluctuations, predict future trends, and make self-adjustments based on feedback mechanisms, improving the accuracy and stability of financial data analysis.
[0143] S104: Generate an anomaly warning and decision support report based on the output results of the anomaly detection model and the prediction model.
[0144] Specifically, the purpose of the abnormal warning report is to enable decision makers to quickly identify current abnormal financial indicators and make a detailed analysis of the nature of the abnormalities (degree, duration, etc.) to help them take effective management measures.
[0145] Furthermore, the abnormality score obtained from step S103 of the present invention is Representation node The abnormality level at time t. To determine the severity of the abnormality, the present invention designs the following calculation method:
[0146] Calculate the degree of anomaly for each node based on the anomaly score and the node's historical standard deviation Measured by the ratio:
[0147] ;
[0148] in, For nodes The abnormality score, is the historical standard deviation, reflecting the volatility of the node under normal circumstances.
[0149] According to the calculated , nodes can be divided into different abnormality levels (mild, moderate, severe). The present invention uses a grading function To classify the degree of abnormality:
[0150] ;
[0151] in, and The pre-set thresholds distinguish mild, moderate and severe abnormalities.
[0152] Furthermore, a sliding window method is used to calculate the duration of abnormal events. In the past W time steps, if the node Anomaly score Continuously exceeding a certain threshold , then the anomaly is considered to be persistent. According to the causal graph model , the present invention evaluates the impact of anomalies on other related nodes. By calculating the influence propagation between nodes, the node is further evaluated. Will the abnormality affect other key financial indicators? The impact assessment formula is:
[0153] ;
[0154] in, Representation node The abnormality of its adjacent nodes The impact of is the causal influence weight between adjacent nodes, Score the anomaly of adjacent node j. The above anomaly evaluation helps build a complete anomaly warning information, so that the report can show the severity, duration and possible chain reactions of the anomaly.
[0155] Furthermore, decision support reports should not only identify current anomalies, but also combine future forecast results to help decision makers understand possible future trends and potential risks, thereby guiding their strategy formulation.
[0156] Based on the future value predicted in step S103 , the present invention displays the forecast trend of each financial indicator at a future time, including the forecast value and the corresponding confidence interval. To this end, the present invention uses the following formula to calculate the confidence interval:
[0157] ;
[0158] where z is the critical value of the standard normal distribution (for example, z = 1.96 corresponds to a 95% confidence level), For nodes Standard deviation of the forecast value. By displaying the future trend forecast and its confidence interval for each node, the report can provide decision makers with a specific financial trend forecast, helping them identify potential future risks (such as cash flow shortages or reduced revenue).
[0159] Furthermore, combined with the abnormality score , abnormality degree , Future Forecast and impact assessment , the present invention assesses the risk level of the entire financial system. The present invention proposes a new comprehensive risk score , which combines the severity of the anomaly and the risk of future trends:
[0160] ;
[0161] in, For nodes The importance weight reflects the relative importance of the node in the entire financial system. It is an adjustment coefficient used to adjust the impact of future forecast results deviating from the confidence interval. is an indicator function, when the predicted value Not in the confidence interval The value is 1 when the anomaly is within the risk range, and 0 otherwise. This formula takes into account the current severity of the anomaly and future uncertainty, helping decision makers assess the overall risk and make response measures.
[0162] Furthermore, based on the above risk assessment results The report will provide decision makers with specific response recommendations. For example, if certain nodes have high anomaly scores and future trends are unstable, the report may recommend increasing risk reserves, adjusting investment directions, or strengthening monitoring of certain financial projects.
[0163] Furthermore, to ensure that decision makers can intuitively understand the report content, the present invention designs multiple visual elements:
[0164] Anomaly heat map: displays the anomaly score of each node , using color intensity to identify the severity of the anomaly.
[0165] Trend Forecast Chart: Displays forecast values for future moments and its confidence interval, intuitively presenting future financial trends.
[0166] Risk distribution map: displays the overall risk score distribution of data, helping decision makers identify areas with higher risks.
[0167] Furthermore, the report generation process is automated, with the system automatically generating and delivering reports periodically or in real-time when anomalies are detected. The reports include anomaly warnings, future forecasts, risk assessments, and decision-making recommendations.
[0168] Regular updates: Updated reports are generated after each financial period based on new, real-time data.
[0169] Dynamic feedback: When key anomalies or trend changes are detected, the system automatically updates the report and pushes it to decision makers.
[0170] Through the design of step S104, the present invention not only provides real-time anomaly warnings but also offers comprehensive decision support to decision makers by integrating future trend forecasts. This innovative report generation method combines anomaly detection, causal relationship diagram analysis, future trend forecasting, and comprehensive risk assessment, providing an efficient and systematic decision-making tool for financial management, helping to identify problems and take appropriate measures in a timely manner.
[0171] S105. Adaptively optimize the anomaly detection model and prediction model, and calculate the deviation between the current model and the historical model. When the deviation exceeds a preset threshold, the model update is automatically triggered. According to the changes in model parameters, the anomaly warning and decision support report is updated to generate the latest anomaly warning and decision support report.
[0172] Specifically, to ensure that the entire system can quickly respond to changes in the market or financial environment, the present invention designs an adaptive feedback mechanism. Large fluctuations, or risk scores When a predetermined threshold is exceeded, the system automatically triggers the model retraining process and updates the forecast results based on the latest financial data.
[0173] Furthermore, feedback mechanism: In the adaptive mechanism of the system, the present invention calculates the deviation of the current model To evaluate the accuracy of the model:
[0174] ;
[0175] Where N is the total number of nodes; and are the anomaly scores at time t and t-1, respectively.
[0176] when Exceeds a preset threshold , the system will automatically trigger the model update:
[0177] ;
[0178] This indicator function This ensures that the model's adaptive update mechanism is only activated when the abnormal score fluctuation exceeds the set threshold, ensuring computational efficiency.
[0179] Furthermore, as model parameters and forecast values change dynamically, the system will update reports and generate the latest risk assessments and decision recommendations. The adaptively optimized model not only provides more accurate anomaly warnings, but also adjusts decision recommendations based on the latest financial data. Strategy Adjustment:
[0180] Based on the results of adaptive optimization, the system automatically generates new decision recommendations. The adjusted strategy will take the following aspects into consideration:
[0181] Risk Threshold Adjustment: If the risk score Beyond a certain threshold, decision recommendations may require additional risk control measures (such as increasing financial reserves).
[0182] Forecast Trend Revision: If the future forecast value If a large fluctuation occurs, the system will revise the strategy recommendations based on the parameters optimized by the model.
[0183] Furthermore, the system will automatically perform the following operations after each financial period:
[0184] Model adaptive optimization: Automatically adjust model parameters based on real-time data and prediction results.
[0185] Report generation and optimization: Generate new decision support reports and provide the latest risk assessment and decision recommendations based on the optimized model.
[0186] Through this automated optimization mechanism, the system is able to ensure a high degree of flexibility and accuracy in an ever-changing financial environment.
[0187] Through the design of step S105, the entire system implements an adaptive update mechanism based on real-time feedback, ensuring that the prediction model and anomaly detection algorithm are automatically optimized based on the latest financial data. This not only improves the accuracy of anomaly detection but also provides decision makers with more precise risk assessment and decision support. Ultimately, the system can adapt to the rapidly changing financial environment and continuously provide effective decision support for enterprises.
[0188] Another embodiment of the present invention provides an artificial intelligence-based financial abnormal data analysis system, which includes the following modules:
[0189] The financial data acquisition module is used to collect the financial data to be identified, and build a dynamic data flow graph based on the financial data. The causal reasoning method is introduced into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. Whenever new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph. ,in Represents the node set at time t, each node Represents a financial indicator, Represents the edges connecting these nodes, and the edges represent the dependencies between indicators;
[0190] The dynamic data flow graph construction module is used to construct a causal reasoning model of the dynamic data flow graph based on the dynamic data flow graph using an adaptive causal reasoning method based on a sliding time window. In the causal reasoning model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to construct the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed.
[0191] In the causal reasoning model, when a node enters, a causal chain is generated for each node to describe the path of abnormal propagation:
[0192] For each node The present invention starts from this node and follows the edge in the dynamic data flow graph. Trace back and find all nodes that directly or indirectly affect it , forming a causal chain , which describes the chain from other indicators to The causal transmission path;
[0193] For each causal path , assign a weight to it , which is the product of the weights of all edges on the path:
[0194] ;
[0195] in, Reflects the shift from other indicators to The combined impact of For the edge, is the edge weight;
[0196] Sort all causal paths and select the top K strongest causal paths for subsequent anomaly detection;
[0197] The risk warning module is used to build anomaly detection models and prediction models. When there is real-time data stream input, the causal inference features of each node corresponding to the key features of the real-time data stream are extracted from the causal influence of the adjacent nodes in the dynamic data flow graph to represent the causal influence score of the node. The anomaly detection model determines whether an anomaly has occurred based on the causal influence score and its historical distribution. The prediction model makes predictions for future moments based on the current node.
[0198] A report generation module, configured to generate anomaly warning and decision support reports based on the output results of the anomaly detection model and the prediction model;
[0199] The system optimization module is used to adaptively optimize the anomaly detection model and prediction model, and calculate the deviation between the current model and the historical model. When the deviation exceeds a preset threshold, the model update is automatically triggered. According to the changes in model parameters, the anomaly warning and decision support report is updated to generate the latest anomaly warning and decision support report.
[0200] These are merely some preferred embodiments of the present invention, and certainly cannot be used to limit the scope of rights of the present invention. A person skilled in the art can understand that all or part of the processes of the above embodiments and equivalent changes made in accordance with the claims of the present invention still fall within the scope of the invention.
Claims
1. A method for analyzing abnormal financial data based on artificial intelligence, characterized in that: The method comprises the following steps: S101. Collect the financial data to be identified, construct a dynamic data flow graph based on the financial data, and introduce a causal reasoning method into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. When new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph. S102. Based on the dynamic data flow graph, a causal inference model of the dynamic data flow graph is constructed using an adaptive causal inference method based on a sliding time window. In the causal inference model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to form the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed. S103. Build an anomaly detection model and a prediction model. When a real-time data stream is input, extract the causal inference feature of each node from the causal influence of adjacent nodes in the dynamic data flow graph based on the key features of the real-time data stream, and represent the causal influence score of the node. The anomaly detection model determines whether an anomaly occurs based on the causal influence score and its historical distribution, and the prediction model makes predictions for future moments based on the current node; S104: Generate an anomaly warning and decision support report based on the output results of the anomaly detection model and the prediction model; S105. Adaptively optimize the anomaly detection model and the prediction model, and calculate the deviation between the current anomaly detection model and the current prediction model and the historical anomaly detection model and the historical prediction model. When the deviation exceeds a preset threshold, the model update is triggered, and the anomaly warning and decision support report is updated at the same time to generate the latest anomaly warning and decision support report.
2. The method for analyzing abnormal financial data based on artificial intelligence according to claim 1, characterized in that: The dynamic data flow graph is represented as ,in, Represents the node set at time t, each node Represents a financial indicator, Represents the edges connecting these nodes, and the edges represent the dependencies between indicators; The dynamic data flow graph is constructed as follows: Each financial indicator All as a node , so the node set , each node represents a specific financial indicator; Initially establish edge sets based on the correlation between financial indicators ; Among them, the correlation between the financial indicators is the node and The Pearson correlation coefficient between them is used to construct preliminary edges based on the Pearson correlation coefficient: If the absolute value of the Pearson correlation coefficient is greater than the set threshold, then at the node and Establish a preliminary boundary between , ,side Indicates a strong correlation between the two financial indicators.
3. The method for analyzing abnormal financial data based on artificial intelligence according to claim 2, characterized in that: The causal reasoning method is introduced to optimize the edge weights of the dynamic data flow graph, including: Estimate the causal relationship between two financial indicators through Granger causality analysis, including: For two financial indicators and If the financial indicators Financial indicators Has significant predictive power, then financial indicators Financial indicators have causal influence; The significant predictive ability is determined based on Granger causality analysis.
4. The method for analyzing abnormal financial data based on artificial intelligence according to claim 1, characterized in that: In S1, when the financial environment changes, the edges and weights in the dynamic data flow graph are dynamically adjusted by calculating new causal relationships each time and combining correlations. The weight changes of the edges in the graph are controlled by dynamic adjustment items, so that the graph structure can adapt to changes in real-time data.
5. The method for analyzing abnormal financial data based on artificial intelligence according to claim 1, characterized in that: In the causal reasoning model, when a node enters, a causal chain is generated for each node, describing the path of anomaly propagation: For each node , starting from this node, along the edge in the dynamic data flow graph Trace back and find all the nodes that affect it, forming a causal chain , which describes the chain from other financial indicators to The causal transmission path; For each causal path , assign a weight to it , where the weight is the product of the weights of all edges on the path: Sort all causal chains and select the top K strongest causal chains for subsequent anomaly detection; In the causal inference model that uses the adaptive causal inference method based on sliding time windows to construct a dynamic data flow graph, the financial data in the time series is divided into sliding windows of length T, and the data in each window is represented as ,in, Representation node For time series data at time t, the reasoning goal of setting causal relationships is to estimate the causal impact between various financial indicators through a regression model: Assume that within the window T, the financial indicators Subject to financial indicators The causal effect of is modeled through regression models; The causal relationship is quantified in each regression, and an L1 regularization term is introduced to suppress insignificant regression coefficients, thereby making the model more sparse and removing redundant causal chains.
6. The method for analyzing abnormal financial data based on artificial intelligence according to claim 1, characterized in that: Before building the anomaly detection model and prediction model, a sliding window mechanism is first used to monitor the changes in real-time data and extract key features. For each node , from adjacent nodes Extract the causal influence of , represents the causal influence score of the node.
7. The method for analyzing abnormal financial data based on artificial intelligence according to any one of claims 5 or 6, characterized in that: The anomaly detection model is constructed as follows: Collection Node Historical data, including nodes The mean and standard deviation of the past W moments, combined with the node The causal effect of the node is calculated by analyzing the standard deviation of the absolute difference between the causal effect and the mean. If the anomaly score is greater than the anomaly threshold, the node is considered There is an anomaly; The prediction model is constructed as follows: The causal strength estimated by the regression model is used as the node For Node The prediction coefficient of the node is used to establish a multivariate time series prediction model based on the causal relationship diagram and historical data. The observation values at time t are weighted and corrected using the prediction error to obtain the final node The predicted value of ; where the prediction error follows a normal distribution; At the same time, regularization terms are introduced into the anomaly detection model and the prediction model to prevent overfitting of the model and optimize its adaptability to historical data; The update mechanism of the anomaly detection model and prediction model is as follows: Whenever the system detects new data or anomalies, the anomaly detection model and the prediction model automatically adjust the weighting coefficients of causal influence , prediction coefficient and the threshold for anomaly scoring , so that the prediction and detection effects can adapt to new data patterns.
8. The method for analyzing abnormal financial data based on artificial intelligence according to claim 7, characterized in that: The S104 specifically includes: A. Generation of abnormal warning report: Based on the anomaly score of each node, the degree of anomaly of each node is calculated, which is measured based on the ratio of the anomaly score to the historical standard deviation of the node; According to the abnormality level of each node, the nodes are divided into different abnormality levels, including mild, moderate and severe abnormalities; Use a sliding window approach to calculate the duration of an abnormal event: In the past W time steps, if the node If the anomaly score of a node exceeds the threshold continuously, the anomaly is considered to be persistent. Based on the causal graph model, the impact of the anomaly on other related nodes is evaluated. By calculating the influence propagation between nodes, evaluating nodes Whether the abnormality will affect other key financial indicators; B. Decision support report generation: Based on predicted future values , showing the forecast trend of each financial indicator in the future, including the forecast value and the corresponding confidence interval; C. Combine the anomaly score, anomaly degree, and predicted future value to assess the risk level of the overall financial system through indicator function analysis; D. Provide specific response recommendations to decision makers based on risk levels.
9. The method for analyzing abnormal financial data based on artificial intelligence according to claim 1, characterized in that: The deviation calculation is the average absolute deviation of the anomaly scores at time t and t-1; when the average absolute deviation exceeds a preset threshold, the update of the anomaly detection model and the prediction model is automatically triggered.
10. An artificial intelligence-based financial abnormal data analysis system, characterized in that: The system includes the following modules: The financial data collection module is used to collect the financial data to be identified and construct a dynamic data flow graph based on the financial data. The causal reasoning method is introduced into the dynamic data flow graph to optimize the edge weights of the dynamic data flow graph. When new financial data flows in, the data in the sliding window is used to update the dynamic data flow graph. The dynamic data flow graph construction module is used to construct a causal reasoning model of the dynamic data flow graph based on the dynamic data flow graph using an adaptive causal reasoning method based on a sliding time window. In the causal reasoning model, regression coefficients are used to quantify the causal relationship between financial indicators, and the regression coefficients are used to construct the causal strength. An update strategy based on the regression results is used to update the edge weights of the data flow graph. At the same time, an edge weight threshold is designed. If the current edge weight is lower than the edge weight threshold, the edge is removed. The risk warning module is used to build anomaly detection models and prediction models. When there is real-time data stream input, it extracts the causal inference features of each node from the causal influence of adjacent nodes in the dynamic data flow graph based on the key features of the real-time data stream, and represents the causal influence score of the node. The anomaly detection model determines whether an anomaly occurs based on the causal influence score and its historical distribution, and the prediction model makes predictions for future moments based on the current node; A report generation module, configured to generate anomaly warning and decision support reports based on the output results of the anomaly detection model and the prediction model; The system optimization module is used to adaptively optimize the anomaly detection model and prediction model, and calculate the deviation between the current anomaly detection model and the current prediction model and the historical anomaly detection model and the historical prediction model. When the deviation exceeds a preset threshold, the model update is triggered, and the anomaly warning and decision support report is updated at the same time to generate the latest anomaly warning and decision support report.
Citation Information
Patent Citations
Financial integrated data management system and method based on cloud computing
CN118503881A
AI-based railway signal system abnormality detection and diagnosis method
KR102730303B1