A stock market abnormal event risk early warning method, system, device and medium

By identifying the moments of abnormal stock price movements, constructing non-single semantic time series graphs, and conducting in-depth feature mining, this approach solves the problems of ambiguous event attribution, semantic gaps in heterogeneous data, and insufficient dynamic evolution representation capabilities in traditional stock price fluctuation analysis, thereby achieving accurate early warning and real-time prevention and control of abnormal stock market risks.

CN122390867APending Publication Date: 2026-07-14SHENYANG UNIVERSITY OF TECHNOLOGY

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHENYANG UNIVERSITY OF TECHNOLOGY
Filing Date
2026-04-24
Publication Date
2026-07-14

AI Technical Summary

Technical Problem

Traditional stock price fluctuation analysis and risk prediction methods suffer from problems such as ambiguous event attribution, semantic gaps in heterogeneous data, information leakage in time series modeling, and insufficient dynamic evolution representation capabilities when facing complex and ever-changing stock market environments. These issues prevent them from meeting the accuracy and real-time requirements of financial risk prevention and control.

Method used

By acquiring time-series market data and news text data of target stocks, we identify moments of abnormal stock price movements. We use a triple-filtering mechanism model for data screening and event-level alignment to construct a non-single semantic time-series graph. We then use a non-single semantic time-series graph attention network for deep feature mining and representation learning to generate abnormal event prediction indicators for risk assessment.

Benefits of technology

It enables accurate identification of events driving stock price anomalies and accurate prediction of risk evolution, improving the real-time nature and practicality of stock market anomaly risk warnings, providing clear decision-making basis, and offering efficient and robust support for intelligent risk prevention and control in the stock market.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122390867A_ABST
    Figure CN122390867A_ABST
Patent Text Reader

Abstract

The application relates to a stock market abnormal event risk early warning method, system, device and medium, the method comprising: acquiring stock market quotation time series data and news message text data of a target stock, identifying a stock price abnormal time and intercepting an abnormal related time series segment set; screening associated message texts through a triple filtering mechanism model, aligning the associated message texts and the time series segment events to obtain an abnormal event sample set; constructing a non-single semantic time series graph, inputting the non-single semantic time series graph attention network to generate an abnormal event prediction index, and generating an abnormal risk early warning signal after threshold determination. The method can fuse stock market quotation time series and news public opinion multi-source heterogeneous data, identify stock price abnormal driving events and quantify abnormal risks, and support efficient and stable stock market intelligent risk prevention and control decisions.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of interdisciplinary technology of financial technology and artificial intelligence, and in particular relates to a method, system, device and medium for risk warning of abnormal events in the stock market. Background Technology

[0002] With the rapid development of intelligent risk prevention and control and quantitative analysis technologies in the financial market, multi-source data processing technologies for mining the driving factors of stock market price fluctuations and predicting abnormal risks have emerged.

[0003] Multi-source data processing technology for mining the driving factors of stock market price fluctuations and predicting abnormal risks is based on multi-dimensional heterogeneous data of the stock market. It mines the core events and dynamic mechanisms that drive stock price fluctuations, thereby enabling early identification of abnormal stock price fluctuations and accurate prediction of the direction of risk evolution. It is a core research direction in the field of financial risk prevention and control. At present, the industry mainly uses traditional time series statistical analysis and fixed rule event correlation methods to carry out related technology implementation.

[0004] In traditional techniques, the analysis and risk prediction of stock price fluctuations typically use a fixed time window as the basic unit. This involves extracting multi-source information such as macroeconomic policies, industry sector dynamics, individual stock fundamentals, market sentiment, and major capital transaction data within a specific period. All data within the window is then uniformly aggregated into related events driving the current stock price fluctuations. For the two types of heterogeneous data—numerical stock price time series data and text-based unstructured public opinion data—most methods involve simple concatenation after converting the text content into numerical features, or conducting statistical analysis and model building only on a single data dimension. In the time series feature modeling stage, static graph modeling is commonly used to compress complete abnormal events into fixed-dimensional feature vectors, thereby building a stock price fluctuation prediction and risk identification model.

[0005] However, current traditional methods for analyzing stock price fluctuations and predicting risks face several insurmountable technical obstacles in practical applications. They are ill-suited to the complex and ever-changing stock market environment and fail to meet the precision and real-time requirements of financial risk prevention and control. First, there is the issue of ambiguity in event attribution. A single news report may simultaneously impact multiple stocks, and the timeframe for the effect of such news on stock prices varies significantly. It may be quickly absorbed by the market or experience a delayed impact. Traditional technical solutions simply extract data and aggregate events according to time windows, leading to unclear semantic boundaries and problems such as ineffective merging of related events and confusion in the aggregation of independent events. This makes it impossible to match the true correlation between events and stock price fluctuations. Second, there is the semantic gap caused by data heterogeneity. Stock price trends are numerical time-series data, while news and public opinion are text-based unstructured data. The mathematical representation spaces of stock price trends and news and public opinion are completely different. Simply converting text into numerical features and then concatenating them, or analyzing only from a single dimension, fails to establish true deep semantic connections between heterogeneous data, significantly reducing the effectiveness of data mining. Third, there is an information leakage problem in time series modeling. Most existing prediction models are prone to unintentionally mixing in future information when building training samples. This often results in using news data after the anomaly has occurred to predict the current anomaly, causing the model to perform well in the laboratory environment but immediately fail once deployed to real-time prediction scenarios. Fourth, there is a problem of insufficient representation capability for dynamic evolution. The market environment is constantly changing, and anomalies evolve dynamically from their inception to their outbreak. The dominant driving factors at different stages are also constantly changing. Traditional static graph modeling compresses the entire event into a fixed-dimensional vector, losing the evolutionary details in the time dimension, and failing to accurately predict the direction of the event's risk evolution. Summary of the Invention

[0006] Based on this, it is necessary to address the aforementioned technical problems by providing a method, system, device, and medium for stock market anomaly risk early warning that can solve the core defects of traditional stock anomaly risk analysis technology, such as ambiguous event attribution, semantic gaps in heterogeneous data, information leakage in time series modeling, and insufficient dynamic evolution representation capabilities. This method should accurately identify key events driving stock price fluctuations from multi-source heterogeneous data and make effective predictions on the risk evolution direction of anomaly events.

[0007] Firstly, this application provides a method for early warning of stock market anomaly events, including:

[0008] S101. Obtain the market time series data and news text data of the target stock in the historical time period. Based on the market time series data, identify the time of abnormal stock price movement. Based on the time of abnormal stock price movement and the abnormality judgment sliding window, extract the set of time series segments related to the abnormality.

[0009] S102. Input the news message text data into the triple filtering mechanism model to obtain the set of related message text events, and perform event-level alignment on the set of time series segments related to the anomalies and the set of related message text events to obtain the sample set of anomaly events; among them, the set of related message texts and the set of time series segments related to anomalies are related in time and semantics.

[0010] S103. Based on the sample set of abnormal events, a non-single semantic temporal graph is constructed; wherein, the non-single semantic temporal graph is used to represent the non-single semantic association between objects in the sample set of abnormal events.

[0011] S104. Input the non-single semantic temporal graph into the non-single semantic temporal graph attention network to generate anomaly event prediction indicators.

[0012] S105. Based on the early warning threshold of the abnormal event prediction indicator, the abnormal event prediction indicator is used to determine the abnormal risk and generate abnormal risk determination result information. When the abnormal risk determination result information indicates that there is abnormal risk, an abnormal risk warning signal for the target stock is generated.

[0013] Secondly, this application also provides a stock market anomaly event risk early warning system, including:

[0014] The abnormal stock price segment extraction module is used to obtain the market time series data and news text data of the target stock in the historical time period. Based on the market time series data, it identifies the time of abnormal stock price movement and extracts a set of time series segments related to the abnormal stock price movement based on the time of abnormal stock price movement and the abnormal movement judgment sliding window.

[0015] The event alignment module is used to input news message text data into the triple filtering mechanism model to obtain a set of related message text events, and to perform event-level alignment between the set of time series fragments related to the anomalies and the set of related message text events to obtain a set of anomaly event samples; among them, the set of related message texts and the set of time series fragments related to anomalies are related in time and semantics.

[0016] The semantic temporal graph construction module is used to construct non-single semantic temporal graphs based on the sample set of abnormal events; wherein, the non-single semantic temporal graph is used to represent the non-single semantic associations between objects in the sample set of abnormal events.

[0017] The anomaly prediction module is used to input non-single semantic time series graphs into a non-single semantic time series graph attention network to generate anomaly event prediction metrics.

[0018] The risk warning module is used to determine the abnormal event prediction index based on the abnormal event prediction index warning threshold, generate abnormal event risk determination result information, and generate an abnormal event risk warning signal for the target stock when the abnormal event risk determination result information indicates that there is abnormal event risk.

[0019] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to implement the steps of any of the methods described above.

[0020] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any of the methods described above.

[0021] The aforementioned method, system, device, and medium for risk warning of stock market anomalies acquire historical time-series data of market prices and news text data of the target stock. It identifies moments of price anomalies and extracts a set of time-series segments related to the anomalies based on these moments and a sliding window for anomaly judgment. This allows for locking in the core time-series data range for subsequent anomaly event correlation analysis and risk prediction, anchoring the time boundary corresponding to the price anomalies. This solves the problems of ambiguous event time attribution and lack of clear benchmarks for data extraction in traditional techniques, laying a time-series foundation for subsequent multi-source data correlation analysis. Furthermore, a triple-filtering mechanism model performs multi-stage screening of the news text data to obtain time-series data related to the anomalies. This method generates a set of related message text events that are doubly associated in both time and semantics. By aligning the set of time-series fragments related to abnormal price movements with the set of related message text events at the event level, a sample set of abnormal price events is obtained. This effectively filters irrelevant public opinion information, merges overlapping related events, and matches the attribution relationship between stock price abnormality time-series fragments and their corresponding driving events. This addresses the core pain points of unclear event semantic boundaries and confused aggregation of related events in traditional techniques, and achieves event-level matching between numerical time-series data and text-based public opinion data. Based on the sample set of abnormal price events, a non-single semantic time-series graph is constructed to represent the non-single semantic associations between objects in the sample set, enabling the analysis of time-series market trends within abnormal price events. Transforming data and news text into a unified graph structure breaks down representational barriers between heterogeneous data. Through the characterization of non-single semantic associations, it fully preserves the complex relationships between multiple objects in anomaly events, addressing the limitations of traditional static graph modeling in terms of semantic simplicity and insufficient capacity to represent complex relationships. This avoids the loss of details in the evolution of anomaly events and provides complete structured data support for subsequent deep feature mining and risk prediction. Furthermore, by employing a dedicated graph attention network for deep feature mining and representation learning on non-single semantic time-series graphs, it captures the association weights and dynamic evolution patterns between different objects in anomaly events. This effectively integrates time-series statistical features and textual semantic features, resolving the semantic challenges of heterogeneous data in traditional techniques. This method addresses the issues of insufficient capacity to represent gaps and dynamic evolution, improving the accuracy and reliability of anomaly event prediction. Based on the warning threshold of anomaly event prediction indicators, it assesses anomaly risk and generates anomaly risk assessment results. When the assessment result indicates the presence of anomaly risk, it generates an anomaly risk warning signal for the target stock. This allows for the quantitative assessment and tiered warning of anomaly risk based on accurate prediction indicators, providing timely and effective risk warning signals. It offers clear decision-making basis for anomaly risk prevention and control in the stock market, achieving a complete technical closed loop from multi-source data fusion, event correlation matching, deep feature learning to accurate risk prediction and warning, thus improving the real-time performance and practicality of stock market anomaly risk warnings. This method can integrate multi-source heterogeneous data from stock market time series and news sentiment to identify stock price anomaly driving events and quantify anomaly risks, supporting efficient and robust intelligent risk prevention and control decisions in the stock market. Attached Figure Description

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

[0023] Figure 1 A flowchart illustrating a risk warning method for abnormal stock market events, provided as an exemplary embodiment of this application;

[0024] Figure 2 This is a schematic diagram of the structure of a stock market abnormal event risk early warning system provided as an exemplary embodiment of this application. Detailed Implementation

[0025] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0026] In one embodiment, such as Figure 1 As shown, a method for risk warning of abnormal events in the stock market is provided. This embodiment illustrates the application of this method to a risk warning terminal. It is understood that this method can also be applied to a risk warning server, and can also be applied to a system including a risk warning terminal and a risk warning server, and implemented through the interaction between the risk warning terminal and the risk warning server. In this embodiment, the method may include the following steps:

[0027] S101. Obtain the market time series data and news text data of the target stock in the historical period. Based on the market time series data, identify the time of abnormal stock price movement. Based on the time of abnormal stock price movement and the abnormality judgment sliding window, extract the set of time series segments related to the abnormality.

[0028] Optionally, the time series data of the target stock's market performance over a historical period can be used to characterize the price trend changes and trading activity of the target stock over a historical period.

[0029] Optionally, obtaining news text data of the target stock within a historical time period can be used to characterize various event-driven information and market sentiment content that drive fluctuations in the target stock price.

[0030] Optionally, there can be one or more stock price fluctuation moments. When there is only one stock price fluctuation moment, the set of time series segments related to the fluctuation can contain only one element. When there is no stock price fluctuation moment, the set of time series segments related to the fluctuation can be an empty set.

[0031] Specifically, the risk warning terminal can acquire full-volume market data and news text data of the target stock according to historical statistical time ranges and data collection granularity. Secondly, the risk warning terminal can preprocess the full-volume market data and news text data of the target stock to obtain preprocessed full-volume market data and news text data.

[0032] Preferably, the preprocessing of the risk warning terminal for full market time series data and news message text data may include the following steps:

[0033] S1011. Preprocess the full volume of market data time series.

[0034] Preferably, the risk warning terminal can complete missing values ​​and clean outliers in the full market time series data to obtain market basic data that is continuous in time and compliant in value, and then convert the continuous in time and compliant market basic data into an equally spaced time series.

[0035] Furthermore, the risk warning terminal can use the Z-score standardization method to eliminate the differences in data of different dimensions in equally spaced time series, thereby obtaining preprocessed market time series data.

[0036] S1012. Preprocess the news message text data.

[0037] Preferably, the risk warning terminal can perform basic text cleaning and invalid text filtering on the news message text data to obtain financial news basic text data with standardized format and valid content. It can also perform time-series attribute standardization and text structuring on the financial news basic text data with standardized format and valid content to obtain preprocessed news message text data.

[0038] Furthermore, the risk warning terminal can perform continuous sliding traversal calculations on the preprocessed market time series data based on the anomaly amplitude threshold and the anomaly judgment sliding window, and calculate the maximum stock price amplitude within each anomaly judgment sliding window using the following formula:

[0039]

[0040] In the formula, Indicates the first The maximum price fluctuation of the target stock corresponding to each anomaly detection sliding window. Indicates the first Preprocessed target stock market time series data for each anomaly detection sliding window. Indicates the first The maximum value of the target stock's time series data within the sliding window for anomaly detection. Indicates the first The minimum value of the target stock's time series data within the sliding window for anomaly detection.

[0041] Furthermore, the risk warning terminal can compare the maximum price fluctuation within the obtained anomaly judgment sliding window with the anomaly amplitude threshold. When the maximum price fluctuation within the anomaly judgment sliding window is greater than or equal to the anomaly amplitude threshold, the risk warning terminal can mark the midpoint of the extreme point of the price within the anomaly judgment sliding window as the price anomaly moment. Further, the risk warning terminal can use each identified price anomaly moment as a benchmark, and based on the preset preceding and following data lengths of the cold start phase, determine the start and end time range of the time series segment corresponding to each anomaly moment. Based on the start and end time range, it can extract the data segment corresponding to the start and end time range from the preprocessed market time series data to obtain a single anomaly-related time series segment.

[0042] Furthermore, the risk warning terminal can extract time series segments from multiple abnormal stock price movements identified within a historical time period, and aggregate all time series segments to generate a set of time series segments related to the abnormal movements.

[0043] S102. Input the news message text data into the triple filtering mechanism model to obtain the set of related message text events, and perform event-level alignment on the set of time series segments related to the anomalies and the set of related message text events to obtain the sample set of anomaly events.

[0044] Optionally, the associated message text set and the set of time series fragments related to contract changes can be associated both temporally and semantically.

[0045] Optionally, the abnormal event sample set can be used to represent a collection of multiple standardized abnormal event samples of a target stock over a historical period. Each abnormal event sample in the sample set can correspond to a single instance of abnormal stock price movement in the target stock.

[0046] Optionally, the triple filtering mechanism model can be a hierarchical filtering model that is serially cascaded. The triple filtering mechanism model can consist of a same-label filter, a temporal overlap merger, and a temporal adjacency filter.

[0047] Optionally, the construction of a triple filtering mechanism model may include the following steps:

[0048] S1021. Construct a filter with the same label.

[0049] For example, the risk warning terminal can construct a standardized multi-level tag system for target stocks. The multi-level tag system for target stocks can adopt a three-level classification architecture, which can be a stock-specific tag layer, a sector-related tag layer, and a global impact tag layer. Each level includes predefined standardized tag generation rules and keyword mapping relationships.

[0050] Furthermore, the risk warning terminal can construct a dual-path label matching algorithm architecture. The first path in this architecture can be a regularized keyword precision matching algorithm, and the terminal can predefine regularization expression rules and matching priority logic for multi-pattern matching. The second path can be a semantic similarity matching algorithm. The terminal can logically integrate the dual-path label matching algorithms, encapsulate the functionality of the same-label filter, and perform matching accuracy verification and parameter optimization of the same-label filter based on a historical financial news annotation dataset.

[0051] S1022, Construct a time-overlapping merger.

[0052] For example, the risk warning terminal can predefine a standardized news message time sequence attribute extraction rule system. The news message time sequence attribute extraction rule system can serve as the basic processing benchmark for the time sequence overlap merging unit. The news message time sequence attribute extraction rule system may include, but is not limited to, standardized extraction rules for publication timestamps and quantitative determination rules for the effective period of events.

[0053] Furthermore, the risk warning terminal can construct a serialized temporal overlap processing algorithm architecture. The first stage of the temporal overlap processing algorithm architecture can be a temporal overlap detection and clustering algorithm. The risk warning terminal can predefine sliding window traversal rules, time interval overlap calculation methods, and clustering judgment logic for related events based on the principle of time interval intersection determination. The second stage of the temporal overlap processing algorithm architecture can be an overlapping event merging processing algorithm. The risk warning terminal can predefine semantic aggregation rules, temporal range merging logic, and standardized event unit encapsulation format for related message texts within the same cluster.

[0054] Furthermore, the risk warning terminal can logically integrate the temporal attribute extraction rule system and the serialized temporal overlap processing algorithm architecture to encapsulate the function of the temporal overlap merger. Based on the historically labeled financial news event dataset, it can complete the event clustering accuracy verification, merging rule adaptability adjustment, and core parameter optimization of the temporal overlap merger.

[0055] S1023. Construct a time adjacency filter and complete the serial cascade solidification of the triple filtering mechanism model.

[0056] For example, the risk warning terminal can construct an adaptive quantization model of adjacent time range based on statistical distribution as the judgment criterion for time adjacency filters. The risk warning terminal can use the adaptive quantization model of adjacent time range, based on kernel density estimation, to predefine the input specifications of historical abnormal event samples, the construction logic of message-abnormal time lag sequences, kernel function selection rules, adaptive calculation methods for bandwidth parameters, and quantile extraction logic for effective time boundaries. Based on the full historical abnormal event data of the target stock, it adaptively fits the time lag distribution characteristics of message release and stock price abnormalities, and quantifies and outputs the effective adjacent time range of the corresponding abnormal time series segments.

[0057] Furthermore, the risk warning terminal can predefine the compliance judgment rules for the release time and adjacent time range of message event units, the filtering logic for effectively related message events, and the standardized output format, accurately filter the time dimension of message event units after time-series merging, and eliminate noisy message events that have no effective time dimension correlation with abnormal stock price movements.

[0058] Furthermore, the risk warning terminal can, under the functional encapsulation of the time adjacency filter, integrate the cascade of the same-label filter, time-series overlap merger, and time adjacency filter according to the serial processing order of the same-label filter, time-series overlap merger, and time adjacency filter. It predefines the input specifications of the results of the preceding processing layer to the subsequent processing layer, the logic for intercepting and processing abnormal data, and the standardized output format of the final associated message text event set. It can then construct and solidify the triple filtering mechanism model as a whole, and perform end-to-end performance verification and full-process parameter tuning of the triple filtering mechanism model based on the historical full market data and news text dataset of the target stock.

[0059] Specifically, the risk warning terminal can input pre-processed news message text data into a triple filtering mechanism model. The triple filtering mechanism model performs multi-stage progressive filtering on the pre-processed news message text data and outputs a set of related news message text events that have correlation attributes with the abnormal stock price movement of the target stock.

[0060] Furthermore, the risk warning terminal can use the stock price fluctuation time corresponding to each time series segment in the set of abnormal fluctuation related time series segments as the abnormal fluctuation time benchmark anchor point for the time series segment, and divide the effective time range of each time series segment based on the abnormal fluctuation time benchmark anchor point. The risk warning terminal can traverse all event units in the set of associated message text events, and initially match event units whose publication time falls within the effective time range to the associated event set of the time series segment.

[0061] Based on this, the risk warning terminal can extract the semantic vector of market fluctuation features corresponding to the time series segment, as well as the text semantic vector of the preliminarily matched related event unit, and calculate the semantic similarity between the semantic vector of market fluctuation features and the text semantic vector of the preliminarily matched related event unit. When the semantic similarity reaches the semantic matching threshold, it is determined that the event unit and the corresponding time series segment have a strong semantic relationship.

[0062] Furthermore, the risk warning terminal can encapsulate standardized event units based on each set of time series segments that have achieved initial alignment in the time dimension and precise matching in the semantic dimension, as well as the unique associated message text event corresponding to each set of time series segments that have achieved initial alignment in the time dimension and precise matching in the semantic dimension. This generates a single abnormal event sample with a complete structure and a clear mapping relationship. The risk warning terminal can traverse all time series segments within the set of abnormal event-related time series segments, perform matching verification and encapsulation processing on all time series segments within the set of abnormal event-related time series segments, and summarize all single abnormal event samples that conform to the specifications to generate a standardized abnormal event sample set.

[0063] S103. Based on the abnormal event sample set, a non-single semantic temporal graph is constructed.

[0064] Optionally, non-single semantic time sequence diagrams can be used to characterize non-single semantic associations between objects in a sample set of anomaly events.

[0065] Specifically, the risk warning terminal can define each time series segment within each individual abnormal event sample in the abnormal event sample set as a time series graph node, extract five types of statistical features corresponding to each time series graph node: root mean square, mean absolute value, wavelength, maximum fractal length, and average power, and use these five types of statistical features as the initial features of the time series graph node.

[0066] Furthermore, the risk warning terminal can define each message text within a single abnormal event sample as a message graph node, perform semantic vectorization encoding on each message text, and obtain message semantic features as the initial node features of the message graph node.

[0067] Furthermore, the risk warning terminal can use the time of stock price fluctuation corresponding to the abnormal event sample as the time reference point, calculate the time difference between the time sequence graph nodes and the message graph nodes, and construct the initial edge weights between nodes to obtain an initial fully connected graph structure. The risk warning terminal can remove message graph nodes in the initial fully connected graph structure whose publication time is later than the time of stock price fluctuation, resulting in a non-single semantic time sequence graph.

[0068] S104. Input the non-single semantic time sequence graph into the non-single semantic time sequence graph attention network to generate anomaly event prediction indicators.

[0069] Optionally, the non-single semantic temporal graph attention network can be a dedicated graph neural network architecture adapted to the heterogeneous node features and association structure design of non-single semantic temporal graphs. The non-single semantic temporal graph attention network can learn the weight distribution of non-single semantic associations between nodes, extract the temporal evolution features of the entire cycle of the anomaly event, and output a quantifiable comprehensive representation of the anomaly risk.

[0070] Optionally, the non-single semantic temporal graph attention network can be trained using an end-to-end supervised learning approach, with a set of positive and negative samples of historically labeled abnormal events as training data, and the parameters of the non-single semantic temporal graph attention network iteratively optimized using binary cross-entropy loss as the objective function.

[0071] Optionally, the abnormal event prediction indicators may include, but are not limited to, quantitative values ​​predicting the probability and magnitude of abnormal stock price movements.

[0072] Optionally, the probability of abnormal stock price fluctuations can be used to characterize the likelihood that the target stock will experience abnormal price fluctuations that meet the fluctuation magnitude threshold within the prediction time window.

[0073] Optionally, the quantitative value of the abnormal fluctuation amplitude prediction can be used to characterize the maximum estimated value of the target stock's price fluctuation within the prediction time window, and the quantitative value of the abnormal fluctuation amplitude prediction can be used to quantify the potential impact of abnormal events on the target stock price.

[0074] Specifically, the risk warning terminal can perform standardized preprocessing on non-single semantic temporal graphs, verifying the integrity of the graph structure, the dimensional standardization of node features, and the validity of edge weight data. Invalid graph data with structural anomalies or missing features is eliminated, generating standardized graph structure data that conforms to the input specifications of non-single semantic temporal graph attention networks. The risk warning terminal can then input this standardized graph structure data into a non-single semantic temporal graph attention network that has undergone training and parameter fixing. Through hierarchical feature processing and deep representation learning within the non-single semantic temporal graph attention network, it achieves unified mapping of heterogeneous node features, adaptive learning of inter-node association weights, and aggregation and extraction of core driving features of abnormal events. This captures the evolutionary patterns and multi-dimensional association features of abnormal events over time.

[0075] Furthermore, the risk warning terminal can use a fully connected layer of a non-single semantic temporal graph attention network to perform nonlinear mapping and quantification of the evolutionary patterns and multi-dimensional correlation features in the time dimension, generating quantitative values ​​for predicting the probability and magnitude of abnormal stock price movements.

[0076] S105. Based on the early warning threshold of the abnormal event prediction indicator, the abnormal event prediction indicator is used to determine the abnormal risk and generate abnormal risk determination result information. When the abnormal risk determination result information indicates that there is abnormal risk, an abnormal risk warning signal for the target stock is generated.

[0077] Optionally, the abnormal event prediction indicator warning threshold can be used to characterize a quantitative critical judgment benchmark for distinguishing whether a target stock has abnormal fluctuation risk.

[0078] Optionally, the warning threshold of the abnormal event prediction indicator can be obtained by adaptive quantification using non-parametric statistical methods based on the statistical distribution characteristics of the historical abnormal event samples of the target stock. The warning threshold of the abnormal event prediction indicator can be divided into two dimensions: the critical threshold for the probability of abnormality and the critical threshold for the magnitude of abnormality. The critical threshold for the probability of abnormality and the critical threshold for the magnitude of abnormality can correspond one-to-one with the core components of the abnormal event prediction indicator.

[0079] Specifically, the risk warning terminal can use historical full-volume abnormal event sample data of the target stock to fit the probability distribution characteristics of abnormal event prediction indicators through kernel density estimation, and combine it with preset quantile rules to quantify and generate critical thresholds for the probability of abnormal events and the magnitude of abnormal events. The risk warning terminal can compare the generated abnormal event prediction indicators with the warning thresholds of the corresponding dimensions of the abnormal event prediction indicators item by item. When the value of any dimension of the abnormal event prediction indicators reaches or exceeds the corresponding warning threshold, an abnormal event risk judgment result is generated, indicating that there is an abnormal event risk; otherwise, an abnormal event risk judgment result is generated, indicating that there is no abnormal event risk.

[0080] Furthermore, when the abnormal stock risk assessment result indicates the existence of abnormal stock risk, the risk warning terminal can integrate the target stock's security identification information, the quantitative results of abnormal event prediction indicators, and related driving event information to generate a standardized abnormal stock risk warning signal.

[0081] In the aforementioned stock market anomaly event risk warning method, the risk warning terminal acquires historical market time series data and news text data of the target stock, identifies the moment of stock price anomaly, and extracts a set of time series segments related to the anomaly based on the moment of the anomaly and the anomaly judgment sliding window. This can lock in the core time series data range for subsequent anomaly event correlation analysis and risk prediction, anchoring the time boundary corresponding to the stock price anomaly. This solves the problems of ambiguous event time attribution and lack of clear benchmark for data extraction in traditional technologies, laying a time series foundation for subsequent multi-source data correlation analysis. Furthermore, a triple filtering mechanism model is used to perform multi-stage screening of the news text data to obtain the time series related to the anomaly. This dataset, a set of related message text events with dual temporal and semantic associations, aligns the time-series fragments and related message text events at the event level to obtain a sample set of abnormal events. This effectively filters irrelevant public opinion information, merges overlapping related events, and matches the attribution relationships between stock price abnormality time-series fragments and their corresponding driving events. This addresses the core pain points of unclear event semantic boundaries and confused aggregation of related events in traditional technologies, and achieves event-level matching between numerical time-series data and text-based public opinion data. Based on the sample set of abnormal events, a non-single semantic time-series graph is constructed to represent the non-single semantic associations between objects in the sample set, enabling the analysis of time-series market data within abnormal events. Transforming news text data into a unified graph structure breaks down representation barriers between heterogeneous data. Through the characterization of non-single semantic associations, it fully preserves the complex relationships between multiple objects in anomaly events, solving the problems of limited semantic depth and insufficient ability to represent complex relationships in traditional static graph modeling. This avoids the loss of details in the evolution of anomaly events and provides complete structured data support for subsequent deep feature mining and risk prediction. Furthermore, by using a dedicated graph attention network to perform deep feature mining and representation learning on non-single semantic time-series graphs, it captures the association weights and dynamic evolution patterns between different objects in anomaly events. This effectively integrates time-series statistical features and textual semantic features, solving the semantic problems of heterogeneous data in traditional techniques. This method addresses the issues of insufficient capacity to represent gaps and dynamic evolution, improving the accuracy and reliability of anomaly event prediction. Based on the warning threshold of anomaly event prediction indicators, it assesses anomaly risk and generates anomaly risk assessment results. When the assessment result indicates the presence of anomaly risk, it generates an anomaly risk warning signal for the target stock. This allows for the quantitative assessment and tiered warning of anomaly risk based on accurate prediction indicators, providing timely and effective risk warning signals. It offers clear decision-making basis for anomaly risk prevention and control in the stock market, achieving a complete technical closed loop from multi-source data fusion, event correlation matching, deep feature learning to accurate risk prediction and warning, thus improving the real-time performance and practicality of stock market anomaly risk warnings. This method can integrate multi-source heterogeneous data from stock market time series and news sentiment to identify stock price anomaly driving events and quantify anomaly risks, supporting efficient and robust intelligent risk prevention and control decisions in the stock market.

[0082] In one embodiment, constructing a non-single semantic temporal graph based on an anomaly event sample set may include the following steps:

[0083] S201. Define each time series segment of each abnormal event sample in the abnormal event sample set as a time series graph node, extract the statistical features of each time series graph node, and use the statistical features as the initial node features of the time series graph node.

[0084] Optionally, the initial features of the nodes in the time series graph can be used to characterize the stock price fluctuation patterns, abnormal precursor features, and time series distribution attributes within the corresponding time series segment of the target stock. The initial features of the nodes in the time series graph can be the basic numerical features for constructing a non-single semantic time series graph.

[0085] For example, the risk warning terminal can first traverse all individual abnormal event samples in the abnormal event sample set, perform unique identification and standardization preprocessing on the independent time series segments within each abnormal event sample, and define each preprocessed time series segment as an independent time series graph node. The risk warning terminal can then calculate five statistical characteristics—root mean square, mean absolute value, wavelength, maximum fractal length, and average power—for the time series segment corresponding to each time series graph node.

[0086] Optionally, the root mean square and average power can be used to characterize the overall fluctuation energy of a time series segment, the average absolute value can be used to characterize the average fluctuation amplitude of a time series segment, the wavelength can be used to characterize the trend change rate of a time series segment, and the maximum fractal length can be used to characterize the nonlinear fluctuation complexity of a time series segment.

[0087] Furthermore, the risk warning terminal can combine five types of statistical features in dimensional order to generate the initial node features of the corresponding time series graph nodes.

[0088] S202. Define each message text of each abnormal event sample as a message graph node, perform semantic vectorization encoding on each message text to obtain message semantic features, and use the message semantic features as the initial node features of the message graph node.

[0089] Optionally, message semantic features can be used to characterize the core semantic connotation, event type attributes, market sentiment and stock price impact logic of the message text corresponding to the abnormal event. Message semantic features can be high-dimensional numerical representations obtained after standardizing and transforming unstructured news message text.

[0090] For example, the risk warning terminal can traverse all individual abnormal event samples in the abnormal event sample set, uniquely identify and preprocess the independent message text within each abnormal event sample, and obtain preprocessed message texts. The risk warning terminal can define each preprocessed message text as an independent message graph node, perform semantic vectorization encoding on each message text, and extract the context semantic vector corresponding to each message text. The risk warning terminal can perform dimensionality standardization mapping on the context semantic vectors to generate fixed-dimensional message semantic features, and use these message semantic features as the initial node features of the corresponding message graph nodes.

[0091] S203. Using the time of abnormal stock price movement as the time reference point for the time series graph node, calculate the time difference between the time series graph node and the message graph node, and construct the initial edge weights between nodes based on the time difference to obtain the initial fully connected graph structure.

[0092] Optionally, the time difference can be used to quantify the time lag relationship between message events corresponding to message graph nodes and market fluctuations corresponding to time series graph nodes.

[0093] Optionally, the initial fully connected graph structure can be a fully connected graph structure consisting of all time-series graph nodes and message graph nodes within a single abnormal event sample as a vertex set, with weighted directed edges established between any two different vertices. The initial fully connected graph structure may include, but is not limited to, the potential relationships between all market fluctuation objects and message event objects within the abnormal event.

[0094] For example, the risk warning terminal can use the time of stock price fluctuation corresponding to a single abnormal event sample as the only time reference point, extract the center time of the time series segment corresponding to each time series graph node and the release time of the message text corresponding to each message graph node, and calculate the time difference between the time series graph node and the message graph node, between different time series graph nodes, and between different message graph nodes.

[0095] Furthermore, the risk warning terminal can convert time differences into initial edge weights between nodes based on a time decay weight function. The smaller the absolute value of the time difference, the larger the initial edge weight between the corresponding nodes. The risk warning terminal can traverse all time-series graph nodes and message graph nodes within the current abnormal event sample, establish connection edges with initial edge weights for any two different independent nodes, and construct an initial fully connected graph structure.

[0096] S204. Remove all message graph nodes whose release time is later than the time of stock price fluctuation to obtain a non-single semantic time sequence graph.

[0097] Optionally, a non-single semantic sequence graph can be used to characterize the multi-dimensional non-single semantic relationships between sequence graph nodes and message graph nodes within the compliant time sequence range of a single abnormal event sample.

[0098] For example, the risk warning terminal can traverse all message graph nodes in the initial fully connected graph structure, extract the standardized release time of the message text corresponding to each message graph node one by one, compare the standardized release time of the message text corresponding to each message graph node with the time of stock price fluctuation corresponding to the current abnormal event sample, and filter out all message graph nodes whose release time is later than the time of stock price fluctuation.

[0099] Furthermore, the risk warning terminal can remove all message graph nodes whose release time is later than the time of stock price fluctuation, delete all connection edges associated with message graph nodes later than the time of stock price fluctuation in the initial fully connected graph structure, and generate a non-single semantic time sequence graph.

[0100] In this embodiment, the risk warning terminal defines the time series segments and message texts in the abnormal event samples as time series graph nodes and message graph nodes, respectively. It extracts the statistical features of time series nodes and the semantic features of message nodes as the initial features of nodes. It calculates the time difference between nodes based on the time of stock price abnormality and constructs a fully connected graph structure. It also removes message graph nodes whose release time is later than the time of stock price abnormality, thus constructing a non-single semantic time series graph that can uniformly represent heterogeneous data, eliminate semantic gaps, and ensure temporal causal consistency.

[0101] In one embodiment, defining each time series segment of each abnormal event sample in the abnormal event sample set as a time series graph node, extracting the statistical features of each time series graph node, and using the statistical features as the initial node features of the time series graph node may include the following steps:

[0102] S301. Perform root mean square (RMS) calculation on the time series segments corresponding to the nodes in the time series graph to obtain the RMS features.

[0103] Optionally, the root mean square feature can be used to characterize the overall volatility energy and dispersion of time series data. The root mean square feature can quantify the overall volatility amplitude and volatility energy level of the target stock price within the corresponding time window.

[0104] For example, the risk warning terminal can obtain the standardized preprocessed time series segment corresponding to the time series graph node, traverse all market data points within the standardized preprocessed time series segment, perform a square operation on the value of each market data point, calculate the arithmetic mean of all squared values, and perform a square root operation on the arithmetic mean to obtain the root mean square feature.

[0105] S302. Calculate the average absolute value of the time series segments corresponding to the nodes in the time series diagram to obtain the average absolute value feature.

[0106] Optionally, the average absolute value feature can be used to characterize the average volatility of the target stock within a corresponding time window.

[0107] For example, the risk warning terminal can calculate the absolute difference between each data point and the zero value based on all data points in the time series segment corresponding to the time series graph node, obtain the absolute fluctuation value of each data point, and perform an arithmetic average of all absolute fluctuation values ​​to obtain the average absolute value feature.

[0108] S303. Calculate the wavelength of the time series segment corresponding to the node in the time series diagram to obtain the wavelength characteristics.

[0109] Optionally, wavelength characteristics can be used to characterize the frequency and volatility of trend changes in a target stock within a corresponding time window.

[0110] For example, the risk warning terminal can traverse all consecutive data point pairs within the time series segment corresponding to the time series graph node, calculate the absolute value of the price difference between two adjacent data points in turn, and sum up the absolute differences of all adjacent data points to obtain the wavelength feature.

[0111] S304. Calculate the maximum fractal length of the time series segments corresponding to the nodes in the time series diagram to obtain the maximum fractal length feature.

[0112] Optionally, the maximum fractal length feature can be used to quantify the irregularity of stock price fluctuations.

[0113] For example, the risk warning terminal can extract all consecutive adjacent data points within the time series segment corresponding to the time series graph node, calculate the price difference between each group of adjacent data points, sum the squares of all differences, perform a square root operation on the summation result, and take the logarithm of the square root value to the base 10 to obtain the maximum fractal length feature.

[0114] S305. Calculate the average power of the time series segments corresponding to the nodes in the time series diagram to obtain the average power characteristics.

[0115] Optionally, the average power feature can be used to characterize the overall average volatility energy of time series data, reflecting the average volatility energy level of the target stock within the corresponding time window from the energy domain dimension.

[0116] For example, the risk warning terminal can obtain all market data points within the time series segment corresponding to the time series graph node, perform a square operation on the value of each market data point, calculate the arithmetic mean of all squared values, and obtain the average power characteristic of the time series segment.

[0117] S306. The initial node features are constructed by combining the root mean square feature, the mean absolute value feature, the wavelength feature, the maximum fractal length feature, and the average power feature.

[0118] Optionally, the risk warning terminal can perform dimensional splicing on multi-dimensional statistical features to construct an initial feature vector of nodes with a unified dimension, thereby obtaining a complete multi-dimensional numerical representation of the time series graph nodes.

[0119] Furthermore, the risk warning terminal can sequentially acquire the root mean square feature, mean absolute value feature, wavelength feature, maximum fractal length feature, and average power feature corresponding to the same time series graph node. The risk warning terminal can horizontally splice the root mean square feature, mean absolute value feature, wavelength feature, maximum fractal length feature, and average power feature according to the feature dimension order to obtain a fixed-dimensional multi-dimensional feature vector. The risk warning terminal can use the multi-dimensional feature vector as the initial node feature of the time series graph node.

[0120] Preferably, the expression for the initial features of a node can be:

[0121]

[0122]

[0123]

[0124]

[0125]

[0126]

[0127] In the formula, Indicates the first The first abnormal event sample Initial node features of time series graph nodes corresponding to each time series segment Indicates the first The first abnormal event sample Root mean square features of time series graph nodes corresponding to each time series segment Indicates the first The first abnormal event sample The average absolute value characteristics of time series graph nodes corresponding to each time series segment. Indicates the first The first abnormal event sample Wavelength characteristics of time series graph nodes corresponding to each time series segment Indicates the first The first abnormal event sample The maximum fractal length feature of time series graph nodes corresponding to each time series segment. Indicates the first The first abnormal event sample Average power characteristics of time series graph nodes corresponding to each time series segment. Indicates the first The first abnormal event sample A time series segment, Indicates the first The first abnormal event sample The first time series segment Data points, Indicates the first The first abnormal event sample The total number of data points in a time series segment.

[0128] In this embodiment, the risk warning terminal extracts five statistical features—root mean square, average absolute value, wavelength, maximum fractal length, and average power—from the time series segments corresponding to the time series nodes in the time series graph and combines them into an initial feature vector for the nodes. This enables a comprehensive numerical representation of stock price time series data across multiple dimensions, providing accurate basic feature inputs that reflect the energy, amplitude, rate of change, and complexity of fluctuations for subsequent construction of non-single semantic time series graphs and prediction of abnormal risk.

[0129] In one embodiment, inputting news message text data into a triple filtering mechanism model to obtain a set of associated message text events may include the following steps:

[0130] S401. Using the same-label filter, based on the keyword information of the target stock, filter out the message texts that belong to the same label as the target stock in the news message text data, and obtain the same-label message set.

[0131] Optionally, the tags may include, but are not limited to, stock tags, probability tags, and sector tags.

[0132] Optionally, the same-label message set can be used to represent a set of news message texts that have label association attributes with the target stock in the dimensions of individual stock, sector, and global impact.

[0133] For example, the same-tag filter can use the predefined multi-level tag system of the target stock as the screening benchmark, and adopt a dual-path screening mechanism that combines keyword precise matching and semantic similarity matching to filter the entire news message text by tag dimension.

[0134] Furthermore, the same-tag filter can load a standardized tag system corresponding to the target stock. Stock tags can correspond to the target stock's unique keywords, concept tags can correspond to market hot topics related to the target stock, and sector tags can correspond to keywords such as the target stock's industry classification and regional sector. The same-tag filter can traverse the entire dataset of news message text data to be processed. The first path of the same-tag filter's dual-path filtering mechanism can identify message texts with tag keywords corresponding to the target stock through regularized keyword matching. The second path of the same-tag filter's dual-path filtering mechanism can calculate the semantic similarity between the message text and the target stock's tag system, filtering out message texts that meet the semantic matching criteria.

[0135] Furthermore, the same-label filter can merge the results of dual-path filtering, remove duplicate message text, and generate a set of messages with the same label after completing the label matching validity verification.

[0136] S402. Using a time-overlapping merger, detect and merge message texts with overlapping time ranges in the message set with the same label to obtain a time-overlapping message set with the same label.

[0137] Optionally, the same-label time-series merged message set can be used to characterize the standardized event unit set formed after merging and deduplicating related events with the same origin and overlapping time sequences in the same-label message set.

[0138] For example, the time-series overlap merger can take a set of messages with the same label as input and perform serial processing logic based on time interval intersection determination and semantic verification of the same source event to complete the detection and merging of time-series overlap messages.

[0139] Furthermore, the time-series overlap merger can traverse each message text in the message set with the same label, extracting the standardized publication timestamp and the effective time interval of the event for each message. The time-series overlap merger can use a sliding window traversal mechanism to detect the time intervals of all message texts and identify message text clusters with overlapping time intervals. For each cluster, the time-series overlap merger can verify the event homology of message texts within the cluster by calculating semantic similarity. After confirming related messages belonging to the same driving event, the time-series overlap merger performs event-level merging of message texts within the cluster and integrates the semantic content and time interval of the messages to obtain a standardized single event unit.

[0140] Furthermore, the time-overlapping merger can perform time integrity and semantic uniqueness checks on the merged event units, remove redundant and duplicate event units, and generate a set of time-overlapping messages with the same label.

[0141] S403. Using a time adjacency filter, based on the time window of the time series fragment set related to the anomaly, retain the message texts in the time series merged message set with the same label whose publication time is within the adjacent time range, and obtain the associated message text set.

[0142] For example, the time adjacency filter can traverse the set of time series segments related to abnormal fluctuations, extract the complete time window corresponding to each time series segment, and use the time of stock price fluctuation corresponding to each segment as the benchmark anchor point to determine the start and end boundaries of the adjacent time range corresponding to each time window.

[0143] Furthermore, the time adjacency filter can traverse all message texts within the time-series merged message set with the same label, extract the standardized publication timestamp of each message text one by one, and perform time sequence compliance verification on the standardized publication timestamp of each message text and the adjacent time range of the corresponding abnormal time series segment. Only message texts whose standardized publication timestamps fall completely within the adjacent time range are retained, irrelevant messages that exceed the time boundary are removed, and the retained message texts are deduplicated and verified for compliance, generating a set of associated message texts.

[0144] In this embodiment, the risk warning terminal uses a serially cascaded triple filtering mechanism model to progressively filter news message text data in terms of tag dimensions, time sequence dimensions, and time adjacency dimensions. This can solve the core pain points of traditional technologies, such as ambiguous event attribution, redundant irrelevant noise data, unclear event semantic boundaries, and future information leakage. It filters out a set of related message text events that are effectively related to the abnormal stock price movement of the target stock in terms of tag attributes, time sequence correlation, and causal logic. This provides basic data support for time sequence compliance for subsequent event-level alignment of abnormal time sequence fragments and message events, as well as the construction of non-single semantic time sequence diagrams.

[0145] In one embodiment, inputting a non-single semantic temporal graph into a non-single semantic temporal graph attention network to generate anomaly event prediction metrics may include the following steps:

[0146] S501. The statistical features of the time sequence graph nodes and the message semantic features of the message graph nodes are mapped to the same dimension space through the projection layer to obtain the initial feature matrix of the nodes.

[0147] Optionally, a non-single semantic sequence graph attention network may include a projection layer, a non-single semantic sequence graph attention layer, a global pooling layer, and a fully connected layer.

[0148] Optionally, the initial feature matrix of a node can be used to characterize the standardized feature set generated after the temporal graph nodes and message graph nodes are mapped to a unified dimension.

[0149] For example, the projection layer can design dedicated linear mapping branches for different types of nodes, mapping heterogeneous features of different dimensions to the same dimensional space. The projection layer can receive the time-series graph node statistical features and message graph node message semantic features input from the risk warning terminal, perform linear transformations on the time-series statistical features and text semantic features respectively, map the time-series statistical features and text semantic features to the same dimensional feature space, and perform dimensional consistency verification on all node features that have completed the dimensional unification mapping, and arrange them in order according to the unique identifier of the node, generating a dimensionally unified and structurally standardized initial node feature matrix, which is then output to the subsequent non-single semantic time-series graph attention layer.

[0150] S502. Through a non-single semantic temporal graph attention layer, the original attention scores between nodes are calculated based on the initial feature matrix of the nodes. The original attention scores are then biased and corrected based on the time difference between the nodes to obtain the final attention coefficients. The neighbor node features in the initial feature matrix of the nodes are then weighted and aggregated according to the final attention coefficients to obtain the updated node feature matrix.

[0151] Optionally, the final attention coefficient can be used to characterize the importance of the association between pairs of nodes in a non-single semantic sequence graph.

[0152] Optionally, the updated node feature matrix can be used to characterize the set of node features that incorporate neighbor node association information and temporal association features after being aggregated by attention weights. The features of each node in the updated node feature matrix can carry its own basic attributes and the influence information of related nodes in the whole graph.

[0153] For example, the non-single semantic temporal graph attention layer can receive the initial node feature matrix output by the projection layer, and calculate the original attention score between all distinct independent node pairs within the non-single semantic temporal graph based on the node feature vectors. The non-single semantic temporal graph attention layer can extract the time difference between the standardized temporal attributes corresponding to the two nodes in each independent node pair participating in the calculation of the original attention score, calculate the temporal bias term based on the time decay function, and perform bias correction on the original attention score to obtain the final attention coefficient.

[0154] Furthermore, the non-single semantic temporal graph attention layer can perform weighted aggregation of the features of each node's neighboring nodes based on the final attention coefficients, and update the feature vector of each node to generate an updated node feature matrix.

[0155] S503. The feature matrix of the updated node is subjected to max pooling and average pooling through the global pooling layer to obtain the max pooling vector and the average pooling vector. The max pooling vector and the average pooling vector are then concatenated to obtain the global representation vector.

[0156] Optionally, the max pooling vector can be used to characterize the core extreme value features in the full node features of a non-single semantic time series graph, capture the strong driving signals that have the most significant impact on stock price fluctuations in abnormal events, retain the core driving features of abnormal events, and filter out irrelevant weak noise information.

[0157] Optionally, the average pooling vector can be used to characterize the overall distribution features of all nodes in a non-single semantic temporal graph.

[0158] Optionally, the global representation vector can be used to represent a high-dimensional aggregated representation of the full information of a non-single semantic temporal graph.

[0159] For example, the global pooling layer can receive the updated node feature matrix output by the attention layer of a non-single semantic temporal graph. The max pooling path in the global pooling layer can perform max pooling, taking the maximum value of all node features in the feature dimension to generate a max pooling vector. The average pooling path in the global pooling layer can perform average pooling, calculating the arithmetic mean of all node features in the feature dimension to generate an average pooling vector.

[0160] Furthermore, the global pooling layer can horizontally concatenate the max pooling vector and the average pooling vector along the feature dimension. After feature validity verification, a global representation vector is generated and output to the fully connected layer.

[0161] S504. By performing a nonlinear mapping on the global representation vector through a fully connected layer, an abnormal event prediction index is generated.

[0162] For example, the fully connected layer can receive the global representation vector output by the global pooling layer, perform a first-order nonlinear mapping on the global representation vector through the first fully connected network, and use a linear rectified function as the activation function to enhance the network's ability to fit nonlinear correlations.

[0163] Furthermore, the fully connected layer can perform a second-order mapping and dimensional compression on the global representation vector through the second fully connected network, mapping the high-dimensional feature vector to the prediction output dimension. The high-dimensional feature vector can correspond to the quantitative values ​​of the probability and magnitude of the target stock price fluctuation, respectively. The second fully connected network is standardized and constrained by the Sigmoid activation function to generate anomaly event prediction indicators.

[0164] In this embodiment, the risk warning terminal uses a non-single semantic temporal graph attention network to sequentially perform dimensional unification mapping of heterogeneous node features, adaptive learning of attention weights incorporating temporal associations, graph-level global feature aggregation, and quantitative prediction of anomaly risks. This breaks down the representation barriers between temporal statistical features and textual semantic features, fully preserves the temporal evolution associations and non-single semantic association information of anomaly events, and significantly improves the accuracy and generalization ability of anomaly event prediction indicators.

[0165] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0166] Based on the same inventive concept, this application also provides a stock market anomaly event risk warning system for implementing the aforementioned stock market anomaly event risk warning method. The solution provided by this system is similar to the implementation scheme described in the above method; therefore, the specific limitations of one or more embodiments of the stock market anomaly event risk warning system provided below can be found in the limitations of the stock market anomaly event risk warning method described above, and will not be repeated here.

[0167] In one exemplary embodiment, such as Figure 2 As shown, a stock market anomaly event risk early warning system 600 is provided, including:

[0168] The abnormal movement segment extraction module 601 can be used to obtain the market time series data and news text data of the target stock in the historical time period. Based on the market time series data, it can identify the time of abnormal stock price movement and extract the set of abnormal time series segments based on the time of abnormal stock price movement and the abnormal movement judgment sliding window.

[0169] The event alignment module 602 can be used to input news message text data into the triple filtering mechanism model to obtain a set of related message text events, and perform event-level alignment between the set of time series fragments related to the anomalies and the set of related message text events to obtain a set of anomaly event samples; wherein, the set of related message texts and the set of time series fragments related to anomalies are related in time and semantics.

[0170] The semantic temporal graph construction module 603 can be used to construct a non-single semantic temporal graph based on the sample set of abnormal events; wherein, the non-single semantic temporal graph is used to represent the non-single semantic association between objects in the sample set of abnormal events.

[0171] The anomaly prediction module 604 can be used to input non-single semantic time sequence graphs into a non-single semantic time sequence graph attention network to generate anomaly event prediction indicators.

[0172] The risk warning module 605 can be used to determine the abnormal event prediction index based on the abnormal event prediction index warning threshold, generate abnormal event risk determination result information, and generate an abnormal event risk warning signal for the target stock when the abnormal event risk determination result information indicates that there is abnormal event risk.

[0173] In one embodiment, the semantic sequence graph construction module includes:

[0174] The time series node construction unit can be used to define each time series segment of each abnormal event sample in the abnormal event sample set as a time series graph node, extract the statistical features of each time series graph node, and use the statistical features as the initial node features of the time series graph node;

[0175] The message node construction unit can be used to define each message text of each abnormal event sample as a message graph node, perform semantic vectorization encoding on each message text to obtain message semantic features, and use the message semantic features as the initial node features of the message graph node.

[0176] The time-series edge construction unit can be used to calculate the time difference between time-series graph nodes and message graph nodes with the time of abnormal stock price fluctuation as the time reference point, and construct the initial edge weights between nodes based on the time difference to obtain the initial fully connected graph structure.

[0177] The future information masking unit can be used to remove all message graph nodes whose release time is later than the time of stock price fluctuation, resulting in a non-single semantic time sequence graph.

[0178] In one embodiment, the timing node construction unit includes:

[0179] The root mean square feature extraction subunit can be used to perform root mean square calculation on the time series segments corresponding to the nodes in the time series graph to obtain root mean square features;

[0180] The mean absolute value feature extraction subunit can be used to calculate the mean absolute value of the time series segments corresponding to the nodes in the time series graph, and obtain the mean absolute value feature.

[0181] The wavelength feature extraction subunit can be used to calculate the wavelength of the time series segment corresponding to the time series node in the time series diagram to obtain the wavelength feature;

[0182] The maximum fractal length feature extraction subunit can be used to calculate the maximum fractal length of the time series segments corresponding to the nodes in the time series graph, and obtain the maximum fractal length feature.

[0183] The average power feature extraction subunit can be used to calculate the average power of the time series segments corresponding to the nodes in the time series graph, and obtain the average power features.

[0184] The feature combination sub-unit can be used to combine root mean square features, mean absolute value features, wavelength features, maximum fractal length features, and average power features to construct the initial features of the nodes.

[0185] In one embodiment, the event alignment module includes:

[0186] The same-tag filtering unit can be used to filter out message texts that belong to the same tag as the target stock in news message text data based on the keyword information of the target stock, and obtain a set of messages with the same tag;

[0187] The time-overlapping merging unit can be used to detect and merge message texts with overlapping time ranges in the message set with the same label through the time-overlapping merging unit, so as to obtain the time-overlapping merged message set with the same label;

[0188] The time adjacency filtering unit can be used to retain message texts whose publication time is within the adjacent time range in the time window of the time series fragment set related to the anomaly, and obtain the associated message text set.

[0189] In one embodiment, the anomaly prediction module 604 can also be used for:

[0190] The statistical features of the time sequence graph nodes and the message semantic features of the message graph nodes are mapped to the same dimensional space through the projection layer to obtain the initial feature matrix of the nodes;

[0191] Through a non-single semantic temporal graph attention layer, the original attention scores between nodes are calculated based on the initial feature matrix of the nodes. The original attention scores are then biased and corrected based on the time difference between the nodes to obtain the final attention coefficients. The neighbor node features in the initial feature matrix of the nodes are then weighted and aggregated according to the final attention coefficients to obtain the updated node feature matrix.

[0192] The feature matrix of the updated node is subjected to max pooling and average pooling through a global pooling layer to obtain max pooling vector and average pooling vector. The max pooling vector and average pooling vector are then concatenated to obtain the global representation vector.

[0193] By performing a nonlinear mapping on the global representation vector through a fully connected layer, an abnormal event prediction index is generated.

[0194] In one embodiment, a computer device is provided, including a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the steps of the stock market abnormal event risk warning method as described above.

[0195] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps in the above method embodiments.

[0196] For the device embodiments, since they basically correspond to the method embodiments, the relevant parts can be referred to in the description of the method embodiments. The device embodiments described above are merely illustrative. The components described as separate parts may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this disclosure according to actual needs. Those skilled in the art can understand and implement this without creative effort.

[0197] The above-described embodiments are merely illustrative of several implementation methods of the embodiments of this application, and their descriptions are relatively specific and detailed. However, they should not be construed as limiting the scope of the patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the embodiments of this application, and these modifications and improvements all fall within the protection scope of the embodiments of this application.

Claims

1. A method for early warning of stock market anomaly events, characterized in that, The method includes: S101. Obtain the market time series data and news text data of the target stock in the historical time period. Based on the market time series data, identify the time of abnormal stock price movement. Based on the time of abnormal stock price movement and the abnormality judgment sliding window, extract the set of time series segments related to the abnormality. S102. Input the news message text data into the triple filtering mechanism model to obtain the set of related message text events, and perform event-level alignment between the set of anomaly-related time series segments and the set of related message text events to obtain the anomaly event sample set; wherein, the set of related message texts is temporally and semantically related to the set of anomaly-related time series segments. S103. Based on the abnormal event sample set, a non-single semantic time sequence diagram is constructed; wherein, the non-single semantic time sequence diagram is used to characterize the non-single semantic association between objects in the abnormal event sample set. S104. Input the non-single semantic temporal graph into the non-single semantic temporal graph attention network to generate an abnormal event prediction index. S105. Based on the abnormal event prediction indicator warning threshold, the abnormal event prediction indicator is used to determine the abnormal event risk, and abnormal event risk determination result information is generated. When the abnormal event risk determination result information indicates that there is abnormal event risk, an abnormal event risk warning signal for the target stock is generated.

2. The method according to claim 1, characterized in that, The construction of a non-single semantic time sequence graph based on the abnormal event sample set includes: S201. Define each time series segment of each abnormal event sample in the abnormal event sample set as a time series graph node, extract the statistical features of each time series graph node, and use the statistical features as the node initial features of the time series graph node; S202. Define each message text of each abnormal event sample as a message graph node, perform semantic vectorization encoding on each message text to obtain message semantic features, and use the message semantic features as the initial node features of the message graph node. S203. Using the time of the abnormal stock price movement as the time reference point of the time sequence graph node, calculate the time difference between the time sequence graph node and the message graph node, and construct the initial edge weights between nodes based on the time difference to obtain the initial fully connected graph structure. S204. Remove all message graph nodes whose publication time is later than the time of the stock price fluctuation to obtain the non-single semantic time sequence graph.

3. The method according to claim 2, characterized in that, The statistical features include root mean square feature, mean absolute value feature, wavelength feature, maximum fractal length feature, and average power feature; The step of defining each time series segment of each abnormal event sample in the abnormal event sample set as a time series graph node, extracting statistical features of each time series graph node, and using the statistical features as the initial node features of the time series graph node includes: S301. Perform root mean square calculation on the time series segments corresponding to the time series nodes in the time series graph to obtain the root mean square features; S302. Calculate the average absolute value of the time series segments corresponding to the nodes in the time series diagram to obtain the average absolute value feature. S303. Perform wavelength calculation on the time series segment corresponding to the time series node of the time series graph to obtain the wavelength feature; S304. Calculate the maximum fractal length of the time series segment corresponding to the time series node in the time series diagram to obtain the maximum fractal length feature. S305. Calculate the average power of the time series segments corresponding to the time series nodes in the time series diagram to obtain the average power characteristics; S306. Combine the root mean square feature, the mean absolute value feature, the wavelength feature, the maximum fractal length feature, and the average power feature to construct the initial node feature; The expression for the initial features of the node is: In the formula, Indicates the first The first of the aforementioned abnormal event samples The initial node features of the time series graph nodes corresponding to the time series segments. Indicates the first The first of the aforementioned abnormal event samples The root mean square feature of the time series graph nodes corresponding to the time series segments. Indicates the first The first of the aforementioned abnormal event samples The average absolute value feature of the time series graph nodes corresponding to each of the time series segments. Indicates the first The first of the aforementioned abnormal event samples The wavelength characteristics of the time series graph nodes corresponding to the time series segments. Indicates the first The first of the aforementioned abnormal event samples The maximum fractal length feature of the time series graph nodes corresponding to the time series segments. Indicates the first The first of the aforementioned abnormal event samples The average power characteristics of the time series graph nodes corresponding to each of the time series segments. Indicates the first The first abnormal event sample A time series segment, Indicates the first The first abnormal event sample The first time series segment Data points, Indicates the first The first abnormal event sample The total number of data points in each time series segment.

4. The method according to claim 1, characterized in that, The triple filtering mechanism model includes a same-label filter, a temporal overlap merger, and a temporal adjacency filter; The step of inputting the news message text data into the triple filtering mechanism model to obtain a set of related message text events includes: S401. Based on the keyword information of the target stock, the same-label filter filters out message texts belonging to the same label as the target stock from the news message text data, and obtains a set of messages with the same label. S402. The time-overlapping merger detects and merges message texts in the same-label message set whose time ranges overlap, to obtain the same-label time-overlapping message set. S403. Using the time adjacency filter, based on the time window of the abnormal time series fragment set, retain the message texts in the same-label time-series merged message set whose publication time is within the adjacent time range, to obtain the associated message text set.

5. The method according to claim 1, characterized in that, The non-single semantic temporal graph attention network includes a projection layer, a non-single semantic temporal graph attention layer, a global pooling layer, and a fully connected layer: The step of inputting the non-single semantic temporal graph into a non-single semantic temporal graph attention network to generate anomaly event prediction metrics includes: S501. The statistical features of the time sequence graph nodes and the message semantic features of the message graph nodes are mapped to the same dimensional space through the projection layer to obtain the initial feature matrix of the nodes. S502. Through the non-single semantic temporal graph attention layer, the original attention scores between nodes are calculated based on the initial feature matrix of the nodes. The original attention scores are then biased and corrected based on the time difference between the nodes to obtain the final attention coefficients. The neighbor node features in the initial feature matrix of the nodes are then weighted and aggregated according to the final attention coefficients to obtain the updated node feature matrix. S503. Max pooling and average pooling are performed on the feature matrix of the updated node through the global pooling layer to obtain a max pooling vector and an average pooling vector, and the max pooling vector and the average pooling vector are concatenated to obtain a global representation vector. S504. The global representation vector is nonlinearly mapped through the fully connected layer to generate the abnormal event prediction index.

6. A stock market anomaly event risk early warning system, characterized in that, The system includes: The abnormal stock segment extraction module is used to acquire market time series data and news text data of the target stock within a historical time period. Based on the market time series data, it identifies the time of abnormal stock price movement and extracts a set of abnormal time series segments based on the time of abnormal stock price movement and the abnormal judgment sliding window. The event alignment module is used to input the news message text data into the triple filtering mechanism model to obtain a set of related message text events, and to perform event-level alignment between the set of anomaly-related time series segments and the set of related message text events to obtain an anomaly event sample set; wherein, the set of related message texts is temporally and semantically related to the set of anomaly-related time series segments. A semantic temporal graph construction module is used to construct a non-single semantic temporal graph based on the abnormal event sample set; wherein, the non-single semantic temporal graph is used to represent the non-single semantic association between objects in the abnormal event sample set. Anomaly prediction module is used to input the non-single semantic time sequence graph into a non-single semantic time sequence graph attention network to generate anomaly event prediction index. The risk warning module is used to determine the abnormal event prediction index based on the abnormal event prediction index warning threshold, generate abnormal event risk determination result information, and generate an abnormal event risk warning signal for the target stock when the abnormal event risk determination result information indicates that there is abnormal event risk.

7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 5.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 5.