A method and system for fund analysis agent based on MCP protocol architecture
By employing a fund analysis intelligent agent method based on the MCP protocol architecture, and leveraging the collaborative work of a large language model and specialized small models, the analysis workflow is dynamically generated, solving the rigidity and data governance problems of fund analysis systems and achieving efficient and multimodal presentation of analysis results.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SHANGHAI BIG DATA INC
- Filing Date
- 2026-04-08
- Publication Date
- 2026-07-31
AI Technical Summary
Existing financial analysis systems are unable to flexibly respond to complex and dynamic practical analysis needs, and suffer from problems such as rigid operators, weak cross-source heterogeneous data governance capabilities, inability to understand user intent, and insufficient professional computing capabilities.
We adopt a financial analysis intelligent agent method based on the MCP protocol architecture. By parsing user intent through a large language model, we dynamically generate analysis workflows of multiple professional small model intelligent agents. We combine the MCP protocol for scheduling and result fusion to achieve multimodal analysis results presentation.
It enables flexible responses to complex queries, improves analysis efficiency and depth, solves the problems of lack of intent understanding, fixed paths, single result display and difficulty in cross-source data governance in traditional systems, and significantly shortens analysis time.
Smart Images

Figure CN122492354A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and in particular to a method and system for financial analysis intelligent agents based on the MCP protocol architecture. Background Technology
[0002] Currently, the financial analysis solutions available on the market can be mainly divided into two categories, but they all have inherent technical bottlenecks and are difficult to meet the complex, dynamic and highly heterogeneous practical analysis needs.
[0003] The first type is an analysis system based on traditional rules and fixed operators. This system typically consists of a data access layer, a standardization processing layer, a fixed operator analysis layer, and a results display layer. The data access layer is responsible for accessing transaction flow data with diverse formats from multiple data sources. The standardization processing layer cleans and transforms the raw data using predefined, hard-coded data mapping rule tables. The fixed operator analysis layer consists of a series of pre-programmed analysis "operators," whose execution logic and parameters are fixed during the development phase. The results display layer presents the analysis results of the fixed operators in the form of charts or lists. Its analysis process is linear and rigid; users must choose from a limited set of analysis scenarios. The system calls a series of fixed operators based on preset scenarios, and cannot flexibly combine or adjust them according to dynamic changes in query intent.
[0004] The second category: Question answering systems based on large language models. These systems attempt to improve user experience by utilizing large language models. Users ask questions directly in natural language, and the model generates answers based on its internal training data.
[0005] However, both types of systems have significant drawbacks. The first type suffers from rigid operators, weak cross-source heterogeneous data governance capabilities, inability to understand user intent, and fixed analysis paths. The second type lacks specialized computing capabilities; its large language models are not adept at precise numerical calculations and complex relational reasoning, and it cannot directly interface with real-time data, resulting in answers lacking practical value. Summary of the Invention
[0006] To address the problems existing in the prior art, this invention provides a fund analysis intelligent agent method based on the MCP protocol architecture, comprising the following steps: Step S1: Obtain and parse the user's natural language query command to identify the user's financial analysis intent; Step S2: Based on the identified capital analysis intent, generate an analysis workflow plan consisting of multiple specialized small model agents; Step S3: The multiple specialized small model agents are invoked and scheduled to execute the tasks in the analysis workflow plan through the MCP protocol. The MCP protocol is a context interaction and scheduling protocol between the large language model and the specialized small model agents. Step S4: The results returned by the professional small model agent after performing the task are fused and processed to generate multimodal analysis results, which are then presented to the user.
[0007] Preferably, step S1 includes: Step S11: Input the user's natural language query command into the large language model; Step S12: The large language model interacts with the capital analysis knowledge base layer to retrieve subgraphs, pattern nodes and entities related to the query semantics from the technical and tactical knowledge graph and entity relationship graph stored in the capital analysis knowledge base layer. Step S13: Based on the retrieved subgraphs, pattern nodes and entities, the user instructions are deconstructed and expanded to generate a structured intent containing multiple sub-intents.
[0008] Preferably, step S2 includes: Step S21: The large language model identifies the analysis task types required to implement each sub-intent based on the multiple sub-intents contained in the structured intent; Step S22: Based on the analysis task type, determine the specialized small model agent to be invoked to complete each analysis task; Step S23: Based on the data dependencies and execution logic between each analysis task, arrange the determined specialized small model agents into an agent call sequence with a calling order; Step S24: Based on the agent call sequence, generate an executable workflow plan that includes the agent call sequence, input and output parameters, data dependencies, and parallel or conditional execution logic.
[0009] Preferably, step S3 includes: Step S31: The MCP server in the agent capability engine layer parses the executable workflow plan and obtains the agent call sequence and the data dependencies between tasks. Step S32: Based on the obtained agent call sequence and data dependencies between tasks, call the professional small model agents that have been registered on the MCP server in sequence or in parallel. Step S33: Pass intermediate results between the called specialized small model agents, maintain the task execution status, and ensure that the workflow is completed as planned.
[0010] Preferably, step S4 includes: Step S41: Obtain multiple output results returned by the professional small model agent after performing the task. The output results include at least two of the following: structured data, relational graph data, and text data. Step S42: Integrate the multiple output results according to the preset fusion rules, establish the correlation mapping between different modal data, and form a comprehensive analysis context; Step S43: Based on the comprehensive analysis context, generate multimodal analysis results that include at least two presentation formats among data tables, relationship graphs, and text descriptions; Step S44: The generated multimodal analysis results are presented to the user through the user interface.
[0011] Preferably, a heterogeneous data intelligent governance step is included before step S1: Step S01: In the data access phase, the original fund flow data is intelligently analyzed and standardized to generate standardized transaction data and store it in the case database. In step S3, the specialized small model agent invoked reads the standardized transaction data from the case database as the data source for the analysis task.
[0012] Preferably, step S01 includes: Step S011: The data governance intelligent agent reads the original header and multiple sample data from the original fund flow data; Step S012: Submit the read original table header and sample data to the large language model and request semantic matching; Step S013: Based on its natural language understanding capabilities, the large language model identifies the mapping relationship between the original table header and the fields of the system's standard data model, and returns it in JSON format; In step S014, the data governance intelligent agent executes the data transformation script according to the mapping relationship, completes the standardization processing of the data, outputs standardized transaction data, and stores it in the case database.
[0013] Preferably, after step S4, the method further includes: Step S5: Based on the multimodal evidence, and taking into account multiple dimensions such as fund size, transaction behavior anomaly, number of pattern matches, and network risk density, generate a quantitative risk score, level characterization, and disposal recommendations. Step S6: Input the generated risk score, level classification and treatment suggestions into the visualization rendering agent to generate an interactive multidimensional chart, and embed it into the multimodal analysis results to present to the user.
[0014] This invention also provides a financial analysis intelligent agent system based on the MCP protocol architecture, which applies the above-mentioned financial analysis intelligent agent method and includes: The intent parsing module is used to acquire and parse the user's natural language query commands to identify the user's financial analysis intent; The planning generation module, connected to the intent parsing module, is used to generate an analysis workflow plan consisting of multiple specialized small model agents based on the identified capital analysis intent. The scheduling and execution module is connected to the planning generation module and is used to call and schedule the multiple specialized small model agents to execute the tasks in the analysis workflow plan through the MCP protocol. The MCP protocol is a context interaction and scheduling protocol between the large language model and the specialized small model agents. The result fusion module, connected to the scheduling and execution module, is used to fuse the results returned by the specialized small model agent after it has performed the task, generate multimodal analysis results, and present them to the user.
[0015] Preferably, the intent parsing module includes: The instruction input unit is used to input the user's natural language query instructions into the large language model; The knowledge retrieval unit, connected to the instruction input unit, is used to enable the large language model to interact with the capital analysis knowledge base layer, and to retrieve subgraphs, pattern nodes and entities related to the query semantics from the technical and tactical knowledge graph and entity relationship graph stored in the capital analysis knowledge base layer; The intent generation unit, connected to the knowledge retrieval unit, is used to deconstruct and expand user instructions based on the retrieved subgraphs, pattern nodes, and entities to generate a structured intent containing multiple sub-intents.
[0016] The above technical solution has the following advantages or beneficial effects: 1. Directly parses user query intent, eliminating the need for manual breakdown into fixed operation steps, thus solving the problems of lack of intent understanding and high operation threshold in traditional systems.
[0017] 2. Based on intent-driven dynamic orchestration of multi-agent workflows, rather than calling preset operators, it can flexibly respond to arbitrarily complex queries, solving the defects of fixed analysis paths and long function expansion cycles.
[0018] 3. Responsible for semantic understanding and planning, while specialized small models are responsible for accurate calculations and data retrieval. This avoids the illusion of professional calculations found in pure large model solutions and solves the limitation of their inability to connect to real-time data.
[0019] 4. By using a unified architecture to achieve intelligent data governance, dynamic analysis and orchestration, and multimodal result presentation, it solves the problems of difficult cross-source data governance and single result display, reducing hours of manual analysis work to minutes, and significantly improving practical efficiency and depth. Attached Figure Description
[0020] Figure 1A flowchart illustrating a fund analysis intelligent agent method based on the MCP protocol architecture is shown in a preferred embodiment of the present invention. Figure 2 This is a schematic diagram of a sub-process of step S1 in a preferred embodiment of the present invention; Figure 3 This is a schematic diagram of a sub-process of step S2 in a preferred embodiment of the present invention; Figure 4 This is a schematic diagram of a sub-process of step S3 in a preferred embodiment of the present invention; Figure 5 This is a schematic diagram of a sub-process of step S4 in a preferred embodiment of the present invention; Figure 6 This is a schematic diagram of the sub-process of step S01 in a preferred embodiment of the present invention. Figure 7 This is a schematic diagram of an extended process for a financial analysis intelligent agent method based on the MCP protocol architecture, which is a preferred embodiment of the present invention. Detailed Implementation
[0021] The present invention will now be described in detail with reference to the accompanying drawings and specific embodiments. The present invention is not limited to this embodiment; other embodiments that conform to the spirit of the present invention may also fall within the scope of the present invention.
[0022] In a preferred embodiment of the present invention, based on the above-mentioned problems existing in the prior art, a financial analysis intelligent agent method based on the MCP protocol architecture is provided.
[0023] Example 1: This embodiment provides a financial analysis intelligent agent method based on the MCP protocol architecture. Taking an investigator's natural language query command: "Please help me find the largest single transfer Zhang San received in 2023 and tell me where this money came from," as an example, ... Figure 1 As shown, this method includes the following steps: Step S1: Obtain and parse the user's natural language query command to identify the user's financial analysis intent.
[0024] The system receives the aforementioned natural language commands through the interactive interface of the intelligent agent application layer. The large language model performs semantic parsing on the commands, identifying the core intent as querying the largest amount of payment transactions received by a specified subject (Zhang San) within a specific time range (2023) and the source of its funds. This process does not rely on any preset query templates, directly understanding the user's true needs, solving the problem of insufficient intent understanding in traditional systems. Users do not need to break down complex intents into multiple fixed operation steps, significantly lowering the barrier to entry.
[0025] Step S2: Based on the identified funding analysis intent, generate an analysis workflow plan consisting of multiple specialized small model agents.
[0026] Based on the parsed intent, the large language model dynamically generates an executable workflow plan consisting of multiple specialized smaller model agents. For example, this plan might include: Call the account query agent to retrieve all associated accounts under Zhang San; The transaction log retrieval agent is invoked to filter all payment transactions received in 2023 from the case database; Call the data analysis agent to sort the amounts and find the largest one; The information is used to associate the intelligent agent to trace the counterparty information of the transaction.
[0027] This plan is not a pre-defined pipeline, but rather it is orchestrated in real time based on the current query intent. This solves the problem of fixed analysis paths in traditional systems and can flexibly respond to various complex and ever-changing practical needs.
[0028] Step S3: Use the MCP protocol to call and schedule multiple specialized small model agents to execute tasks in the analysis workflow planning.
[0029] The MCP server in the agent capability engine layer receives the above plan and sequentially calls the registered specialized small model agents through the MCP protocol (the context interaction and scheduling protocol between large language models and specialized small model agents). The MCP server is responsible for transmitting intermediate results between agents (for example, using the account ID output by the account query agent as input to the transaction flow retrieval agent) and maintaining the execution status of the entire workflow. This mechanism seamlessly connects the cognitive planning capabilities of the large model with the precise execution capabilities of the small models, leveraging the advantages of the large model in intent understanding while avoiding the illusion problem of specialized computation in pure large model solutions. Precise amount sorting and data retrieval are all completed by specialized small models, ensuring the accuracy of the analysis results.
[0030] Step S4: The results returned by the professional small model intelligent agent after performing the task are fused and processed to generate multimodal analysis results, which are then presented to the user.
[0031] The system integrates structured transaction data and relational information returned by various agents to generate multimodal analysis results. For example, the user interface simultaneously displays a detailed list of transactions with the largest amounts, a simplified graph showing fund flows (e.g., Zhang San ← Li Si), and a summary text: "The largest transfer Zhang San received in 2023 was 500,000 yuan, from Li Si's account." This result presentation method, which integrates tables, graphs, and text, is intuitive and information-rich, solving the problems of traditional systems' limited result display and the need for manual extraction of analytical conclusions.
[0032] This embodiment constructs an automated mapping loop from natural language intent to professional analysis results through the above steps. Compared with existing technologies, the beneficial effects of this method are as follows: It solves the problems of lack of intent understanding and high operational threshold: users can ask questions directly using everyday language without having to learn complex system operations and fixed analysis scenarios, enabling frontline personnel to focus on the case itself rather than the use of tools.
[0033] It breaks through the limitations of fixed analysis paths: the system can dynamically orchestrate workflows for each unique query, adapting to ever-changing practical analysis needs, rather than being limited to a few preset modes.
[0034] It combines the cognitive advantages of large models with the precise computational capabilities of small models: through the MCP protocol, it achieves collaboration, which not only ensures the accurate understanding of complex semantics, but also ensures the accuracy and reliability of tasks such as numerical calculation and data retrieval, effectively overcoming the illusionary defects of pure large model solutions.
[0035] It enables a rapid transformation from data to insights: automated data retrieval, analysis, and multimodal presentation reduce manual analysis work that originally took hours or even days to minutes, significantly improving the efficiency and depth of financial analysis.
[0036] Example 2: As a further improvement to Example 1, this example refines step S1. For example... Figure 2 As shown, step S1 specifically includes the following sub-steps: Step S11, Instruction Input: Input the user's natural language query instruction into the large language model.
[0037] Step S12, Knowledge Retrieval: The large language model does not perform semantic understanding in isolation, but interacts with the underlying financial analysis knowledge base layer. This knowledge base layer stores a structured knowledge graph of tactics and techniques (storing crime patterns, behavioral characteristics, and their associations) and an entity relationship graph (storing networks of known involved entities). The model retrieves subgraphs, pattern nodes, and entities from these graphs that are semantically relevant to the query. For example, for a query analyzing whether account A is involved in money laundering, the model might retrieve pattern nodes related to money laundering (such as quick in-and-out transactions, breaking down large sums into smaller ones), as well as known risk entities associated with account A.
[0038] Step S13, Intent Generation: Based on the retrieved subgraphs, pattern nodes, and entities, the large language model deeply deconstructs and expands the user's original instructions. It breaks down the simple analysis of Account A into a complex, structured intent that penetrates the funds within Account A, analyzes behavioral characteristics based on the "quick in, quick out" and "break down into smaller units" patterns, and explores its second-level relationships. This enhanced intent provides a rich cognitive foundation for subsequent generation of more accurate and in-depth analytical workflow planning.
[0039] Example 3: This embodiment refines step S2, describing the specific transformation logic from structured intent to executable plan. For example... Figure 3 As shown, step S2 includes: Step S21, Task Type Identification: The large language model identifies the analysis task type required to achieve each sub-intent based on the structured intent generated in Example 2, which contains multiple sub-intents. For example, fund penetration corresponds to the link construction task, and behavioral feature analysis corresponds to the pattern recognition task.
[0040] Step S22, Agent Determination: Based on the identified analysis task type, determine the specialized small model agent required to complete each analysis task. For example, the link building task corresponds to the link building agent, and the pattern recognition task corresponds to the pattern recognition agent.
[0041] Step S23, call sequence orchestration: Based on the data dependencies and execution logic between each analysis task, the determined specialized small model agents are orchestrated into an agent call sequence with a clear calling order. For example, the link building agent needs to acquire transaction data first, so it depends on the output of the data acquisition agent.
[0042] Step S24, Plan Generation: Based on the orchestrated agent call sequence, a complete and executable workflow plan is generated. This plan not only includes the agent call sequence, but also defines in detail the input and output parameters of each agent, the data dependencies between tasks, and the parallel or conditional execution logic, forming a standardized description file (such as JSON format).
[0043] Example 4: This embodiment elaborates on step S3, describing the working process of the core scheduler. For example... Figure 4 As shown, step S3 includes: Step S31, Planning and Parsing: The MCP server in the agent capability engine layer receives and parses the executable workflow plan generated in Example 3, and accurately obtains the agent call sequence and the data dependencies between tasks.
[0044] Step S32, Agent Invocation: The MCP server dynamically, sequentially, or in parallel invokes specialized small model agents already registered in the server based on the parsed invocation sequence and data dependencies. For example, if two tasks have no data dependencies, they are invoked in parallel to improve efficiency.
[0045] Step S33, State Maintenance and Result Transmission: Between the called professional small model agents, the MCP server is responsible for transmitting intermediate results (such as using the output of the data acquisition agent as the input of the link construction agent) and continuously maintaining the task execution status of the entire workflow to ensure that the complex analysis chain can be completed smoothly as planned.
[0046] Example 5: This embodiment refines step S4, describing the processing flow from the original result to multimodal presentation. For example... Figure 5 As shown. Step S4 includes: Step S41, Result Acquisition: Acquire multiple output results returned by each specialized small model agent after performing the task. These results typically include at least two of the following: structured data (such as database query results), relational graph data (such as a list of nodes and edges), and text data (such as analysis conclusions).
[0047] Step S42, Evidence Fusion: The acquired multiple output results are integrated according to preset fusion rules to establish a correlation mapping between different modal data, forming a unified multimodal evidence body for this query. For example, the high-frequency transaction tags discovered by the pattern recognition agent are associated with specific transaction records in the transaction flow data.
[0048] Step S43, Result Generation: Based on the fused multimodal evidence body, generate multimodal analysis results containing at least two of the following presentation formats: data tables, relationship graphs, and text descriptions.
[0049] Step S44, Result Presentation: The final generated multimodal analysis results are presented to the user in a user-friendly way through the user interface.
[0050] Example 6: This embodiment adds a pre-processing step before step S1 to ensure the quality of the analyzed data. For example... Figure 7 As shown, the method also includes: Step S01, Heterogeneous Data Intelligent Governance: In the data access phase, the raw fund flow data is intelligently parsed and standardized to generate standardized transaction data, which is then stored in the case database. This step is the foundation for all subsequent analyses. It ensures that the various specialized small model agents invoked in Step S3, such as the AI data retrieval agent, can read standardized transaction data from a unified and standardized data source—the case database—when performing analysis tasks, thereby guaranteeing the accuracy of the analysis results.
[0051] Example 7: This embodiment refines step S01, describing how to achieve seamless data standardization using a large model. Combined with... Figure 6 , Figure 7 As shown, step S01 specifically includes: Step S011, Data Reading: When a user uploads a non-standard formatted transaction record Excel file, the intelligent agent capability engine layer calls the data governance intelligent agent. This intelligent agent first reads the original headers (such as "Transaction Date", "Payment / Received Amount", "Counterparty Name", "Loan / Debit Flag") and multiple rows of sample data from the file.
[0052] Step S012, Semantic Matching Request: The data governance agent submits the original table headers and sample data it reads, along with the standard data model defined within the system (including fields such as transaction_time, amount, counterparty_account, direction, etc.), to the large model service layer to request semantic matching.
[0053] Step S013, Mapping Relationship Generation: Based on its natural language understanding capabilities, the large model service layer identifies the semantic correspondence between the original table headers and standard fields, and generates mapping relationships. For example: Transaction date -> transaction_time; Payment amount -> amount; counterparty_account; Debit / Credit indicator -> direction (and can further identify that a debit represents a withdrawal and a credit represents an entry); The large model returns this mapping relationship to the data governance agent in JSON format.
[0054] Step S014, Data Conversion and Storage: The data governance intelligent agent dynamically generates and executes a data conversion script based on the received mapping relationship, extracts, converts, and loads the data from the original Excel file into the standard data model, and finally outputs standardized transaction data and stores it in the case database.
[0055] Example 8: This embodiment adds a step of in-depth analysis and visualization enhancement of the results after step S4 to provide more insightful data for decision-making. For example... Figure 7 As shown, the method also includes: Step S5, Risk Assessment: Based on the multimodal evidence body formed in Example 5, the system (which can be achieved through a dedicated risk profiling agent or by calling the large model again) comprehensively considers multiple dimensions such as capital scale, transaction behavior anomaly, number of pattern matches, and network risk density to generate a quantitative risk score, level characterization, and disposal recommendations.
[0056] Step S6, Visualization Enhancement: The conclusive information such as risk scores, levels, and treatment recommendations generated in Step S5 is input into the visualization rendering agent. This agent combines these conclusions with the original multimodal evidence to generate interactive multidimensional charts. For example, in a financial relationship graph, nodes with different risk levels are marked with different colors, or the thickness of lines indicates the level of risk. Finally, the enhanced chart is embedded into the initial multimodal analysis results and presented to the user, achieving a leap from simply seeing to understanding.
[0057] Example 9: This embodiment demonstrates how to use the method of the present invention to achieve automated governance of cross-source heterogeneous financial data.
[0058] Scenario Description: Police officers need to upload a non-standard formatted Excel file of transaction records exported from the YY branch of XX Bank. The system needs to automatically parse it and convert it into a standard format before storing it in the case database for subsequent analysis.
[0059] Participating components: User interface (belonging to the application layer of the intelligent agent): A web page that provides file upload functionality.
[0060] Data governance agent (belonging to the agent capability engine layer): a small model agent that encapsulates data parsing logic and has been registered on the MCP server.
[0061] Large Language Model Service (belonging to the Large Model Service Layer): Provides natural language understanding capabilities.
[0062] Standard data model: A unified transaction data format defined internally by the system, including fields such as transaction_time, amount, counterparty_account, and direction.
[0063] Case database: Stores standardized transaction data.
[0064] Specific steps and interactions (corresponding to steps S011 to S014): Step S011 (Data Reading): The user uploads a file named XX Bank Transaction Statement.xlsx through the user interface. The interface sends the binary data of this file and parsing instructions to the intelligent agent capability engine layer. The engine layer calls the data governance intelligent agent, which reads the original header of the Excel file (such as transaction date, payment amount, counterparty name, and loan / credit flag) and multiple rows of sample data.
[0065] Step S012 (Semantic Matching Request): The data governance agent submits the original table headers and sample data, along with the field definitions of the system's standard data model, to the large language model service and issues a request: Please perform semantic matching between the original table headers on the left and the standard fields on the right, and provide the mapping relationship.
[0066] Step S013 (Mapping Relationship Generation): Based on its natural language understanding capabilities, the large language model identifies the mapping relationship: Transaction date → transaction_time; Amount received / paid → amount; counterparty_account; Debit / Credit indicator → direction (and further identify that debit represents outgoing funds and credit represents incoming funds); The large model returns this mapping relationship to the data governance agent in JSON format.
[0067] Step S014 (Data Conversion and Storage): The data governance intelligent agent dynamically generates and executes a data conversion script based on the received mapping relationship. It extracts, converts, and loads the data from the original Excel file into the standard data model, completes the format unification (e.g., unifying December 5, 2023 into 2023-12-05), and finally outputs standardized transaction data and stores it in the case database.
[0068] Step-by-step instructions: This process follows a strict sequence; the steps cannot be interchanged. Files must be uploaded before parsing can begin, and semantic matching by a large model is essential for accurate data transformation.
[0069] This embodiment achieves zero-intervention, zero-operation, and seamless standardization of offline data in unknown formats, reducing the data cleaning work that originally required hours or days of manual effort to less than minutes, and providing a high-quality, unified data foundation for subsequent analysis.
[0070] Example 10: This embodiment demonstrates how the method of the present invention can be used to transform a simple user query into a deep, multi-dimensional analysis workflow through dynamic scheduling of Graph RAG and MCP.
[0071] Scenario description: A user inputs a natural language query: Analyze whether account A is involved in money laundering risks.
[0072] Technical process (corresponding to S11~S13, S21~S24, S31~S33, S41~S44): Phase 1: Deep intent parsing with graph augmentation (corresponding to S11-S13).
[0073] S11: Input the query command into the large language model.
[0074] S12: The large language model interacts with the capital analysis knowledge base layer to retrieve money laundering-related pattern nodes (such as quick in and out, breaking down large amounts into smaller ones, and multi-layer nesting) from the technical and tactical knowledge graph, and retrieves known risk entities that may be associated with account A from the entity relationship graph.
[0075] S13: Based on the search results, deconstruct the original instructions into structured intents: conduct [fund penetration] on account A, perform [behavioral feature analysis] based on the [quick in and quick out] and [break down into smaller units] patterns, and explore its [second-degree association].
[0076] Phase 2: Dynamic analysis and scheduling plan generation (corresponding to S21 to S24).
[0077] S21: The large language model identifies the required analysis task types based on structured intent: link building task, pattern recognition task, and network expansion task.
[0078] S22: Determine the specialized small model agents required to complete each task: link building agent, pattern recognition agent, and network expansion agent.
[0079] S23: Arrange the call sequence according to data dependencies: First, transaction data needs to be acquired, so the data acquisition agent should be called first; link building and pattern recognition can be executed in parallel, both depending on the output of data acquisition; network expansion depends on the result of link building.
[0080] S24: Generate an executable workflow plan, including agent call sequence, input and output parameters, data dependencies and parallel logic (such as parallel pattern recognition and link construction).
[0081] Phase 3: Parallelized Agent Cooperative Computation (corresponding to S31-S33) S31: The MCP server parses the workflow plan and obtains the call sequence and data dependencies.
[0082] S32: According to the plan, the MCP server first calls the data acquisition agent to extract the transaction history of account A from the case database; then it calls the link in parallel to build the agent and the pattern recognition agent.
[0083] S33: The MCP server transmits intermediate results between agents: it passes the output of the data acquisition agent to the link building and pattern recognition agents; and it passes the output of the link building agent to the network extension agent. Simultaneously, it maintains the execution status of each task.
[0084] Phase 4: Multimodal evidence fusion and correlation (corresponding to S41-S42) S41: Obtain the results returned by each agent: structured transaction data, fund flow diagram, pattern label (e.g., quick in and quick out confidence score of 0.9), and expanded association network.
[0085] S42: Integrate the above results to form a multimodal evidence body, such as attaching fast-in and fast-out tags to the corresponding nodes in the link, and performing collision verification between newly discovered related parties and risk entities in the knowledge base.
[0086] Phase 5: Comprehensive risk assessment and profile generation.
[0087] S5: The risk profiling agent is based on multimodal evidence and takes into account factors such as fund size, frequency of abnormal transactions, number of pattern matches, and network risk density to generate a risk score (e.g., 85 points), risk level (high risk), and disposal recommendations (recommend freezing and further investigation) for account A.
[0088] Phase 6: Presentation of interpretable results (corresponding to S43-S44).
[0089] S43: The visualization rendering agent receives the risk assessment conclusion and evidence, generates an interactive Sankey diagram to display the flow of funds, and marks high-risk nodes and paths with colors. At the same time, it generates a text conclusion containing risk scores and disposal suggestions.
[0090] S44: Present multimodal results (charts and text) to the user through the user interface.
[0091] This embodiment demonstrates how the system can automatically transform fuzzy natural language queries into in-depth, interpretable analysis results, achieving intelligent mapping from data to insights and greatly improving the efficiency and depth of financial analysis.
[0092] Example 11: This embodiment demonstrates how to use the method of the present invention to implement Text-To-Report and automatically generate structured financial analysis reports.
[0093] Scenario Description: User Instruction: Generate a comprehensive financial analysis report for Wang Moumou in the case of illegal business operations (Case XXX).
[0094] Participating components: Natural language interaction interface, large language model, MCP server, AI data retrieval agent, account profile analysis agent, transaction flow analysis agent, AI chart agent, AI report agent.
[0095] Specific steps and interactions (corresponding to S41~S44, and embodying multi-agent cooperation): Step S41 (Intent Recognition and Macro Planning): The large language model parses the instruction, identifies that a comprehensive report needs to be generated, the target subject is Wang Moumou, and the context is the XXX illegal business case. It plans a complex report generation workflow, including sub-tasks such as data acquisition, profile analysis, flow analysis, chart generation, and report synthesis.
[0096] Step S42 (MCP Scheduling and Cooperative Execution): The MCP server executes the plan, scheduling tasks based on their dependencies: First, the AI data retrieval agent is invoked to obtain basic information and transaction summary data of all of Wang's accounts from the case database.
[0097] Subsequently, the account profiling analysis agent (analyzing trading behavior and outputting tags such as high-frequency trading and active nighttime trading) and the flow analysis agent (analyzing major trading counterparties and capital size) are invoked in parallel. The AI charting agent (generating monthly trading trend charts and pie charts of capital distribution among major counterparties) are also invoked. All three tasks rely on the output of the AI data retrieval agent, but they are independent of each other and can be executed in parallel.
[0098] Step S43 (Report Synthesis): The output results of all the above agents (summary data, profile tags, analysis conclusions, chart data) are submitted to the AI report agent.
[0099] Step S44 (Structured Report Generation): The AI-powered report intelligence embeds report templates and generation logic. After receiving input, it integrates information and formats the text, ultimately generating a structured Word or PDF document. The report content typically includes: Chapter 1: Main Overview (Based on the Results of the Data Acquisition Agent) Chapter 2: Transaction Feature Analysis (Based on Account Profile Intelligent Agent Results); Chapter 3: Analysis of Fund Flows (Based on the Results of the Flow to the Intelligent Agent); Chapter 4: Key Charts (Embedded Trend Charts and Distribution Charts); Chapter 5: Comprehensive Analysis Conclusion (A summary judgment is generated by the large model or reporting agent by integrating the aforementioned information).
[0100] Step-by-step instructions: This process is partially parallel and partially sequential. Data retrieval begins first, followed by profile analysis, flow analysis, and chart generation, which can be executed in parallel. The final report synthesis can only begin after all preceding tasks are completed; the order is not interchangeable. The MCP server is responsible for managing and scheduling this complex task dependency.
[0101] This embodiment simplifies the work of manually compiling, analyzing, and writing multiple documents that investigators originally needed to do, into a single natural language command that automatically generates a professional analysis report with a complete structure and detailed data, greatly improving case-handling efficiency.
[0102] The above are merely preferred embodiments of the present invention and are not intended to limit the implementation methods and protection scope of the present invention. Those skilled in the art should recognize that any equivalent substitutions and obvious changes made using the content of this specification and illustrations should be included within the protection scope of the present invention.
Claims
1. A method of a fund analysis agent based on a MCP protocol architecture, characterized in that, Includes the following steps: Step S1: Obtain and parse the user's natural language query command to identify the user's financial analysis intent; Step S2: Based on the identified capital analysis intent, generate an analysis workflow plan consisting of multiple specialized small model agents; Step S3: The multiple specialized small model agents are invoked and scheduled to execute the tasks in the analysis workflow plan through the MCP protocol. The MCP protocol is a context interaction and scheduling protocol between the large language model and the specialized small model agents. Step S4: The results returned by the professional small model agent after performing the task are fused and processed to generate multimodal analysis results, which are then presented to the user.
2. The method of claim 1, wherein, Step S1 includes: Step S11: Input the user's natural language query command into the large language model; Step S12: The large language model interacts with the capital analysis knowledge base layer to retrieve subgraphs, pattern nodes and entities related to the query semantics from the technical and tactical knowledge graph and entity relationship graph stored in the capital analysis knowledge base layer. Step S13: Based on the retrieved subgraphs, pattern nodes and entities, the user instructions are deconstructed and expanded to generate a structured intent containing multiple sub-intents.
3. The method of claim 2, wherein, Step S2 includes: Step S21: The large language model identifies the analysis task types required to implement each sub-intent based on the multiple sub-intents contained in the structured intent; Step S22: Based on the analysis task type, determine the specialized small model agent to be invoked to complete each analysis task; Step S23: Based on the data dependencies and execution logic between each analysis task, arrange the determined specialized small model agents into an agent call sequence with a calling order; Step S24: Based on the agent call sequence, generate an executable workflow plan that includes the agent call sequence, input and output parameters, data dependencies, and parallel or conditional execution logic.
4. The method of claim 3, wherein, Step S3 includes: Step S31: The MCP server in the agent capability engine layer parses the executable workflow plan and obtains the agent call sequence and the data dependencies between tasks. Step S32: Based on the obtained agent call sequence and data dependencies between tasks, call the professional small model agents that have been registered on the MCP server in sequence or in parallel. Step S33: Pass intermediate results between the called specialized small model agents, maintain the task execution status, and ensure that the workflow is completed as planned.
5. The method of claim 4, wherein, Step S4 includes: Step S41: Obtain multiple output results returned by the professional small model agent after performing the task. The output results include at least two of the following: structured data, relational graph data, and text data. Step S42: Integrate the multiple output results according to the preset fusion rules, establish the correlation mapping between different modal data, and form a comprehensive analysis context; Step S43: Based on the comprehensive analysis context, generate multimodal analysis results that include at least two presentation formats among data tables, relationship graphs, and text descriptions; Step S44: The generated multimodal analysis results are presented to the user through the user interface.
6. The method of claim 1, wherein, The heterogeneous data intelligent governance step is included before step S1: Step S01: In the data access phase, the original fund flow data is intelligently analyzed and standardized to generate standardized transaction data and store it in the case database. In step S3, the specialized small model agent invoked reads the standardized transaction data from the case database as the data source for the analysis task.
7. The method of claim 6, wherein, Step S01 includes: Step S011: The data governance intelligent agent reads the original header and multiple sample data from the original fund flow data; Step S012: Submit the read original table header and sample data to the large language model and request semantic matching; Step S013: Based on its natural language understanding capabilities, the large language model identifies the mapping relationship between the original table header and the fields of the system's standard data model, and returns it in JSON format; In step S014, the data governance intelligent agent executes the data transformation script according to the mapping relationship, completes the standardization processing of the data, outputs standardized transaction data, and stores it in the case database.
8. The method of claim 5, wherein, The process following step S4 also includes: Step S5: Based on the multimodal evidence, and taking into account multiple dimensions such as fund size, transaction behavior anomaly, number of pattern matches, and network risk density, generate a quantitative risk score, level characterization, and disposal recommendations. Step S6: Input the generated risk score, level classification and treatment suggestions into the visualization rendering agent to generate an interactive multidimensional chart, and embed it into the multimodal analysis results to present to the user.
9. A funds analysis agent system based on a MCP protocol architecture, characterized in that, The application of the financial analysis intelligent agent method as described in any one of claims 1-8 includes: The intent parsing module is used to acquire and parse the user's natural language query commands to identify the user's financial analysis intent; The planning generation module, connected to the intent parsing module, is used to generate an analysis workflow plan consisting of multiple specialized small model agents based on the identified capital analysis intent. The scheduling and execution module is connected to the planning generation module and is used to call and schedule the multiple specialized small model agents to execute the tasks in the analysis workflow plan through the MCP protocol. The MCP protocol is a context interaction and scheduling protocol between the large language model and the specialized small model agents. The result fusion module, connected to the scheduling and execution module, is used to fuse the results returned by the specialized small model agent after it has performed the task, generate multimodal analysis results, and present them to the user.
10. The MCP protocol architecture based funds analysis agent system according to claim 9, characterized in that, The intent parsing module includes: The instruction input unit is used to input the user's natural language query instructions into the large language model; The knowledge retrieval unit, connected to the instruction input unit, is used to enable the large language model to interact with the capital analysis knowledge base layer, and to retrieve subgraphs, pattern nodes and entities related to the query semantics from the technical and tactical knowledge graph and entity relationship graph stored in the capital analysis knowledge base layer; The intent generation unit, connected to the knowledge retrieval unit, is used to deconstruct and expand user instructions based on the retrieved subgraphs, pattern nodes, and entities to generate a structured intent containing multiple sub-intents.