Investment market trend intelligent analysis and prediction platform based on machine learning

Through the intelligent analysis and prediction platform for investment market trends based on machine learning, the problem of difficulty in mining the value of multi-dimensional data and risk-return balance is solved, accurate prediction and strategic optimization of investment market trends are achieved, and portfolio selection is provided for risk-return balance.

CN120450870APending Publication Date: 2025-08-08QILIAN INFORMATION TECHNOLOGY CO LTD
View PDF 0 Cites 3 Cited by

Patent Information

Application Number
CN202510529494.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-25
Publication Date
2025-08-08

AI Technical Summary

Technical Problem

The existing investment market trend analysis methods are difficult to fully explore the value of multi-dimensional data, and cannot effectively capture the nonlinear and non-stationary characteristics of financial time series data. In addition, the investment strategy generation method lacks a balance between risks and returns, and it is difficult to find the optimal balance point between multiple conflicting goals.

Method used

The investment market trend intelligent analysis and prediction platform based on machine learning is adopted, and multi-dimensional financial timing data is obtained through the data acquisition module. The feature processing module generates a spatio-temporal correlation feature matrix. The deep prediction model construction module uses a hierarchical attention mechanism to predict, and combines segmented prediction and anomaly detection, prediction result correction, hybrid integration model and investment strategy generation module to optimize the decision-making module for multi-objective optimization.

Benefits of technology

It improves the accuracy and stability of investment market trend forecasts, can promptly detect data abnormalities, provide investment strategies with risk-return balance, help investors optimize asset allocation and reduce investment risks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120450870A_ABST
    Figure CN120450870A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of financial investment analysis and prediction, and discloses an investment market trend intelligent analysis and prediction platform based on machine learning. The data acquisition module acquires multi-dimensional financial time series data, and a space-time correlation feature matrix is generated through the feature processing module and is used for training a depth prediction model based on a hierarchical attention mechanism. The segmentation prediction and anomaly detection module carries out segmentation processing and anomaly detection, and the prediction result correction module corrects an abnormal window prediction result. The hybrid integrated model module fuses multiple models to generate market trend probability distribution, the investment strategy generation module constructs a risk-income balance strategy, and the optimization decision module determines an optimal investment portfolio. The platform can accurately analyze and predict an investment market trend, generates a reasonable investment strategy, assists investors in optimizing decisions, reduces risks, and improves benefits.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of financial investment analysis and prediction, and in particular to an investment market trend intelligent analysis and prediction platform based on machine learning. Background Art

[0002] In the financial investment sector, accurately predicting investment market trends is crucial for investors to make sound decisions and achieve desired returns. However, traditional investment market trend analysis methods face numerous difficulties.

[0003] In the early days, investors relied heavily on fundamental analysis, assessing asset values and market trends by studying macroeconomic data, company financial statements, and other information. However, this approach has significant flaws, ignoring the influence of factors such as market sentiment and investor psychology. For example, during periods of market panic or excessive optimism, investor sentiment can have a far greater impact on asset prices than fundamental factors, making it difficult to accurately grasp market trends based solely on fundamental analysis.

[0004] Technical analysis subsequently emerged, using various technical indicators and chart patterns to predict market trends by studying historical price and trading volume data. However, technical analysis relies solely on the surface characteristics of historical data and fails to delve deeper into the complex relationships and underlying patterns. Furthermore, the financial market is a highly complex and dynamic system, influenced by a variety of factors, including the macroeconomic environment, policies and regulations, industry competition, and unexpected events. The intertwined and interdependent nature of these factors makes predicting market trends extremely difficult.

[0005] With the advent of the big data era, data volumes are exploding. Financial markets are generating massive amounts of multi-dimensional data, such as investment discussions on social media, news information, and other sentiment-driven data. However, traditional methods struggle to effectively integrate and analyze this multi-source, heterogeneous data, hindering the full realization of its value.

[0006] In the early days of machine learning technology, simple machine learning models, such as linear regression models and decision trees, were applied to investment market forecasts. These models exhibited limitations when processing complex financial data and were unable to effectively capture the nonlinear and non-stationary characteristics of financial time series data.

[0007] The emergence of deep learning technology has brought new opportunities for financial market forecasting, but existing deep learning-based forecasting models still face challenges when processing multidimensional financial data. For one thing, they lack sufficient depth in exploring the correlations between features across different data sources, failing to fully leverage the complementary information within multidimensional data. Furthermore, during model training, it is difficult to adjust model parameters in real time based on market dynamics, resulting in limited adaptability and generalization capabilities.

[0008] Furthermore, existing investment strategy generation methods are often overly simplistic and fail to adequately consider the balance between risk and return. Some strategies pursue high returns while ignoring potential risks, while others are overly conservative and fail to achieve effective asset appreciation. Furthermore, the lack of scientifically sound multi-objective optimization methods in portfolio optimization makes it difficult to find the optimal balance between multiple conflicting objectives. Summary of the Invention

[0009] The purpose of the present invention is to provide an investment market trend intelligent analysis and prediction platform based on machine learning to solve the problems raised in the above background technology.

[0010] To achieve the above objectives, the present invention provides the following technical solution: an investment market trend intelligent analysis and prediction platform based on machine learning, the platform comprising:

[0011] Data acquisition module: used to obtain multi-dimensional financial time series data in real time, including historical prices, trading volumes, macroeconomic indicators, and social media sentiment polarity data;

[0012] Feature processing module: normalizes the multi-dimensional financial time series data acquired by the data acquisition module and inputs it into a preset feature fusion module to generate a spatiotemporal correlation feature matrix;

[0013] Deep prediction model construction module: uses the spatiotemporal correlation feature matrix generated by the feature processing module to train a deep prediction model based on a hierarchical attention mechanism. The model includes a temporal feature extraction layer, a cross-modal attention layer, and a dynamic weight allocation layer. The temporal feature extraction layer uses a bidirectional long short-term memory network to extract implicit patterns in historical sequences. The cross-modal attention layer is used to calculate the feature correlation between different data sources. The dynamic weight allocation layer adjusts the contribution weight of each feature dimension according to market volatility.

[0014] Segmented prediction and anomaly detection module: The input data is segmented using an adaptive sliding window mechanism. The data in each window is generated through the deep prediction model of the deep prediction model construction and training module to generate preliminary trend prediction results, and the local anomaly index of the data in the window is simultaneously calculated.

[0015] Preferably, the platform further comprises:

[0016] Prediction result correction module: This module filters abnormal windows in the segmented prediction and anomaly detection module based on a preset abnormal threshold, and inputs the preliminary trend prediction results corresponding to the abnormal windows into a preset correction module. The correction module dynamically adjusts the prediction results through the Q-learning strategy combined with historical correction feedback data to generate an optimized trend prediction value.

[0017] Hybrid integration model module: Inputs the optimized trend forecast value generated by the forecast result correction module and real-time market data into the hybrid integration model, which is composed of a gradient boosting decision tree, a variational autoencoder, and a graph convolutional network in parallel to generate the final market trend probability distribution;

[0018] Investment strategy generation module: constructs a risk-return equilibrium strategy based on the probability distribution generated by the hybrid integrated model module, generates multiple portfolio paths through Monte Carlo simulation, and calculates the Sharpe ratio and maximum drawdown index of each path;

[0019] Optimization decision module: uses a non-dominated sorting genetic algorithm to perform multi-objective optimization on the investment portfolio path generated by the investment strategy generation module, outputs a Pareto front solution set, and determines the optimal investment portfolio configuration plan through a fuzzy comprehensive evaluation method.

[0020] Preferably, the specific steps of the feature fusion module generating the spatiotemporal correlation feature matrix are:

[0021] For the normalized historical price and trading volume data, multi-scale frequency domain features are extracted through wavelet transform and tensor splicing is performed with the lagged terms of macroeconomic indicators;

[0022] Utilize graph neural networks to construct an asset association topology graph, where nodes represent different asset categories and edge weights are determined based on cointegration coefficients. Graph embedding algorithms are used to generate asset association feature vectors.

[0023] The social media sentiment polarity data is converted into a sentiment density matrix through a word embedding model, and is fused with the frequency domain features and asset association feature vectors through three-dimensional convolution to output a spatiotemporal association feature matrix.

[0024] Preferably, the calculation process of the cross-modal attention layer is specifically as follows:

[0025] Assume that the input data source includes the historical price series X p , trading volume sequence X v , macroeconomic indicator series X m and sentiment polarity sequence X s , are mapped to high-dimensional space through independent fully connected layers to obtain the feature vector H p ,H v ,H m ,H s ;

[0026] Calculate the cross-modal correlation matrix Among them, H i ,H j is the eigenvector of different modes, W ais the trainable parameter matrix, i,j∈{p,v,m,s};

[0027] Perform weighted aggregation on the feature vector of each data source: H′ i =∑ j A ij H j , output cross-modal fusion features {H′ p ,H′ v ,H′ m ,H′ s}.

[0028] Preferably, the calculation method of the local abnormality index is:

[0029] For the data in the window W k , calculate its Mahalanobis distance Where μ is the mean vector of the sliding window data, Σ is the covariance matrix;

[0030] Defining abnormality where μ D is the mean Mahalanobis distance of the historical window, σ D is its standard deviation;

[0031] If O k >γ, where γ is the dynamically adjusted threshold, then the window W k Mark the window as abnormal.

[0032] Preferably, the Q-learning strategy of the reinforcement learning correction module is specifically:

[0033] Define the state space S as the combination of the forecast error distribution of the abnormal window and the market volatility, and the action space A as the addition and subtraction adjustments to the forecast value;

[0034] Reward function R(s,a) = -λ|P adjusted -P real |+η·VolatilityAlignment, where λ,η are weight coefficients, P adjusted is the adjusted predicted value, P real is the actual value, VolatilityAlignment is a measure of the consistency between the predicted direction and the market volatility direction;

[0035] The Q-value table is updated iteratively through the Bellman equation until convergence, and the action that maximizes the Q-value is selected to correct the prediction result.

[0036] Preferably, the hybrid integration model is constructed as follows:

[0037] The gradient boosting decision tree receives the optimized trend prediction value and generates a decision rule set in a recursive splitting manner;

[0038] The variational autoencoder encodes real-time market data into a latent space and generates a latent variable distribution through sampling using a reparameterization technique;

[0039] The graph convolutional network aggregates neighborhood node information based on the asset association topology graph and outputs graph structural features;

[0040] The outputs of the three are gated and fused.

[0041] Preferably, the optimization process of the non-dominated sorting genetic algorithm is:

[0042] Initialize the population, each chromosome encodes a portfolio weight vector;

[0043] Calculate the individual Sharpe ratio and maximum drawdown objective function values, and divide the frontier level by fast non-dominated sorting;

[0044] A tournament selection mechanism is used to screen parent individuals, and the offspring population is generated by simulating binary crossover and polynomial mutation;

[0045] The parent and child populations are merged and reordered, retaining the first N individuals to enter the next generation of iteration until the termination condition is reached.

[0046] Preferably, the implementation steps of the fuzzy comprehensive evaluation method are:

[0047] Construct the evaluation factor set U = {Sharpe ratio, maximum drawdown, liquidity}, and the comment set V = {excellent, good, fair, poor};

[0048] The membership function and weight vector W = (w1, w2, w3) of each factor are determined by the expert scoring method, where w1, w2, and w3 are the weights of the Sharpe ratio, maximum drawdown, and liquidity, respectively;

[0049] Calculate the fuzzy comprehensive evaluation matrix R for each solution in the Pareto front solution set and synthesize the final evaluation value in For the fuzzy synthesis operator, the solution corresponding to the maximum membership is selected as the optimal configuration.

[0050] Preferably, the method for constructing the asset association topology map is:

[0051] Calculate the correlation strength based on the cointegration relationship of the historical returns of assets, assuming that the cointegration coefficient of assets i and j is ρ ij , then the edge weight e ij =|ρ ij |;If ρ ij >θ, then the edge is retained and Gaussian kernel smoothing is applied, where θ is the significance threshold;

[0052] The ForceAtlas2 algorithm is used to optimize the layout of the topology map and generate a visual asset association network.

[0053] Compared with the prior art, the present invention has the following beneficial effects:

[0054] In terms of data processing and feature extraction, the data acquisition module acquires multi-dimensional financial time series data in real time, covering historical prices, trading volumes, macroeconomic indicators, and social media sentiment data. This enables the platform to comprehensively understand investment market conditions from multiple perspectives. The feature processing module normalizes this data and, through complex operations, generates a spatiotemporal correlation feature matrix. Specifically, a wavelet transform is applied to historical price and trading volume data to extract multi-scale frequency domain features. This is combined with the features of lagged macroeconomic indicators and social media sentiment data, and then fused using three-dimensional convolution to fully exploit the temporal and spatial correlations between different data sources. This multi-dimensional data fusion and feature extraction approach more accurately characterizes market characteristics than traditional methods, providing richer and more valuable information for subsequent forecasting and analysis, significantly improving the accuracy and reliability of analysis.

[0055] In terms of deep prediction model construction, the deep prediction model built based on the hierarchical attention mechanism contains multiple key layers. The time series feature extraction layer uses a bidirectional long short-term memory network, which can effectively capture implicit patterns and long-term dependencies in historical sequences, overcoming the problem that traditional models lack long-term information when processing time series data. The cross-modal attention layer calculates the feature correlation between different data sources, enabling the model to focus on the important connections between different data modalities and fully utilize the complementary information of multi-dimensional data. The dynamic weight allocation layer adjusts the contribution weight of each feature dimension based on market volatility, allowing the model to flexibly adjust the prediction strategy under different market conditions, improving the model's adaptability and generalization capabilities. Compared with traditional prediction models, this deep prediction model can more accurately predict investment market trends and provide investors with more reliable decision-making basis.

[0056] The segmented prediction and anomaly detection module utilizes an adaptive sliding window mechanism to segment input data. A deep prediction model generates preliminary trend forecasts for each window, while simultaneously calculating local anomaly indicators. This approach not only promptly detects anomalies in the data but also allows for corrections to be made to the forecast results for the anomalous windows, effectively improving the accuracy and stability of the forecasts. By monitoring data anomalies in real time, the platform can issue timely warnings, helping investors avoid erroneous decisions caused by anomalous data and reducing investment risk.

[0057] The forecast correction module filters out abnormal windows based on preset anomaly thresholds and dynamically adjusts forecast results using a Q-learning strategy combined with historical correction feedback data. This correction approach fully considers market dynamics and historical experience, continuously optimizing forecast results and further improving forecast accuracy. By defining a reasonable state space, action space, and reward function, the Q-learning strategy enables the correction module to intelligently adjust forecast values based on market conditions, making it more flexible and effective than traditional fixed correction methods.

[0058] The hybrid ensemble model module feeds the revised forecast and real-time market data into a hybrid ensemble model consisting of a gradient boosting decision tree, a variational autoencoder, and a graph convolutional network in parallel, generating a final market trend probability distribution. This multi-model fusion approach combines the strengths of different models: the gradient boosting decision tree captures nonlinear relationships in the data, the variational autoencoder extracts latent features, and the graph convolutional network utilizes the asset association topology to uncover inter-asset correlations. By fusing the outputs of these three models through gated attention, the platform can more accurately grasp market trends and provide a more reliable basis for investment strategy formulation.

[0059] The investment strategy generation module constructs a risk-return equilibrium strategy based on the probability distribution generated by the hybrid ensemble model. It generates multiple portfolio paths through Monte Carlo simulation and calculates the Sharpe ratio and maximum drawdown metric. This approach fully considers the balance between investment risk and return, providing investors with a variety of portfolio options with different risk-return characteristics. Compared to traditional single investment strategies, investors can choose a portfolio that best suits their risk preferences and investment objectives, achieving optimal asset allocation.

[0060] The optimization decision module uses a non-dominated sorting genetic algorithm to perform multi-objective optimization on the portfolio path, outputting a Pareto front solution set and determining the optimal portfolio allocation plan through a fuzzy comprehensive evaluation method. The non-dominated sorting genetic algorithm can find the optimal balance between multiple conflicting objectives (such as high return and low risk), providing investors with a series of Pareto optimal solutions. The fuzzy comprehensive evaluation method comprehensively considers factors such as Sharpe ratio, maximum drawdown, and liquidity, and combines expert experience to determine the weights and membership functions of each factor. This method can more scientifically and rationally select the optimal portfolio from the Pareto front solution set, helping investors make more informed investment decisions. BRIEF DESCRIPTION OF THE DRAWINGS

[0061] Figure 1 This is a diagram showing the working principle of the investment market trend intelligent analysis and prediction platform based on machine learning according to the present invention;

[0062] Figure 2Flowcharts for forecast result correction and investment strategy generation and optimization;

[0063] Figure 3 This is a flowchart of local abnormality index calculation and abnormal window judgment;

[0064] Figure 4 Flowchart for optimizing a portfolio for a non-dominated sorting genetic algorithm. DETAILED DESCRIPTION

[0065] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of the present invention.

[0066] See also Figure 1-4 The present invention provides a technical solution: a machine learning-based intelligent analysis and prediction platform for investment market trends, which enables accurate prediction of investment market trends and optimized formulation of investment strategies. The platform mainly includes the following key modules:

[0067] Data Collection Module: This module is responsible for acquiring multi-dimensional financial time-series data in real time. This data covers historical prices, trading volume, macroeconomic indicators, and social media sentiment data. Historical prices reflect the past trading price trends of assets and are a fundamental component of market trend analysis. Trading volume reflects the level of market activity and is crucial for determining the strength of market trends. Macroeconomic indicators, such as GDP and interest rates, influence the overall investment market environment at a macro level. Social media sentiment data reflects the sentiment and attitudes of market participants towards the investment market, providing a new perspective for market trend analysis.

[0068] Feature processing module: The multi-dimensional financial time series data acquired by the data acquisition module has different dimensions and distributions. To facilitate subsequent analysis and modeling, normalization is required. The normalized data is input into the preset feature fusion module, which generates a spatiotemporal correlation feature matrix through a series of complex operations. These operations include performing wavelet transform on historical price and trading volume data to extract multi-scale frequency domain features, and tensor splicing them with the lagged terms of macroeconomic indicators; using graph neural networks to construct an asset correlation topology map, and generating asset correlation feature vectors through a graph embedding algorithm; converting social media sentiment polarity data into a sentiment density matrix through a word embedding model, and finally performing three-dimensional convolution fusion on these features to obtain a spatiotemporal correlation feature matrix. This matrix integrates the correlation information of different data sources in the time and space dimensions, providing richer and more valuable features for subsequent model training.

[0069] Deep prediction model construction module: The spatiotemporal correlation feature matrix generated by the feature processing module is used to train a deep prediction model built based on a hierarchical attention mechanism. The model consists of a temporal feature extraction layer, a cross-modal attention layer, and a dynamic weight allocation layer. The temporal feature extraction layer uses a bidirectional long short-term memory network (Bi-LSTM), which can effectively extract implicit patterns in historical sequences and capture long-term dependencies in data. The cross-modal attention layer is used to calculate the feature correlation between different data sources, allowing the model to focus on the important connections between different data modalities. The dynamic weight allocation layer adjusts the contribution weight of each feature dimension according to market volatility, allowing for more flexible predictions under different market conditions.

[0070] The Segmented Prediction and Anomaly Detection Module uses an adaptive sliding window mechanism to segment input data. For each window, the deep prediction model trained in the Deep Prediction Model Construction Module generates preliminary trend predictions. Simultaneously, the module calculates local anomaly metrics for the data within the window to detect anomalies. If an anomalous window is detected, the corresponding prediction result is subsequently corrected to ensure accuracy and reliability.

[0071] The present invention will be further described below in conjunction with Examples 1 to 6:

[0072] Example 1:

[0073] This embodiment is mainly described around the prediction result correction module, hybrid integrated model module, investment strategy generation module and optimization decision module. In the prediction result correction module, an abnormal threshold is preset to filter the abnormal windows in the segmented prediction and anomaly detection module. When the local abnormality index of the data in the window exceeds the preset abnormal threshold, the window is identified as an abnormal window. The preliminary trend prediction results corresponding to these abnormal windows will be input into the preset correction module. The correction module uses the Q-learning strategy combined with historical correction feedback data to dynamically adjust the prediction results. In the Q-learning strategy, the state space S is defined as a combination of the prediction error distribution of the abnormal window and the market volatility. The prediction error distribution reflects the difference between the current prediction value and the actual value, and the market volatility reflects the severity of market price fluctuations. The action space A is the addition and subtraction adjustment of the prediction value, that is, the prediction value can be increased or decreased by a certain value according to the actual situation. Reward function R(s,a)=-λ|P adjusted -P real |+η·VolatilityAlignment, where λ and η are weight coefficients used to adjust the importance of different factors in the reward function; P adjustedis the adjusted predicted value, P real is the actual value, |P adjusted -P real | represents the absolute error between the adjusted forecast and the actual value; a smaller value indicates a more accurate forecast. VolatilityAlignment measures the consistency between the forecast direction and the market fluctuation direction, measuring the degree of fit between the forecast result and the actual market fluctuation direction. The higher the fit, the higher the reward. The Q-value table is iteratively updated through the Bellman equation, continuously optimizing the adjustment strategy for the forecast value until convergence, selecting the action that maximizes the Q-value to correct the forecast result.

[0074] The hybrid ensemble model module takes as input the optimized trend forecast values generated by the forecast result correction module and real-time market data. This hybrid ensemble model consists of a gradient boosting decision tree, a variational autoencoder, and a graph convolutional network in parallel. The gradient boosting decision tree receives the optimized trend forecast values and generates a decision rule set using a recursive segmentation method. It gradually improves the model's prediction accuracy by continuously fitting the residuals. The variational autoencoder encodes real-time market data into a latent space and generates a latent variable distribution through sampling using a reparameterization technique, which effectively extracts the data's latent features. The graph convolutional network aggregates neighborhood node information based on the asset association topology graph and outputs graph structural features, fully leveraging the relationships between assets. Finally, the outputs of the three are gated for attention fusion, with weights dynamically assigned based on the importance of the different outputs to generate the final market trend probability distribution.

[0075] The Investment Strategy Generation Module constructs a risk-return trade-off strategy based on the probability distribution generated by the Hybrid Integrated Model Module. Multiple portfolio paths are generated through Monte Carlo simulation, a method that simulates a variety of possible scenarios through random sampling. In the investment field, it can generate a large number of different portfolio paths based on market uncertainty. The Sharpe ratio and maximum drawdown metric are then calculated for each path. The Sharpe ratio measures the additional return a portfolio can achieve over the risk-free return for each unit of risk assumed. A higher Sharpe ratio indicates a more cost-effective portfolio. The maximum drawdown metric reflects the maximum possible loss a portfolio may incur over a given period of time. A lower maximum drawdown metric indicates a stronger portfolio's risk management capabilities.

[0076] The optimization decision module uses a non-dominated sorting genetic algorithm to perform multi-objective optimization on the portfolio paths generated by the investment strategy generation module. First, the population is initialized, with each chromosome encoding a portfolio weight vector that determines the proportion of different assets in the portfolio. Next, the Sharpe ratio and maximum drawdown objective function values are calculated for each individual. A fast non-dominated sorting algorithm is used to assign frontier ranks, classifying the portfolio into different ranks based on non-domination relationships. A higher rank indicates better overall performance across multiple objectives. A tournament selection mechanism is then used to select parent individuals. The offspring population is generated by simulating binary crossover and polynomial mutation. This approach increases population diversity and prevents the algorithm from falling into local optima. The parent and offspring populations are merged and re-sorted, retaining the top N individuals for the next iteration until a termination condition is met. Finally, the optimal portfolio allocation is determined using a fuzzy comprehensive evaluation method. This method constructs a set of evaluation factors and a set of comments, and combines this with an expert scoring method to determine the membership functions and weight vectors for each factor. A fuzzy comprehensive evaluation matrix is calculated for each solution in the Pareto front solution set, and the final evaluation value is synthesized. The solution with the highest membership is selected as the optimal allocation.

[0077] Example 2:

[0078] When the feature fusion module generates the spatiotemporal correlation feature matrix, it first performs a wavelet transform on the normalized historical price and trading volume data. The wavelet transform is a time-frequency analysis method that decomposes signals into components of different frequencies and analyzes them at different time scales. By extracting multi-scale frequency domain features through the wavelet transform, it is possible to capture the fluctuation characteristics of historical price and trading volume data at different time scales. For example, short time scales can reflect short-term market fluctuations, while long time scales can reveal long-term market trends. These multi-scale frequency domain features are then tensor-concatenated with the lagged terms of macroeconomic indicators. The lagged terms of macroeconomic indicators reflect the lagged impact of macroeconomic factors on the investment market. Combining these features with the frequency domain features of historical prices and trading volumes through tensor concatenation provides a more comprehensive picture of the market.

[0079] Graph neural networks are used to construct an asset association topology graph. In this topology graph, nodes represent different asset categories, such as stocks, bonds, funds, etc. Edge weights are determined based on the cointegration coefficient, which measures the long-term equilibrium relationship between different assets. If there is a cointegration relationship between two assets, it means that their prices will maintain a certain relative stability in the long term. Let the cointegration coefficient of assets i and j be ρ ij , then the edge weight e ij =|ρ ij |, by converting the cointegration relationship into the edge weight of the topological graph in this way, the strength of the correlation between assets can be intuitively reflected.ij >θ, where θ is the significance threshold, indicating that the cointegration relationship is relatively significant, the edge is retained and Gaussian kernel smoothing is applied. Gaussian kernel smoothing can make the structure of the topological graph smoother and more stable, avoiding excessive fluctuations in edge weights caused by individual abnormal data.

[0080] Social media sentiment polarity data is converted into a sentiment density matrix using a word embedding model. A word embedding model maps words in a text to a low-dimensional vector space, thereby converting text data on social media into a numerical sentiment density matrix. This matrix can reflect the sentiment on social media regarding the investment market, such as positive, negative, or neutral. Finally, a three-dimensional convolution is performed to fuse the frequency domain features, asset association feature vectors, and sentiment density matrix. This three-dimensional convolution operation simultaneously processes data in time, space, and feature dimensions, fully exploiting the spatiotemporal correlations between different data sources and outputting a spatiotemporal correlation feature matrix. This matrix integrates the temporal and spatial correlation features of historical prices, trading volumes, macroeconomic indicators, and social media sentiment polarity data, providing high-quality input data for subsequent deep prediction model training.

[0081] Example 3:

[0082] The cross-modal attention layer plays a key role in deep prediction models. It is used to calculate the feature correlation between different data sources. Assume that the input data source includes the historical price series X p , trading volume sequence X v , macroeconomic indicator series X m and sentiment polarity sequence X s These sequences are mapped to high-dimensional space through independent fully connected layers. The fully connected layer is a common structure in neural networks. It can perform linear transformation and nonlinear activation on the input data, thereby mapping the data to a higher-dimensional feature space, enabling the model to learn more complex feature relationships. After mapping through the fully connected layer, the feature vector H is obtained. p 、H v 、H m 、H s .

[0083] Next, calculate the cross-modal correlation matrix Among them, H i 、H j is the eigenvector of different modes, W a is a trainable parameter matrix, i,j∈p,v,m,s. Softmax function is a commonly used activation function that converts the input value into a probability distribution so that each element is between 0 and 1 and the sum of all elements is 1. The cross-modal association matrix A calculated by the Softmax function is ijIt indicates the degree of correlation between different modal eigenvectors. The larger the value, the closer the correlation between the two modes.

[0084] Perform weighted aggregation on the feature vector of each data source. The specific calculation method is H i ′=∑ j A ij H j The characteristic vector H corresponding to the historical price series p For example, H′ p By adding H p The eigenvector H of other modalities (trading volume, macroeconomic indicators, sentiment polarity) v 、H m 、H s , according to the cross-modal correlation matrix A ij The corresponding weights in are weighted summed. Thus, H′ p It not only contains the characteristic information of the historical price series itself, but also integrates the characteristic information related to the historical price series from other data sources. Similarly, H′ is calculated v , H′ m , H′ s , output cross-modal fusion feature H′ p , H′ v , H′ m , H′ s These cross-modal fusion features integrate information from different data sources, can better reflect the complex characteristics of the investment market, and provide stronger support for subsequent predictions.

[0085] Example 4:

[0086] In the segmented prediction and anomaly detection module, calculating the local anomaly index is an important means of detecting data anomalies. k , first calculate its Mahalanobis distance Where μ is the mean vector of the sliding window data, reflecting the average level of the data within the window; Σ is the covariance matrix, which measures the correlation between dimensions in the data. The Mahalanobis distance accounts for the covariance structure of the data and, compared to the Euclidean distance, more accurately reflects the relative positional relationships between data points and is unaffected by the data's dimensionality.

[0087] Defining abnormality where μ D is the mean Mahalanobis distance of the historical window, which is obtained by averaging the Mahalanobis distances of multiple historical windows and reflects the average level of Mahalanobis distance under normal circumstances; σ D Its standard deviation measures the degree of dispersion of the Mahalanobis distance in the historical window.k >γ, where γ is the dynamic adjustment threshold, which can be adjusted according to market changes and actual needs. When the abnormality of the data in the window exceeds this threshold, the window W k Marks the window as abnormal.

[0088] For example, in a specific investment market data set, the sliding window size is set to 30 data points. k , calculate its mean vector μ and covariance matrix Σ, and then calculate the Mahalanobis distance D k By statistically analyzing the Mahalanobis distances of a large number of historical windows, the mean Mahalanobis distance μ of the historical windows is obtained. D and standard deviation σ D , calculate the abnormality O k If O k If it is greater than the dynamic adjustment threshold γ, it indicates that the data in the window may be abnormal, and the preliminary trend prediction results corresponding to the window need to be further corrected to improve the accuracy of the prediction.

[0089] Example 5:

[0090] The construction of the hybrid ensemble model is one of the important links of the present invention, which is composed of a gradient boosting decision tree, a variational autoencoder and a graph convolutional network in parallel.

[0091] The gradient boosting decision tree receives the optimized trend prediction values generated by the prediction result correction module. The gradient boosting decision tree generates a set of decision rules using a recursive partitioning method. It is based on an iterative approach, where each iteration fits the residuals of the previous model, gradually improving the model's predictive capabilities. For example, in the first iteration, a decision tree is constructed based on the difference between the optimized trend prediction value and the actual value. This decision tree can correct the prediction error for a portion of the data. In subsequent iterations, new decision trees are continuously constructed to fit the residuals of the previous model. The results of these decision trees are accumulated to obtain the final prediction result. In this way, the gradient boosting decision tree can capture complex nonlinear relationships in the data and improve prediction accuracy.

[0092] A variational autoencoder processes real-time market data. It first encodes the data into a latent space, a low-dimensional feature space. Through encoding, the high-dimensional raw data can be compressed into a low-dimensional space while preserving the data's key features. The variational autoencoder then samples and generates a latent variable distribution using the reparameterization technique, a method that converts sampling into a differentiable computational process, allowing the variational autoencoder to be trained using the backpropagation algorithm. In this way, the variational autoencoder learns the underlying distribution of the data and generates representative latent variables, which can provide more in-depth information for subsequent predictions.

[0093] Graph convolutional networks aggregate information about neighboring nodes based on an asset association topology graph. Nodes in the graph represent different asset categories, and edges represent the relationships between assets. By aggregating the features of neighboring nodes, graph convolutional networks can fully leverage the associations between assets. For example, for a given asset node, the graph convolutional network considers the features of its neighboring asset nodes and aggregates the information from these neighboring nodes onto the current node through methods such as weighted summation, thereby outputting graph structural features. These graph structural features reflect the relationships between assets and the overall market structure.

[0094] Finally, the outputs of the gradient boosting decision tree, variational autoencoder, and graph convolutional network are fused using gated attention. This gated attention mechanism dynamically assigns weights based on the importance of different outputs, allowing the model to more flexibly integrate information from different modules. For example, during periods of high market volatility, the latent variable information output by the variational autoencoder may be given greater weight; whereas during periods of relative market stability, the decision rules of the gradient boosting decision tree may have a greater impact on the final prediction results. Through gated attention fusion, a final probability distribution of market trends is generated, providing a more reliable basis for formulating investment strategies.

[0095] Example 6:

[0096] In the optimization decision module, the non-dominated sorting genetic algorithm optimization process, the fuzzy comprehensive evaluation method implementation steps and the asset association topology map construction method are involved. These contents are explained in detail below.

[0097] The non-dominated sorting genetic algorithm is used to perform multi-objective optimization on the portfolio paths generated by the investment strategy generation module. The population is initialized. During this process, each chromosome encodes a portfolio weight vector. The portfolio weight vector determines the proportion of different assets in the portfolio. For example, assuming there are three asset classes: stocks, bonds, and mutual funds, the portfolio weight vector (0.5, 0.3, 0.2) indicates that stocks account for 50%, bonds for 30%, and mutual funds for 20%. This encoding method converts the portfolio configuration information into a chromosome form that the genetic algorithm can process, laying the foundation for subsequent optimization operations.

[0098] Next, calculate the individual Sharpe ratio and maximum drawdown objective function value. The Sharpe ratio is an important indicator to measure the performance of the investment portfolio. Its calculation formula is: Among them, R p It represents the expected rate of return of the investment portfolio, which reflects the average return that the investment portfolio is expected to obtain over a period of time. p The higher the value of R, the stronger the profitability of the portfolio; f Represents the risk-free rate of return, which is usually based on a more stable rate of return such as the government bond rate of return. It represents the rate of return under risk-free conditions; σ p is the standard deviation of the portfolio, which is used to measure the volatility of the portfolio return, that is, the risk level, σ p The larger the value, the more volatile the portfolio's returns and the higher the risk. By calculating the Sharpe ratio, we can assess the additional return a portfolio can earn over the risk-free rate for each unit of risk it assumes. The higher the ratio, the more cost-effective the portfolio.

[0099] The maximum drawdown indicator reflects the maximum possible loss a portfolio can incur over a given period. It identifies the maximum drop in asset value from a peak to a subsequent trough within the portfolio's historical returns. For example, if a portfolio's asset value drops from a high of 100 yuan to a low of 80 yuan over a given period, the maximum drawdown is (100 - 80) ÷ 100 = 20%. A smaller maximum drawdown indicator indicates a portfolio's ability to better manage losses during market fluctuations and demonstrates stronger risk management capabilities.

[0100] After calculating the objective function values, the frontier ranks are assigned using fast non-dominated sorting. Fast non-dominated sorting is a ranking method based on dominance relationships between individuals. In multi-objective optimization problems, an individual is said to dominate another individual if it performs equally well on all objectives, or even better on some objectives. Using fast non-dominated sorting, individuals in the population are divided into different frontier ranks based on their dominance relationships. Individuals with lower frontier ranks have better overall performance across multiple objectives and are closer to Pareto optimal solutions. This ranking method effectively selects individuals in portfolios that achieve a good balance between multiple objectives, providing higher-quality candidate solutions for subsequent optimization operations.

[0101] A tournament selection mechanism is used to select parent individuals. This mechanism randomly selects a certain number of individuals from the population, for example, five, and then selects the one with the best fitness as the parent. Fitness is typically measured based on previously calculated objective functions such as the Sharpe ratio and maximum drawdown. Individuals with a high Sharpe ratio and a low maximum drawdown are considered more fit. This selection method can, to a certain extent, mitigate excessive randomness in the selection process, ensuring that the selected parent individuals have good performance, which helps the genetic algorithm gradually search for a better solution during the iterative process.

[0102] The offspring population is then generated through simulated binary crossover and polynomial mutation. Simulated binary crossover simulates the natural genetic process of genetic crossover, swapping genes from two parent individuals with a certain crossover probability to generate new offspring individuals. For example, if two parent individuals have portfolio weight vectors of (0.4, 0.3, 0.3) and (0.2, 0.5, 0.3), the resulting offspring weight vectors after simulated binary crossover might be (0.4, 0.5, 0.1) and (0.2, 0.3, 0.5). Polynomial mutation randomly mutates the genes of individuals, adjusting certain gene values with a certain probability to increase population diversity. For example, a portfolio weight vector of (0.3, 0.4, 0.3) might become (0.35, 0.4, 0.25) under polynomial mutation. By simulating binary crossover and polynomial mutation to continuously generate new offspring populations, the genetic algorithm can explore a wider solution space and avoid being trapped in local optima.

[0103] The parent and child populations are merged and re-sorted, retaining the top N individuals for the next iteration. After each iteration, the parent and child populations are merged and re-sorted using the fast non-dominated sorting method. The top N best-performing individuals are selected as members of the next generation population. This process is repeated until a predetermined termination condition is met, such as reaching the maximum number of iterations or the objective function value converges to a certain level. Through this iterative optimization process, the performance of the portfolio is continuously improved, gradually approaching the optimal solution.

[0104] To determine the optimal investment portfolio allocation, a fuzzy comprehensive evaluation method is used. First, we construct the evaluation factor set U = {Sharpe ratio, maximum drawdown, liquidity} and the comment set V = {Excellent, Good, Fair, Poor}. The evaluation factor set encompasses the key factors that influence the quality of an investment portfolio. The Sharpe ratio reflects the portfolio's return-risk ratio, the maximum drawdown reflects the portfolio's risk control capabilities, and the liquidity measures the ease of liquidating the portfolio's assets. The comment set then categorizes the comprehensive evaluation results of the portfolio.

[0105] Next, the membership function and weight vector W = (w1, w2, w3) for each factor are determined through an expert scoring method. Experts in relevant fields, based on their expertise and experience, assign scores to each evaluation factor based on different rating scales. For example, for the Sharpe ratio, experts might consider that when the Sharpe ratio exceeds a certain threshold, it has a membership level of 0.8 in the "Excellent" category and 0.2 in the "Good" category. For maximum drawdown, experts determine its membership level based on factors such as risk tolerance. In the weight vector W, w1, w2, and w3 represent the weights for the Sharpe ratio, maximum drawdown, and liquidity, respectively, reflecting the relative importance of each factor in the comprehensive evaluation. When determining the weight vector, experts consider various factors, including the market environment and investor risk appetite. For example, during periods of high market volatility, maximum drawdown may be given a higher weight; whereas, when investors prioritize returns, the Sharpe ratio may be given a higher weight.

[0106] Calculate the fuzzy comprehensive evaluation matrix R for each solution in the Pareto front solution set and synthesize the final evaluation value in is the fuzzy synthesis operator. The element r in the fuzzy comprehensive evaluation matrix R ij It represents the membership of the i-th evaluation factor to the j-th comment level. For example, r 12 The Sharpe ratio represents the degree of membership of the evaluation level "good". The final evaluation value B is obtained by performing fuzzy synthesis operation on the weight vector W and the fuzzy comprehensive evaluation matrix R. Each element b in B jrepresents the portfolio's overall membership to the jth rating. Finally, the solution with the maximum membership is selected as the optimal allocation. For example, if b2 (corresponding to the "good" rating) is the largest, then this portfolio is considered closest to a "good" rating in terms of overall evaluation and is considered the optimal portfolio allocation for the current situation.

[0107] In the entire optimization decision-making process, the asset correlation topology plays an important role. When constructing the asset correlation topology, the correlation strength is calculated based on the cointegration relationship of the asset's historical returns. Let the cointegration coefficient of assets i and j be ρ ij , then the edge weight e ij =|ρ ij |. Cointegration reflects the equilibrium relationship between different asset prices in the long term. If two assets have a cointegration relationship, it means that their price trends will affect each other in the long term. Cointegration coefficient ρ ij It measures the closeness of this relationship, ij The larger the | is, the stronger the association between assets i and j is. The corresponding edge weight e in the asset association topology graph is ij The larger it is. If ρ ij >θ, where θ is the significance threshold, indicating a significant cointegration relationship. In this case, the edge is retained and Gaussian kernel smoothing is applied. Gaussian kernel smoothing can make the topology structure smoother and more stable, reducing edge weight fluctuations caused by individual abnormal data and better reflecting the true correlation between assets.

[0108] The ForceAtlas2 algorithm is used to optimize the topology map layout and generate a visual asset association network. The ForceAtlas2 algorithm is a physics-based graph layout algorithm that simulates the attractive and repulsive forces between nodes in a graph, making the layout of nodes on a plane more rational and intuitive. After optimizing the asset association topology map using this algorithm, a visual asset association network is generated. In this network, nodes represent different assets, and the thickness and color of edges indicate the edge weights—that is, the strength of the associations between assets. This visual asset association network allows investors to more clearly understand the relationships between different assets, providing a more intuitive reference for investment decisions.

[0109] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that includes a list of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus.

[0110] While embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions, and variations may be made to these embodiments without departing from the principles and spirit of the invention, and that the scope of the invention is defined by the appended claims and their equivalents.

Claims

1. An investment market trend intelligent analysis and prediction platform based on machine learning, characterized by: include: Data acquisition module: used to obtain multi-dimensional financial time series data in real time, including historical prices, trading volumes, macroeconomic indicators, and social media sentiment polarity data; Feature processing module: normalizes the multi-dimensional financial time series data acquired by the data acquisition module and inputs it into a preset feature fusion module to generate a spatiotemporal correlation feature matrix; Deep prediction model construction module: uses the spatiotemporal correlation feature matrix generated by the feature processing module to train a deep prediction model based on a hierarchical attention mechanism. The model includes a temporal feature extraction layer, a cross-modal attention layer, and a dynamic weight allocation layer. The temporal feature extraction layer uses a bidirectional long short-term memory network to extract implicit patterns in historical sequences. The cross-modal attention layer is used to calculate the feature correlation between different data sources. The dynamic weight allocation layer adjusts the contribution weight of each feature dimension according to market volatility. Segmented prediction and anomaly detection module: The input data is segmented using an adaptive sliding window mechanism. The data in each window is generated through the deep prediction model of the deep prediction model construction and training module to generate preliminary trend prediction results, and the local anomaly index of the data in the window is simultaneously calculated.

2. The investment market trend intelligent analysis and prediction platform according to claim 1 is characterized in that: Also includes: Prediction result correction module: This module filters abnormal windows in the segmented prediction and anomaly detection module based on a preset abnormal threshold, and inputs the preliminary trend prediction results corresponding to the abnormal windows into a preset correction module. The correction module dynamically adjusts the prediction results through the Q-learning strategy combined with historical correction feedback data to generate an optimized trend prediction value. Hybrid integration model module: Inputs the optimized trend forecast value generated by the forecast result correction module and real-time market data into the hybrid integration model, which is composed of a gradient boosting decision tree, a variational autoencoder, and a graph convolutional network in parallel to generate the final market trend probability distribution; Investment strategy generation module: constructs a risk-return equilibrium strategy based on the probability distribution generated by the hybrid integrated model module, generates multiple portfolio paths through Monte Carlo simulation, and calculates the Sharpe ratio and maximum drawdown index of each path; Optimization decision module: uses a non-dominated sorting genetic algorithm to perform multi-objective optimization on the investment portfolio path generated by the investment strategy generation module, outputs a Pareto front solution set, and determines the optimal investment portfolio configuration plan through a fuzzy comprehensive evaluation method.

3. The investment market trend intelligent analysis and prediction platform according to claim 1 is characterized in that: The specific steps of the feature fusion module to generate the spatiotemporal correlation feature matrix are as follows: For the normalized historical price and trading volume data, multi-scale frequency domain features are extracted through wavelet transform and tensor splicing is performed with the lagged terms of macroeconomic indicators; Utilize graph neural networks to construct an asset association topology graph, where nodes represent different asset categories and edge weights are determined based on cointegration coefficients. Graph embedding algorithms are used to generate asset association feature vectors. The social media sentiment polarity data is converted into a sentiment density matrix through a word embedding model, and is fused with the frequency domain features and asset association feature vectors through three-dimensional convolution to output a spatiotemporal association feature matrix.

4. The investment market trend intelligent analysis and prediction platform according to claim 3 is characterized in that: The calculation process of the cross-modal attention layer is specifically as follows: Assume that the input data source includes the historical price series X p , trading volume sequence X v , macroeconomic indicator series X m and sentiment polarity sequence X s , are mapped to high-dimensional space through independent fully connected layers to obtain the feature vector H p ,H v ,H m ,H s ; Calculate the cross-modal correlation matrix Among them, H i ,H j is the eigenvector of different modes, W a is the trainable parameter matrix, i,j∈{p,v,m,s}; Perform weighted aggregation on the feature vector of each data source: H′ i =∑ j A ij H j , output cross-modal fusion features {H′ p ,H′ v ,H′ m ,H′ s }.

5. The investment market trend intelligent analysis and prediction platform according to claim 2 is characterized in that: The calculation method of the local abnormality index is: For the data in the window W k , calculate its Mahalanobis distance Where μ is the mean vector of the sliding window data, Σ is the covariance matrix; Defining abnormality where μ D is the mean Mahalanobis distance of the historical window, σ D is its standard deviation; If O k >γ, where γ is the dynamically adjusted threshold, then the window W k Mark the window as abnormal.

6. The investment market trend intelligent analysis and prediction platform according to claim 2, characterized in that: The Q-learning strategy of the reinforcement learning correction module is specifically: Define the state space S as the combination of the forecast error distribution of the abnormal window and the market volatility, and the action space A as the addition and subtraction adjustments to the forecast value; Reward function R(s,a) = -λ|P adjusted -P real |+η·VolatilityAlignment, where λ,η are weight coefficients, P adjusted is the adjusted predicted value, P real is the actual value, VolatilityAlignment is a measure of the consistency between the predicted direction and the market volatility direction; The Q-value table is updated iteratively through the Bellman equation until convergence, and the action that maximizes the Q-value is selected to correct the prediction result.

7. The investment market trend intelligent analysis and prediction platform according to claim 2 is characterized in that: The construction method of the hybrid integration model is: The gradient boosting decision tree receives the optimized trend prediction value and generates a decision rule set in a recursive splitting manner; The variational autoencoder encodes real-time market data into a latent space and generates a latent variable distribution through sampling using a reparameterization technique; The graph convolutional network aggregates neighborhood node information based on the asset association topology graph and outputs graph structural features; The outputs of the three are gated and fused.

8. The investment market trend intelligent analysis and prediction platform according to claim 2 is characterized in that: The optimization process of the non-dominated sorting genetic algorithm is: Initialize the population, each chromosome encodes a portfolio weight vector; Calculate the individual Sharpe ratio and maximum drawdown objective function values, and divide the frontier level by fast non-dominated sorting; A tournament selection mechanism is used to screen parent individuals, and the offspring population is generated by simulating binary crossover and polynomial mutation; The parent and child populations are merged and reordered, retaining the first N individuals to enter the next generation of iteration until the termination condition is reached.

9. The investment market trend intelligent analysis and prediction platform according to claim 7, characterized in that: The implementation steps of the fuzzy comprehensive evaluation method are: Construct the evaluation factor set U = {Sharpe ratio, maximum drawdown, liquidity}, and the comment set V = {excellent, good, fair, poor}; The membership function and weight vector W = (w1, w2, w3) of each factor are determined by the expert scoring method, where w1, w2, and w3 are the weights of the Sharpe ratio, maximum drawdown, and liquidity, respectively; The fuzzy comprehensive evaluation matrix R is calculated for each solution in the Pareto front solution set, and the final evaluation value B = W°R is synthesized, where ° is the fuzzy synthesis operator, and the solution corresponding to the maximum membership degree is selected as the optimal configuration.

10. The investment market trend intelligent analysis and prediction platform according to claim 2, characterized in that: The method for constructing the asset association topology map is: Calculate the correlation strength based on the cointegration relationship of the historical returns of assets, assuming that the cointegration coefficient of assets i and j is ρ ij , then the edge weight e ij =|ρ ij |;If ρ ij >θ, then the edge is retained and Gaussian kernel smoothing is applied, where θ is the significance threshold; The ForceAtlas2 algorithm is used to optimize the layout of the topology map and generate a visual asset association network.

Citation Information

Cited By

  • Data asset valuation method based on machine learning fusion benefit and market factor

    CN120894077A

  • Data asset valuation method based on machine learning fusion of benefits and market factors

    CN120894077B

  • Method, apparatus, and system for stock investment analysis and decision-making optimization based on quantum computing and multi-agents

    KR102966966B1