Multi-agent financial analysis system and method based on large language model

By introducing a multi-agent financial analysis system based on large language models into the financial analysis system, the organizational structure of the financial analysis team is simulated and combined with dynamic coordination and hybrid communication protocols, the shortcomings of the existing system in organizational modeling, communication efficiency, interpretability and analysis depth are solved, and efficient and interpretable financial market analysis and strategy generation are achieved.

CN120106986APending Publication Date: 2025-06-06SHANDONG INSPUR SCI RES INST CO LTD
View PDF 0 Cites 8 Cited by

Patent Information

Application Number
CN202510270740.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-07
Publication Date
2025-06-06

AI Technical Summary

Technical Problem

The existing financial analysis system has shortcomings in simulating the complex interaction and organizational structure, communication efficiency, interpretability and analysis depth of the financial analysis team, resulting in deviations from the actual situation, inefficiency, information omissions or misunderstandings, affecting the accuracy of the analysis, and may trigger trust crises and regulatory difficulties.

Method used

A multi-agent financial analysis system based on large language models is adopted to simulate the organizational structure of the financial analysis team, combined with dynamic coordination and hybrid communication protocols, to achieve efficient and interpretable financial market analysis and strategy generation. The system includes a multi-role agent module, a hybrid communication protocol module, a dynamic coordinator module, an interpretability enhancement module, and a data fusion and policy generation module.

Benefits of technology

The efficiency, depth and credibility of financial analysis have been significantly improved, and organizational modeling has been improved through multi-role agent modules, hybrid communication protocols have improved communication efficiency, and dynamic coordinator and interpretability enhancement modules have enhanced the interpretability of analysis and the credibility of strategies.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120106986A_ABST
    Figure CN120106986A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of financial analysis, and discloses a multi-agent financial analysis system and method based on a large language model, and each agent of a multi-role agent module realizes specialized analysis through a field customization LLM; the hybrid communication protocol module integrates a structured report and a natural language dialogue, and the structured report adopts a JSON or XML format; the dynamic coordinator module is configured to dynamically allocate an agent weight according to the difference between the market stage and the confidence coefficient; the interpretability enhancing module is used for outputting an inference logic chain through a natural language generation technology and visually presenting the inference logic chain; and the data fusion and strategy generation module is used for integrating basic surface, emotion, technology and macroeconomic data and generating a dynamic investment strategy. According to the method, by simulating the organization structure and the cooperation process of a real financial analysis team, the multi-source data are integrated, and the interpretable comprehensive investment strategy is generated, so that the efficiency, the depth and the credibility of financial analysis are remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of financial analysis technology, for example, to a multi-agent financial analysis system based on a large language model (LLM). Background Art

[0002] In the field of financial analysis, traditional analysis methods mostly rely on quantitative models and single-agent systems, but the limitations of these methods become increasingly prominent when dealing with complex market data and the interactions between multiple factors. In recent years, the significant progress of large language models (LLMs) in natural language processing and understanding has undoubtedly injected new vitality into financial applications. However, the existing system still has many shortcomings that need to be improved:

[0003] First, they fail to effectively simulate the complex interactions and organizational structures of real-world financial analysis teams, which leads to certain deviations between the analysis results and actual conditions.

[0004] Secondly, existing systems mainly rely on natural language dialogue for communication, which is not only inefficient but also prone to information omissions or misunderstandings, affecting the accuracy of analysis.

[0005] Furthermore, deep learning models are usually like "black boxes" and their decision-making logic is difficult to explain intuitively, which may cause a crisis of trust and regulatory difficulties in the financial field.

[0006] Finally, despite the advancement of technology, the existing system still lacks the depth and breadth of market analysis, and it is difficult to fully grasp the multiple factors affecting the financial market. The existence of these problems restricts the actual application effect of the financial analysis system.

[0007] In recent years, large language models (LLMs) have made breakthroughs in the field of natural language processing, but their application in financial analysis is still limited to single-task scenarios and lacks multi-role collaboration and structured communication mechanisms. Existing systems urgently need to be improved in terms of team modeling, communication efficiency, and analysis depth.

[0008] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present application, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention

[0009] In order to provide a basic understanding of some aspects of the disclosed embodiments, a brief summary is given below. The summary is not an extensive review, nor is it intended to identify key / critical components or delineate the scope of protection of these embodiments, but rather serves as a prelude to the detailed description that follows.

[0010] The disclosed embodiments provide a multi-agent financial analysis system and method based on a large language model, which achieves efficient and explainable financial market analysis and strategy generation by simulating the organizational structure of a financial analysis team and combining dynamic coordination and hybrid communication protocols.

[0011] In some embodiments, the system comprises:

[0012] Multi-role agent module, including fundamental analyst, sentiment analyst, technical analyst, macroeconomic analyst and strategy generator. Each agent can achieve professional analysis through field-customized LLM.

[0013] A hybrid communication protocol module integrates structured reports and natural language dialogues, wherein the structured reports are in JSON or XML format; the structured reports contain mandatory fields and extensible fields;

[0014] A dynamic coordinator module, configured to dynamically assign agent weights based on market stage and confidence differences;

[0015] The explainability enhancement module outputs the reasoning logic chain through natural language generation technology and presents it visually;

[0016] The data fusion and strategy generation module integrates fundamental, sentiment, technical and macroeconomic data to generate dynamic investment strategies.

[0017] Optionally, the explainability enhancement module dynamically outputs the reasoning steps through natural language generation technology; and visualizes the contribution of key indicators to the strategy through SHAP or LIME algorithm;

[0018] The data fusion and strategy generation module integrates a cross-modal attention network, synchronously processes text data streams and high-frequency trading time series data through a time alignment mechanism, and realizes multi-dimensional feature cross-validation.

[0019] Optionally, the trigger mechanism of the structured report includes: mandatory fields are used for conventional analysis tasks; and extensible fields are used to adapt to emergencies or add new analysis dimensions.

[0020] Optionally, a fundamental analysis agent is used to analyze the company's financial statements, earnings reports, and internal transaction data to assess the company's intrinsic value;

[0021] Sentiment analysis agents that process social media posts and news articles to analyze market sentiment and predict short-term market fluctuations;

[0022] Technical analysis agents, which are used to calculate and analyze technical indicators of stocks to predict stock price trends;

[0023] Macroeconomic analysis agent, which is used to analyze macroeconomic data to assess the impact of the macroeconomic environment on the market;

[0024] The strategy generation agent is used to integrate the reports of the aforementioned analysis agents to generate investment strategies and recommendations.

[0025] Optionally, the fundamental analysis agent includes a data cleaning and processing sub-agent for standardizing and cleaning the company's financial statements, earnings reports, and internal transaction data to improve the accuracy of the analysis;

[0026] The strategy generation agent uses a machine learning algorithm to optimize the generation of investment strategies based on historical data.

[0027] Optionally, the triggering condition of the natural language dialogue is:

[0028] The confidence differences between the conclusions of the agents exceed 30%;

[0029] Market volatility exceeds the historical mean by two standard deviations.

[0030] Optionally, the sentiment analyst agent integrates a graph neural network to identify the propagation path of false information in social media and filters noisy data through an attention mechanism.

[0031] Optionally, the technical analyst agent is embedded in the TA-Lib knowledge base for real-time calculation of technical indicators and data update with a delay of less than 50ms through the Apache Flink stream processing framework.

[0032] Optionally, the weight allocation logic of the dynamic coordinator module includes:

[0033] Give more weight to technical analysis and sentiment analysis in the bull market phase;

[0034] Give more weight to fundamental analysis and macroeconomic analysis in the bear market phase;

[0035] Dynamic optimization is performed through the reinforcement learning algorithm (PPO algorithm) with the Sharpe ratio maximization as the objective function.

[0036] In some embodiments, the method uses the aforementioned multi-agent financial analysis system based on a large language model, and the multi-agent financial analysis method includes:

[0037] Process fundamental, sentiment, technical and macroeconomic data through multi-role agent modules;

[0038] Structured reports and natural language dialogues are delivered through a hybrid communication protocol module, and conflicts are resolved by a dynamic coordinator;

[0039] Dynamically adjust agent weights based on reinforcement learning to generate investment strategies;

[0040] Output dual explanation reports through natural language generation and feature attribution analysis.

[0041] The multi-agent financial analysis system based on a large language model provided by the embodiments of the present disclosure can achieve the following technical effects:

[0042] This system uses a multi-role agent module to define multiple professional agent roles. By defining multi-role agents such as fundamental analysts and sentiment analysts, the functional division of real financial teams is mapped to the AI ​​system for the first time. Traditional methods mostly rely on a single model or loose collaboration, while this solution simulates the real team collaboration process through role-based division of labor, filling the gap in organizational modeling in existing systems.

[0043] The structured communication protocol proposes a combination of natural language dialogue and structured reports (such as tables and templated data), solving the efficiency problem of pure natural language interaction. Existing systems (such as the ChatGPT financial plug-in) mostly rely on single language interaction, and this protocol improves information density and accuracy through structured data, which is an important improvement in the communication mechanism.

[0044] The explainable analysis module makes the analysis process transparent, using natural language generation (NLG) technology to dynamically explain the reasoning steps of each agent instead of just providing results. Compared with traditional explainability methods (such as feature importance analysis), this design is more in line with the cognitive habits of financial practitioners and enhances the credibility of decision-making.

[0045] The multi-source data integration engine integrates fundamentals, sentiment, technical indicators and macroeconomic data at the same time, and realizes in-depth analysis through the division of labor agents. Existing systems usually focus on a single data type (such as quantitative models only use historical prices), while this solution covers a more comprehensive analysis dimension through multi-agent collaboration.

[0046] This application proposes an integrated solution to the four major pain points of financial analysis (organizational modeling, communication efficiency, explainability, and analytical depth), rather than improving a single problem in isolation. For example, the structured communication protocol not only improves efficiency, but also supports explainability (such as annotating data sources and analysis logic) through a standardized format.

[0047] The deep coupling of large language models (LLMs) and multiple agents embeds the capabilities of large language models into the multi-role agent framework, which not only takes advantage of LLM's natural language processing advantages, but also avoids the lack of professionalism caused by its generalization through structured division of labor. For example, technical analyst agents can be trained to identify technical indicators in a targeted manner, rather than relying on the broad knowledge of general LLMs.

[0048] In addition, this application realizes the transformation of the financial analysis system from "tool" to "team". Traditional AI financial tools serve as passive response systems, while this application realizes an active and continuously iterative analysis process by simulating team collaboration (such as the strategy generator coordinating the conclusions of various analysts), which is closer to the working mode of human experts.

[0049] In addition, compared with the existing analysis system, this application has the following advantages:

[0050] Compared with a single-agent system (such as Bloomberg GPT): This solution solves the problem of complex task decomposition through multi-role division of labor, avoiding knowledge overload of a single model.

[0051] Compared with traditional multi-agent frameworks (such as MetaGPT): it introduces role design and structured communication protocols specific to the financial field to enhance domain adaptability.

[0052] Compared with explainability solutions (such as LIME / SHAP): through procedural natural language explanation rather than post-hoc attribution analysis, it is more in line with the financial regulatory needs for decision traceability.

[0053] In summary, the system simulates the organizational structure and collaboration process of a real financial analysis team, integrates multi-source data and generates explainable comprehensive investment strategies, significantly improving the efficiency, depth and credibility of financial analysis.

[0054] The above general description and the following description are exemplary and explanatory only and are not intended to limit the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] One or more embodiments are exemplarily described by corresponding drawings, which do not limit the embodiments. Elements with the same reference numerals in the drawings are shown as similar elements, and the drawings do not constitute a scale limitation, and wherein:

[0056] Figure 1 : Schematic diagram of the working principle of the present invention;

[0057] Figure 2 : System architecture diagram of the present invention. DETAILED DESCRIPTION

[0058] In order to be able to understand the features and technical contents of the embodiments of the present disclosure in more detail, the implementation of the embodiments of the present disclosure is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present disclosure. In the following technical description, for the convenience of explanation, a full understanding of the disclosed embodiments is provided through multiple details. However, one or more embodiments can still be implemented without these details. In other cases, to simplify the drawings, well-known structures and devices can be simplified for display.

[0059] The terms "first", "second", etc. in the embodiments of the present disclosure are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchanged where appropriate, so as to describe the embodiments of the present disclosure described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions.

[0060] Unless otherwise stated, the term "plurality" means two or more.

[0061] In the embodiment of the present disclosure, the character " / " indicates that the preceding and following objects are in an "or" relationship. For example, A / B indicates: A or B.

[0062] The term "and / or" is a description of the association relationship between objects, indicating that three relationships can exist. For example, A and / or B means: A or B, or, A and B.

[0063] The term "correspondence" may refer to an association relationship or a binding relationship. The correspondence between A and B means that there is an association relationship or a binding relationship between A and B.

[0064] The core of the present invention is to build a multi-role intelligent agent collaboration system, combining a hybrid communication protocol with a dynamic coordination mechanism. The specific scheme is as follows:

[0065] The present invention provides a multi-agent financial analysis system based on a large language model, comprising:

[0066] Multi-role agent module, including fundamental analyst, sentiment analyst, technical analyst, macroeconomic analyst and strategy generator. Each agent can achieve professional analysis through field-customized LLM.

[0067] A hybrid communication protocol module integrates structured reports and natural language dialogues, wherein the structured reports are in JSON or XML format; the structured reports contain mandatory fields and extensible fields;

[0068] A dynamic coordinator module, configured to dynamically assign agent weights based on market stage and confidence differences;

[0069] The explainability enhancement module outputs the reasoning logic chain through natural language generation technology and presents it visually;

[0070] The data fusion and strategy generation module integrates fundamental, sentiment, technical and macroeconomic data to generate dynamic investment strategies.

[0071] It can be understood that the present invention proposes a multi-agent financial analysis framework based on a large language model (LLM), which achieves efficient, explainable and comprehensive financial data analysis by simulating the organizational structure and workflow of real-world financial analysis teams.

[0072] The multi-role agent module defines agents with multiple professional roles, such as fundamental analysts, sentiment analysts, technical analysts, macroeconomic analysts, strategy generators, etc. Each agent is responsible for a specific analysis task, simulating the collaborative process of a real-world financial analysis team. Among them, fundamental analysts are used to analyze a company's financial statements, earnings reports, internal transactions, etc., and evaluate the company's intrinsic value.

[0073] Sentiment analysts are used to process social media posts, news articles, etc. to analyze market sentiment and predict short-term market fluctuations.

[0074] Technical analysts use it to calculate and analyze technical indicators, such as MACD, RSI, Bollinger Bands, etc., to predict stock price trends.

[0075] Macroeconomic analysts analyze macroeconomic data, such as GDP, inflation rate, interest rate, etc., and assess the impact of the macroeconomic environment on the market.

[0076] The Strategy Generator is used to synthesize reports from various analysts to generate investment strategies and recommendations.

[0077] The hybrid communication protocol module designs a structured communication protocol that combines natural language dialogue and structured reports to ensure efficient information transfer and decision support between agents.

[0078] Among the advantages of structured reporting are:

[0079] Information transmission is concise and clear: it avoids lengthy natural language descriptions and achieves efficient information transmission.

[0080] Easy to process: The structured data format is easy for other agents to read and process quickly, improving the overall efficiency of the system.

[0081] Easy to record and trace: Structured reports can be easily recorded and traced, facilitating subsequent auditing and analysis.

[0082] Use natural language in debates and discussions between agents to promote deep reasoning and integration of different viewpoints. Natural language dialogue allows agents to flexibly express complex viewpoints and reasoning processes. Specific implementation methods include:

[0083] Dialogue Coordinator: Responsible for organizing and managing dialogues between agents to ensure that the dialogues proceed in an orderly manner.

[0084] Multi-round dialogue: Each round of dialogue focuses on a specific analysis point or suggestion, and the analysis results are discussed in depth through multiple rounds of dialogue.

[0085] Conversation recording and summary: The conversation process is recorded and summarized to form a final analysis report.

[0086] Preferably, the dynamic coordinator adopts reinforcement learning training, the algorithm adopts the PPO algorithm, and the reward function is the Sharpe ratio; the training data can be the historical data of US stocks from 2010 to 2023; to obtain the output: a dynamic weight allocation table (such as a technical analysis weight of 40%).

[0087] The implementation and optimization of communication protocols can be carried out through the following aspects:

[0088] Predefined data formats and templates: Ensure consistency and readability of information.

[0089] Real-time communication: Support real-time communication to ensure timely and accurate information transmission between agents.

[0090] Error handling mechanism: Able to detect and correct errors in the communication process to ensure the integrity and accuracy of information.

[0091] Privacy protection mechanism: Add a privacy protection mechanism to the communication protocol design to ensure the security of data transmission and the privacy between intelligent agents.

[0092] In addition, through machine learning algorithms, agents can learn the analysis methods and reasoning steps of other agents and improve their own analysis capabilities. According to market changes and analysis needs, the content and format of the communication protocol are dynamically adjusted to ensure that the system always adapts to the latest market environment. The system also has a feedback mechanism, where analysts and investors can provide feedback on the analysis results and suggestions of the agents to further optimize the performance of the system.

[0093] Regarding data collection and processing, fundamental data can collect data such as a company's financial statements, earnings reports, and insider trading. Sentiment data can collect data from social media platforms and news websites for sentiment analysts to analyze market sentiment. Technical data calculates and analyzes technical indicators of stocks, such as MACD, RSI, Bollinger Bands, etc. Macroeconomic data can be collected by collecting macroeconomic data such as GDP, inflation rate, interest rate, etc.

[0094] The core link in the multi-agent financial analysis system based on the Large Language Model (LLM) is to combine the analysis results of each agent to generate the final investment strategy. The specific process includes:

[0095] 1. Comprehensive analysis

[0096] Data collection: Collect structured reports and natural language conversation transcripts from each agent.

[0097] Data integration: Integrate the analysis results of different agents to form a comprehensive analysis framework.

[0098] Trend Analysis: Identify market trends and key factors and assess their impact on investment decisions.

[0099] Risk Assessment: Assess market risks and uncertainties, determine risk exposure and response strategies.

[0100] 2. Strategy Generation

[0101] Goal setting: Set goals for your investment strategy based on your investment objectives and risk appetite.

[0102] Strategy formulation: Combine the analysis results of each agent to formulate a specific investment strategy, including decisions to buy, sell or hold.

[0103] Risk control: Set stop-loss and take-profit points based on risk assessment results to ensure that the risks of the investment strategy are controllable.

[0104] Strategy optimization: Dynamically adjust investment strategies based on market changes and new data to ensure their effectiveness and adaptability.

[0105] 3. Report Generation

[0106] Report structure: Determine the structure of the report, including introduction, analytical results, strategic recommendations, and conclusions.

[0107] Content Writing: Write detailed report content based on the results of comprehensive analysis and strategy generation.

[0108] Chart assistance: Use charts and data visualization techniques to enhance the readability and intuitiveness of reports.

[0109] Review and revision: Review and revise the report to ensure the accuracy and completeness of the content.

[0110] 4. Enhanced explainability

[0111] Natural language generation: The analysis process and reasoning steps of each agent are clearly presented through natural language generation technology, enhancing the transparency and credibility of the system.

[0112] Report generation: Generate detailed analysis reports, including the analysis results and reasoning process of each agent, for reference by analysts and investors.

[0113] This paper proposes a multi-agent financial analysis framework based on a large language model (LLM), which achieves efficient, explainable and comprehensive financial data analysis by simulating the organizational structure and workflow of a real-world financial analysis team. This framework not only improves the accuracy and comprehensiveness of financial analysis, but also enhances the transparency and credibility of the system, providing a new decision support tool for the financial investment field.

[0114] As an example, the fundamental analyst agent fine-tunes LLM on the SEC financial report dataset, injects accounting standards knowledge base (such as GAAP / IFRS), analyzes financial statements, earnings reports, etc., and evaluates the intrinsic value of the company. The sentiment analyst agent integrates the BERT model and graph neural network (GNN) to identify the false information propagation chain in social media and filter noise data (such as advertising text) through the attention mechanism. The technical analyst agent is embedded in the TA-Lib knowledge base, calculates technical indicators (such as MACD, RSI) in real time, and implements data updates with a delay of less than 50ms based on the Apache Flink stream processing framework. The macroeconomic analyst agent links the machine learning model to predict macroeconomic trends (such as GDP growth rate, interest rate changes) and evaluates their systemic impact on the market. The strategy generator dynamically allocates agent weights through reinforcement learning (PPO algorithm), and the objective function is to maximize the historical strategy Sharpe ratio.

[0115] The structured report of the hybrid communication protocol module adopts JSON / XML format, contains mandatory fields (`key_metrics`, `analysis_conclusion`) and extensible fields (`custom_fields`), and supports dynamic adaptation to emergencies (such as geopolitical conflicts).

[0116]

[0117] When the confidence difference between the conclusions of the agents exceeds 30% or the market volatility exceeds two standard deviations of the historical mean, multiple rounds of debate are triggered and the dynamic coordinator decides the priority.

[0118] The dynamic coordinator uses weight distribution logic:

[0119] Bull market stage: technical analysis weighting 40%, sentiment analysis 30%, fundamentals 20%, macro 10%;

[0120] Bear market stage: fundamentals weight 35%, macro 30%, technical analysis 25%, sentiment analysis 10%.

[0121] Conflict resolution: If technical analysis is bullish (70% confidence) and sentiment analysis is bearish (65% confidence), the coordinator dynamically adjusts the weights based on the market stage.

[0122] The interpretability enhancement module includes:

[0123] Process explanation: Output the reasoning chain through natural language generation (NLG) (such as "P / E ratio>30→industry ranking in the top 10%→recommendation to reduce holdings").

[0124] Result interpretation: Visualize the contribution of key indicators through SHAP values ​​(such as "the decline in GDP growth rate contributes 35% of the strategy weight").

[0125] The structured report of this application improves the efficiency of cross-agent communication by 50% (actually measured compared with traditional natural language interaction).

[0126] Dynamic weight allocation increases the strategy's Sharpe ratio by 22% compared to the fixed weight model (based on the US stock backtest from 2010 to 2023). The full-process traceability design has passed the EU MiFID II simulation audit test.

[0127] Optionally, the explainability enhancement module dynamically outputs reasoning steps through natural language generation technology; visualizes the contribution of key indicators to the strategy through SHAP or LIME algorithm; the data fusion and strategy generation module integrates a cross-modal attention network, and synchronously processes text data streams and high-frequency trading time series data through a time alignment mechanism to achieve multi-dimensional feature cross-validation.

[0128] It is understandable that in the data fusion and strategy generation module, a cross-modal attention network is integrated to synchronously process text data streams (such as news, social media) and high-frequency trading time series data (such as stock prices, trading volumes) through a temporal alignment mechanism to achieve multi-dimensional feature cross-validation and improve the accuracy and robustness of strategy generation.

[0129] As an example, a cross-modal attention network can be designed as follows:

[0130] 1. Enter the branch:

[0131] -Text modality branch: processes unstructured text data (such as news headlines, social media tweets) and extracts semantic features using pre-trained language models (such as BERT).

[0132] -Time series modal branch: processes high-frequency trading data (such as stock prices and trading volumes per second) and uses time series neural networks (such as LSTM or Transformer) to extract time series features.

[0133] -Attention Fusion Layer:

[0134] -Through the cross-modal attention mechanism, the association weights between text features and temporal features are calculated.

[0135] -Formula Example:

[0136]

[0137] Among them, Q is the temporal feature, K and V are text features, and d k is the dimension scaling factor.

[0138] - Output the fused joint feature vector to capture the causal relationship between text events and market fluctuations (for example, the association between "a company's financial report release" and "an instantaneous jump in stock prices").

[0139] 2. Time alignment mechanism

[0140] -Dynamic Time Warping (DTW):

[0141] - For non-aligned text and transaction data (such as news release time and stock price sampling point are inconsistent), the DTW algorithm is used to align timestamps to ensure that the text and market reaction of the same event are analyzed synchronously.

[0142] - Sliding Window Synchronization:

[0143] - Define a time window (e.g., 5 minutes), aggregate text events within the window (e.g., multiple tweets) into a sentiment score, and match it with trading data (e.g., average price, volatility) for the same period.

[0144] 3. Multi-dimensional feature cross-validation

[0145] -Consistency check:

[0146] - If the sentiment analysis of the text shows "positive sentiment" and the stock price does not rise as expected during the same period, anomaly detection is triggered, indicating potential market manipulation or information lag.

[0147] -Attention weight analysis:

[0148] - Combine text keywords with high attention weights (such as "mergers and acquisitions" and "profit warning") with transaction characteristics (such as a surge in trading volume) to verify whether they are the driving factors of market changes.

[0149] Implementation Example

[0150] Scenario: Strategy generation for breaking news events

[0151] 1. Data input:

[0152] -Text stream: tweets about "Company A was exposed for financial fraud" appear in real time on social media;

[0153] - Trading flow: Company A’s share price fell 8% in 10 seconds, and trading volume increased to 5 times the daily average.

[0154] 2. Time Alignment:

[0155] -Use DTW to align the tweet release time (12:00:03) with the stock price drop time (12:00:05) and regard them as the same event window.

[0156] 3. Cross-modal attention calculation:

[0157] -The text branch extracts the keyword "financial fraud" and outputs a negative sentiment score (-0.9);

[0158] - Abnormal fluctuations are detected in the timing branch (fluctuation rate > 3σ);

[0159] -Attention weight shows that the correlation between "financial fraud" and stock price decline is 85%.

[0160] 4. Cross-validation and strategy generation:

[0161] -Verification logic: The negative sentiment of the text is consistent with the market crash, which is judged as a credible signal;

[0162] -Strategy output: immediately generates a recommendation of "short company A, with the stop loss set at -5% of the current price", and annotates the decision basis (such as "cross-modal attention weight > 80%) through an interpretable module.

[0163] This solution has the following advantages:

[0164] 1. Accurate time series correlation: Solve the time asynchrony problem between text and transaction data to avoid misjudgment of noise events.

[0165] 2. Heterogeneous data fusion: quantify the causal relationship between text and market through attention mechanism, surpassing traditional unimodal analysis.

[0166] 3. Dynamic risk control: Cross-validation can identify false information or market manipulation and improve the robustness of strategies.

[0167] The application scenarios of this solution include:

[0168] -High-frequency trading: Combine news events and market fluctuations in real time to generate millisecond-level trading signals.

[0169] -Risk warning: Detect the synergy between social media rumors and abnormal trading patterns to warn of risks in advance.

[0170] -Regulatory compliance: Provide traceable cross-modal correlation evidence to meet regulatory audit requirements for automated decision-making.

[0171] This solution significantly improves the system's adaptability to complex market environments by deeply integrating text and transaction data, and is particularly suitable for high-frequency and event-driven strategy scenarios.

[0172] Optionally, the strategy generator can also integrate a stress testing module to simulate extreme market scenarios (such as financial crisis data) to optimize the robustness of the strategy.

[0173] For example, simulation scenarios: the 2008 financial crisis and the 2020 epidemic market crash; output: generate alternative strategies (such as "it is recommended to hold a cash ratio of >50% under extreme volatility").

[0174] Optionally, the system can also set up a privacy protection module to encrypt communication data through homomorphic encryption technology to ensure privacy between intelligent agents.

[0175] The present invention solves the defects of traditional systems in terms of collaboration efficiency, analytical depth and compliance through multi-role intelligent agent division of labor, hybrid communication protocol, dynamic coordination mechanism and interpretable design. The system supports real-time data processing and extreme scenario stress testing, and verifies its performance advantages through quantitative indicators (such as a 22% increase in the Sharpe ratio). This solution can be widely used in investment decision support, risk warning and financial supervision scenarios.

[0176] Example 1: Agent collaboration and conflict resolution

[0177] - When the conclusions of technical analysis (70% confidence) conflict with those of sentiment analysis (65% confidence), the dynamic coordinator gives a higher weight to sentiment analysis (60%) based on the market stage (bearish market);

[0178] - Expand the `geopolitical_risk` field in structured reports to analyze the impact of political factors and other factors on prices.

[0179] Example 2: Data processing and real-time computing

[0180] - Emotional data cleaning: filtering noise through attention mechanism (F1 value increased to 89%);

[0181] - Technical indicator calculation: Stream processing is implemented based on Apache Flink, with a latency of less than 50ms.

[0182] Example 3: Explainability Implementation

[0183] - Audit trail: Add a digital signature (SHA-256) and data traceability label to the report (e.g. “Sentiment data source: Twitter API 2024-01-01 to 2024-03-01”);

[0184] -Visual output: SHAP value showing the contribution of GDP growth rate to the 35% of the strategy weight.

[0185] The present disclosure also provides a multi-agent financial analysis method based on a large language model, using the aforementioned multi-agent financial analysis system based on a large language model, the method comprising:

[0186] Process fundamental, sentiment, technical and macroeconomic data through multi-role agent modules;

[0187] Structured reports and natural language dialogues are delivered through a hybrid communication protocol module, and conflicts are resolved by a dynamic coordinator;

[0188] Dynamically adjust agent weights based on reinforcement learning to generate investment strategies;

[0189] Output dual explanation reports through natural language generation and feature attribution analysis.

[0190] This application uses a multi-role agent module to define multiple professional agent roles. By defining multi-role agents such as fundamental analysts and sentiment analysts, the functional division of real financial teams is mapped to the AI ​​system for the first time. Traditional methods rely on a single model or loose collaboration, while this solution simulates the real team collaboration process through role-based division of labor, filling the gap in organizational modeling in existing systems.

[0191] The structured communication protocol proposes a combination of natural language dialogue and structured reports (such as tables and templated data), solving the efficiency problem of pure natural language interaction. Existing systems (such as the ChatGPT financial plug-in) mostly rely on single language interaction, and this protocol improves information density and accuracy through structured data, which is an important improvement in the communication mechanism.

[0192] The explainable analysis module makes the analysis process transparent, using natural language generation (NLG) technology to dynamically explain the reasoning steps of each agent instead of just providing results. Compared with traditional explainability methods (such as feature importance analysis), this design is more in line with the cognitive habits of financial practitioners and enhances the credibility of decision-making.

[0193] The multi-source data integration engine integrates fundamentals, sentiment, technical indicators and macroeconomic data at the same time, and realizes in-depth analysis through the division of labor agents. Existing systems usually focus on a single data type (such as quantitative models only use historical prices), while this solution covers a more comprehensive analysis dimension through multi-agent collaboration.

[0194] This application proposes an integrated solution to the four major pain points of financial analysis (organizational modeling, communication efficiency, explainability, and analytical depth), rather than improving a single problem in isolation. For example, the structured communication protocol not only improves efficiency, but also supports explainability (such as annotating data sources and analysis logic) through a standardized format.

[0195] The deep coupling of large language models (LLMs) and multiple agents embeds the capabilities of large language models into the multi-role agent framework, which not only takes advantage of LLM's natural language processing advantages, but also avoids the lack of professionalism caused by its generalization through structured division of labor. For example, technical analyst agents can be trained to identify technical indicators in a targeted manner, rather than relying on the broad knowledge of general LLMs.

[0196] In addition, this application realizes the transformation of the financial analysis system from "tool" to "team". Traditional AI financial tools serve as passive response systems, while this application realizes an active and continuously iterative analysis process by simulating team collaboration (such as the strategy generator coordinating the conclusions of various analysts), which is closer to the working mode of human experts.

[0197] In addition, compared with the existing analysis system, this application has the following advantages:

[0198] Compared with a single-agent system (such as Bloomberg GPT): This solution solves the problem of complex task decomposition through multi-role division of labor, avoiding knowledge overload of a single model.

[0199] Compared with traditional multi-agent frameworks (such as MetaGPT): it introduces role design and structured communication protocols specific to the financial field to enhance domain adaptability.

[0200] Compared with explainability solutions (such as LIME / SHAP): through procedural natural language explanation rather than post-hoc attribution analysis, it is more in line with the financial regulatory needs for decision traceability.

[0201] In summary, the system simulates the organizational structure and collaboration process of a real financial analysis team, integrates multi-source data and generates explainable comprehensive investment strategies, significantly improving the efficiency, depth and credibility of financial analysis.

[0202] The technical solution of the embodiment of the present disclosure can be embodied in the form of a software product, which is stored in a storage medium and includes one or more instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in the embodiment of the present disclosure. The aforementioned storage medium may be a non-transient storage medium, including: a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, and other media that can store program codes, or a transient storage medium.

[0203] The above description and accompanying drawings fully illustrate the embodiments of the present disclosure so that those skilled in the art can practice them. Other embodiments may include structural, logical, electrical, process and other changes. The embodiments represent possible changes only. Unless explicitly required, separate components and functions are optional, and the order of operation may vary. The parts and features of some embodiments may be included in or replace the parts and features of other embodiments. Moreover, the words used in this application are only used to describe the embodiments and are not used to limit the scope of protection. As used in the description in the text, unless the context clearly indicates, the singular forms of "a", "an" and "the" are intended to include plural forms as well. Similarly, the term "and / or" as used in this application refers to any and all possible combinations of listings containing one or more associated ones. In addition, when used in the present application, the term "comprise" and its variants "comprises" and / or comprising refer to the presence of stated features, wholes, steps, operations, elements, and / or components, but do not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or groups thereof. In the absence of further restrictions, the elements defined by the sentence "comprising a ..." do not exclude the presence of other identical elements in the process, method or device comprising the elements. In this article, each embodiment may focus on the differences from other embodiments, and the same and similar parts between the embodiments may refer to each other. For the methods, products, etc. disclosed in the embodiments, if they correspond to the method part disclosed in the embodiments, then the relevant parts can refer to the description of the method part.

[0204] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software may depend on the specific application and design constraints of the technical solution. The technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the embodiments of the present disclosure. The technicians may clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here.

[0205] In the embodiments disclosed herein, the disclosed methods and products (including but not limited to devices, equipment, etc.) can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units can be only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between each other shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms. The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to implement this embodiment. In addition, each functional unit in the embodiment of the present disclosure may be integrated in a processing unit, or each unit may exist physically alone, or two or more units may be integrated in one unit.

Claims

1. A multi-agent financial analysis system based on a large language model, characterized in that: include: Multi-role agent module, including fundamental analyst, sentiment analyst, technical analyst, macroeconomic analyst and strategy generator. Each agent can achieve professional analysis through field-customized LLM. A hybrid communication protocol module integrates structured reports and natural language dialogues, wherein the structured reports are in JSON or XML format and contain mandatory fields and extensible fields; A dynamic coordinator module, configured to dynamically assign agent weights based on market stage and confidence differences; The explainability enhancement module outputs the reasoning logic chain through natural language generation technology and presents it visually; The data fusion and strategy generation module integrates fundamental, sentiment, technical and macroeconomic data to generate dynamic investment strategies.

2. The multi-agent financial analysis system according to claim 1, characterized in that: The explainability enhancement module dynamically outputs reasoning steps through natural language generation technology; visualizes the contribution of key indicators to the strategy through SHAP or LIME algorithms; The data fusion and strategy generation module integrates a cross-modal attention network, synchronously processes text data streams and high-frequency trading time series data through a time alignment mechanism, and realizes multi-dimensional feature cross-validation.

3. The multi-agent financial analysis system according to claim 1, characterized in that: The triggering mechanism of the structured report includes: Required fields are used for general analysis tasks; Extensible fields are used to adapt to unexpected events or add new analysis dimensions.

4. The multi-agent financial analysis system according to claim 1, characterized in that: Fundamental analysis agents, which analyze a company’s financial statements, earnings reports, and internal transaction data to assess the company’s intrinsic value; Sentiment analysis agents that process social media posts and news articles to analyze market sentiment and predict short-term market fluctuations; Technical analysis agents, which are used to calculate and analyze technical indicators of stocks to predict stock price trends; Macroeconomic analysis agent, which is used to analyze macroeconomic data to assess the impact of the macroeconomic environment on the market; The strategy generation agent is used to integrate the reports of the aforementioned analysis agents to generate investment strategies and recommendations.

5. The multi-agent financial analysis system according to claim 4, characterized in that: The fundamental analysis agent includes a data cleaning and processing sub-agent, which is used to standardize and clean the company's financial statements, earnings reports, and internal transaction data to improve the accuracy of the analysis; The strategy generation agent uses a machine learning algorithm to optimize the generation of investment strategies based on historical data.

6. The multi-agent financial analysis system according to claim 1, characterized in that: The triggering conditions of the natural language dialogue are: The confidence differences between the conclusions of the agents exceed 30%; Market volatility exceeds the historical mean by two standard deviations.

7. The multi-agent financial analysis system according to any one of claims 1 to 6, characterized in that: The sentiment analyst agent integrates a graph neural network to identify the propagation path of false information in social media and filters noisy data through an attention mechanism.

8. The multi-agent financial analysis system according to any one of claims 1 to 6, characterized in that: The technical analyst agent is embedded in the TA-Lib knowledge base for real-time calculation of technical indicators and achieves data update with a latency of less than 50ms through the Apache Flink stream processing framework.

9. The multi-agent financial analysis system according to any one of claims 1 to 6, characterized in that: The weight distribution logic of the dynamic coordinator module includes: Give more weight to technical analysis and sentiment analysis in the bull market phase; Give more weight to fundamental analysis and macroeconomic analysis in the bear market phase; Dynamic optimization is performed through reinforcement learning algorithm with maximizing the Sharpe ratio as the objective function.

10. A multi-agent financial analysis method based on a large language model, characterized in that: Using the multi-agent financial analysis system based on a large language model according to any one of claims 1 to 9, the multi-agent financial analysis method comprises: Process fundamental, sentiment, technical and macroeconomic data through multi-role agent modules; Structured reports and natural language dialogues are delivered through a hybrid communication protocol module, and conflicts are resolved by a dynamic coordinator; Dynamically adjust agent weights based on reinforcement learning to generate investment strategies; Output dual explanation reports through natural language generation and feature attribution analysis.

Citation Information

Cited By

  • Power transmission and distribution production task cooperation system and method based on intelligent agent

    CN120338452A

  • Multi-agent-based self-adaptive budget report generation method

    CN120449839A

  • Large-model-driven intelligent education resource recommendation method and system

    CN120509709A

  • Multi-agent collaboration system for financial investment

    CN120765182A

  • AI knowledge service system and method based on financial intelligent context protocol

    CN121213242A