Financial report data lake construction method, data analysis and retrieval method and intelligent agent

By constructing a financial reporting data lake and combining it with a large language model, the problem of low efficiency in analyzing large-scale financial reporting datasets was solved, achieving the effect of rapid retrieval and generation of analytical answers.

CN121636754APending Publication Date: 2026-03-10CHONGQING INST OF ENG
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-15
Publication Date
2026-03-10

AI Technical Summary

Technical Problem

In large-scale financial reporting datasets, analysis is inefficient, making it difficult to quickly retrieve and obtain the information users need.

Method used

We construct a financial reporting data lake, which includes multiple databases and a semantic layer. By preprocessing and vectorizing the financial report content, and combining it with a large language model for agent analysis, we can achieve rapid retrieval and generation of analytical answers.

Benefits of technology

It improves the efficiency of analysis on large-scale financial reporting datasets, enabling users to quickly locate and generate the financial reporting analysis results they need.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121636754A_ABST
    Figure CN121636754A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of intelligent data analysis and retrieval, and particularly discloses a data lake construction method of a financial report, a data analysis and retrieval method and an intelligent agent. The data lake construction method of the financial report comprises the steps of preprocessing financial report data based on content and entities of the financial report data to obtain a plurality of databases representing different information; and setting a semantic layer, wherein the semantic layer comprises function description and calling functions of each database. A data lake is constructed based on the financial report data, the plurality of databases, and the semantic layer. A data analysis and retrieval method is further realized on the basis of the data lake, and an intelligent agent based on a large language model is constructed on the basis of the data analysis and retrieval method to output required financial report analysis and retrieval answers to a user. According to the method, the utilization rate of financial report data is remarkably improved, a reliable financial report analysis assistant is provided for financial analysis users, and the working efficiency of the users is greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of data intelligent analysis retrieval, and discloses a data lake construction method for financial reports, a data analysis retrieval method and an intelligent agent. BACKGROUND

[0002] Financial reports summarize the financial activities, performance and status of a company within a specific period. Different financial information users can find corresponding financial indicators from these reports based on their own needs, and then understand the business advantages of the enterprise, discover potential management problems and identify major risks by in-depth analysis of the financial reports.

[0003] Financial managers or researchers in the financial industry often have the need to analyze the trend of a certain financial indicator in the financial reports of a company over many years to gain insights into the growth of the company, such as examining the changes in the company's liabilities, or to compare the financial indicators of multiple companies in the same industry to observe the position of a company in the same industry, for example, to examine the profitability of the company in the same industry.

[0004] In the above scenarios, the financial reports may reach as high as tens of thousands, and the huge amount of financial reports can form a large-scale financial report set. If agentic analysis can be performed on this large-scale data set, it can not only help financial analysts and managers analyze enterprise performance and gain insights into industry development, but also provide decision support for investment.

[0005] Agentic analysis is a very popular emerging field in the field of business intelligence and data analysis. Simply put, agentic analysis refers to a self-directed, goal-oriented data analysis process driven by artificial intelligence agents (AI agents). It is not just a traditional data visualization or business intelligence tool, but an AI partner that can actively think, plan and execute complex analysis tasks.

[0006] The purpose of the present application is to develop a data intelligent agent for large-scale financial reports to achieve the purpose of quickly retrieving, efficiently extracting relevant content and generating user-required answers in large-scale financial report data sets. SUMMARY

[0007] The purpose of the present application is to provide a large-scale financial report data analysis retrieval method and system based on intelligent agents to solve the problem of low analysis efficiency of large-scale financial report data sets. The specific scheme is as follows: In a first aspect, a data lake construction method for financial reports is provided, comprising: Based on the content of the financial report data and the entity pre-processing of the financial report data, a plurality of databases representing different information are obtained; A semantic layer is set, which includes the function description of each database and the calling function.

[0008] Based on the financial report data, the plurality of databases and the semantic layer, a data lake is constructed; Further, the database at least includes: A first vector database constructed based on the content of the financial report; Based on the enterprise entity relationship in the financial report, a graph database with an enterprise correlation graph is constructed; Based on the enterprise entity and the corresponding financial indicators in the financial report, a relational database with enterprise financial information is constructed; Based on the industry information content of the enterprise entity in the financial report, a second vector database is constructed; Based on the product information content of the enterprise entity in the financial report, a third vector database is constructed.

[0009] Further, the first vector database constructed based on the content of the financial report is specifically: The content of the financial report is divided into a block sequence including text paragraphs and tables to form a block list; Text paragraphs with a character number exceeding a first character preset number are segmented into text paragraphs with partially overlapping content, and the segmented text paragraphs are stored as independent blocks; Text paragraphs with a character number less than a second character preset number are merged with the previous text paragraph to form a new text paragraph, and the merged text paragraph is stored as an independent block; The vertical line symbol is used as the separator of the cells in the table to convert the table content into text format, and the text content obtained by converting each table is stored as an independent block; The text content in each independent block is converted into a vector and stored in the first vector database.

[0010] Further, the block is stored in JSON format, and each block includes the following key values: The type key value is used to identify whether the block is a table or a text paragraph; The text key value is used to store the text content; The context key value is used to provide context information for the block.

[0011] Further, the context key value of the text paragraph includes the text content of the corresponding text paragraph and the title information of the chapter where it is located; The context key value of the table includes the text content of the text paragraphs before and after the table and the title information of the chapter where the table is located.

[0012] In a second aspect, a data analysis retrieval method for financial reports is provided, which is used for analyzing and retrieving the data lake constructed by the data lake construction method for financial reports described above; specifically comprising: obtaining a set of financial reports based on the enterprise entity related information in the user question; then obtaining a task list according to the user question and the set of financial reports; querying the long-term memory according to the task information in the task list to determine whether there is a same historical task, if yes, extracting and saving the analysis retrieval answer in the short-term memory, otherwise generating an operator according to the task information, and obtaining an operator list; executing each operator in the operator list, and saving the operator corresponding to each task and the execution result of the operator in the short-term memory and the long-term memory; generating an analysis retrieval answer according to the definition of each task saved in the short-term memory, the execution result of the operator corresponding to each task, and the user question.

[0013] Further, the way of obtaining a set of financial reports based on the enterprise entity related information in the user question at least includes one of the following ways: directly positioning to the financial report data based on the enterprise entity and the time in the user question, and forming a set of financial reports; querying and obtaining the enterprise correlation graph of the enterprise entity in the graph database in the data lake based on the enterprise entity in the user question, then obtaining the financial report data of all enterprises in the enterprise correlation graph, and forming a set of financial reports; querying and obtaining the enterprise entity information in the industry based on the industry information in the user question in the second vector database in the data lake, then obtaining the financial report data of all enterprise entities in the industry, and forming a set of financial reports; querying and obtaining the enterprise entity information producing the product based on the product information in the user question in the third vector database in the data lake, then obtaining the financial report data of all enterprise entities producing the product, and forming a set of financial reports.

[0014] Further, the production of the operator according to the task information specifically comprises: inputting the task description, question and description of the selected operator into the classifier to obtain a score; selecting the operator with the highest score as the classification result; the classifier includes a pre-trained cross-encoder and a Sigmoid layer connected thereto.

[0015] Further, the short-term memory is stored through a JSONL file, and when a new user question is input, the JSONL file storing the short-term memory is emptied. The long-term memory data is stored in a fourth vector database, and the fourth vector database stores historical user questions, analysis and retrieval answers corresponding to the user questions, tasks and task execution results.

[0016] In a third aspect, an agent is provided for analyzing and retrieving the data lake constructed by the data lake construction method of the financial report. A locator is configured to obtain a set of financial reports based on enterprise entity related information in the user question; A task decomposition module is configured to obtain a task list based on the user question and the set of financial reports; An operator generation module is configured to query the long-term memory based on task information in the task list to determine whether there is a same historical task, extract and save the analysis and retrieval answer in the short-term memory if there is, or generate an operator based on the task information and obtain an operator list if there is not; A task execution module is configured to execute each operator in the operator list, and save each task corresponding operator and the execution result of the operator in the short-term memory and the long-term memory; An answer generation module is configured to generate an analysis and retrieval answer based on the definition of each task saved in the short-term memory, the execution result of each task corresponding operator and the user question.

[0017] The present application has the following advantages: A large amount of financial report data is preprocessed to obtain a financial report data lake, and through the multiple databases in the data lake and the database function description and function calling information in the semantic layer, the user can quickly retrieve and obtain the required information in the large amount of financial report data; And based on the constructed financial report data lake, a data analysis and retrieval method based on a large language model is proposed to quickly generate a corresponding financial report analysis and retrieval answer based on a user question. BRIEF DESCRIPTION OF DRAWINGS

[0018] Figure 1 The structure of the data lake in the present application; Figure 2 The structure of the classifier in the operator generation module of the present application; Figure 3 The structure of the agent provided by the present application; Figure 4 The flowchart of the data lake construction method of the financial report of the present application; Figure 5 The flowchart of the data analysis and retrieval method of the financial report of the present application. DETAILED DESCRIPTION

[0019] In order to make the purposes, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. Obviously, the described embodiments are some but not all of the embodiments of the present application. The components of the embodiments of the present application described and shown in the drawings herein can be arranged and designed in various different configurations.

[0020] For financial workers and investors, the financial report of an enterprise is the main channel for them to understand the corresponding enterprise and industry, but it is often difficult to quickly and accurately find the required information in the face of a large number of enterprise financial reports. Based on the rapid development of current large language models, a large number of artificial intelligence agents applied in various fields have emerged. In order to efficiently analyze and search a large number of enterprise financial reports, the present application proposes to preprocess enterprise financial report data and then construct a data lake suitable for enterprise financial reports. On the basis of the data lake, a data analysis and retrieval method for intelligent agents is proposed to provide a reliable financial report analysis assistant for financial workers and investors, greatly improving the work efficiency of users.

[0021] The intelligent agent with data analysis and retrieval capability in the present application can plan according to the questions raised by the user. First, it will locate a set of financial report data related to the question, and then retrieve the corresponding content on the corresponding financial report according to the question, and finally generate an analysis and retrieval answer.

[0022] The method of the present application can cope with various questions raised by the user, including: the question can be only for a specific financial report, such as: what is the asset load rate of listed company TCL Technology in 2024? It can also be necessary to analyze multiple financial reports of multiple enterprises, such as: what is the average profit rate of the wind power industry in 2024? Or an analysis of the change of financial indicators of an enterprise over time, such as: the change of gross profit rate of TCL Technology in the past 5 years. The above are only examples of regular user questions. The user questions that the present application can handle and the help provided to users are far more than this.

[0023] In addition, it should be noted that the financial report data involved in the present application are all publicly disclosed financial report data of enterprises (such as listed companies) or financial report data of the user's own enterprise.

[0024] Embodiment 1 In order to enable the agent to quickly and conveniently use the financial report data obtained in a legal and compliant manner. In the embodiment, a data lake construction method of financial report is provided. The method forms a plurality of databases from the preprocessed and processed financial report data, each database has an access interface and a related semantic description to form a semantic layer. Further, based on the financial report data set, the required data lake is formed by combining the plurality of preprocessed databases and the corresponding semantic layer.

[0025] The above method process specifically includes: Based on the content of the financial report data and the entity, the financial report data is preprocessed to obtain a plurality of databases representing different information; specifically as follows: The first vector database constructed based on the content of the financial report.

[0026] Based on the enterprise entity relationship in the financial report, a graph database with enterprise association graph is constructed; such as the financial report of listed companies describes its holding or shareholding enterprises. The enterprise association graph is constructed by obtaining the holding relationship of the target enterprise, and the obtained enterprise association graph is stored in the graph database.

[0027] Based on the enterprise entity and the corresponding financial indicators in the financial report, a relational database with enterprise financial information is constructed; the basic information of the enterprise entity and the corresponding financial indicator data are extracted from the "company profile and main financial indicators" in the financial report, and the extracted data is saved in the relational database. "Company profile and main financial indicators" usually appear in the second section of the financial report, so when preprocessing data, the above-mentioned basic information of the enterprise entity and the corresponding financial indicator data can be preferentially searched in the second section of the financial report, thereby speeding up the data preprocessing speed. In addition, the main financial indicators include but are not limited to asset liability information, profit information, cash flow information, revenue and R&D investment, etc.

[0028] Based on the industry information content of the enterprise entity in the financial report, a second vector database is constructed.

[0029] Based on the product information content of the enterprise entity in the financial report, a third vector database is constructed.

[0030] In addition, based on the key management personnel information in the financial report, a fifth vector database can also be constructed.

[0031] The purpose of the first vector database is to locate a specific content in the financial report of an enterprise after locating the enterprise. The purpose of the second vector database to the third vector database, the fifth vector database, the graph database, and the relational database is to locate the financial report data of an enterprise involved in a problem after decomposing the problem into one or more specific tasks according to the user question.

[0032] A semantic layer is set, which includes the function description of each database and the calling function. Specifically, the semantic layer provides the function description of the databases in the data lake and also includes the function description of calling the data set for information retrieval. Its functions include: (1) To enable the agent to decompose the problem into the calling of the specific database in the data lake when planning, that is, to provide the function description of the database. The function description of the database refers to what kind of data information can be obtained based on the database. For example, based on the aforementioned graph database, the enterprise association relationship of the target enterprise entity can be obtained, such as the subsidiaries, branches, and parent companies of the target enterprise entity.

[0033] (2) To enable the agent to call and access the specific data in the database, the calling function description for accessing the specific data in the database is provided. It should be noted that the calling function can also be referred to as an operator.

[0034] For ease of understanding, Table 1 shows the definition and corresponding description of some operators (i.e., calling functions) in the semantic layer.

[0035] Table 1: Operator definition and description

[0036] It should be noted that the operator can be set according to the user's needs and the characteristics of the financial report data, that is, the operator is not limited to the definition and description presented in Table 1.

[0037] Based on the financial report data, multiple databases, and the semantic layer, a data lake is constructed, as shown in Figure 1 The data lake is constructed based on the financial report data set and serves as the data foundation for subsequent data agents.

[0038] For the above data lake, the data stored in the second vector database to the third vector database, the fifth vector database, the graph database, and the relational database is relatively clear and easy to retrieve. However, the data stored in the first vector database is the vectorization of the entire financial report content, and the data size is large. If not further processed, the retrieval efficiency will be greatly reduced. Therefore, the financial report content information needs to be processed as follows before being stored in the first vector database.

[0039] Firstly, the content of the financial report is decomposed into a block sequence including text paragraphs and tables, forming a block list. Among them, the block is stored in JSON format, and each block includes the following key values: type key value, used to identify whether the block is a table or a text paragraph; text key value, used to store the text content; context key value, used to provide context information for the block.

[0040] Among them, the context key value of the text paragraph includes the text content of the context corresponding to the text paragraph and the title information of the chapter where it is located; the context key value of the table includes the text content of the text paragraphs before and after the corresponding table and the title information of the chapter where it is located.

[0041] Text paragraphs with a character number exceeding a first character preset number are segmented into text paragraphs with partially overlapping content, and the segmented text paragraphs are stored as independent blocks. For example, the first character preset number is set to 100 words, and the number of overlapping words in the partially overlapping content can be set to 5 words; of course, the specific number of words can be flexibly set based on the hardware performance and needs of the user.

[0042] Text paragraphs with a character number less than a second character preset number are merged with the previous text paragraph to form a new text paragraph, and the merged text paragraph is stored as an independent block. For example, the second character preset number is set to 50 words, which should be less than or equal to half of the first character preset number.

[0043] It should be noted that after the text paragraph with a character number exceeding the first character preset number is segmented, the character number of the segmented text paragraph will still be greater than the second character preset number due to the inclusion of overlapping characters. If the character number of the new text paragraph formed by merging the text paragraph with a character number less than the second character preset number with the previous text paragraph is greater than the first character preset number, the new text paragraph at this position can be further segmented into text paragraphs with partially overlapping content. Of course, it is also feasible to set that the new text paragraph formed after merging is not segmented.

[0044] For table block data, the vertical line symbol is used as the separator of the cells in the table to convert the table content into text format for presentation, and the text content obtained by converting each table is stored as an independent block; for table data, not only the chapter title is used as its context, but also the surrounding text paragraphs are included as part of the context to provide background information for the table, thereby more effectively realizing the retrieval of the table.

[0045] The text content in each independent block is converted into a vector and stored in the first vector database. Specifically, when constructing a real-valued vector for each block, the context and text part in its JSON object are spliced into a single text paragraph (for tables, numerical cell content will be excluded); then the merged text is converted into a vector by the text encoder and stored in the first vector database.

[0046] Based on the specific scheme in embodiment 1, a large amount of financial report data is preprocessed to obtain a financial report data lake. Through the multiple databases in the data lake and the database function description and function calling information in the semantic layer, it is convenient for users to quickly search for the required information in the large amount of financial report data.

[0047] Embodiment 2 In order to be able to quickly analyze and search through the agent constructed based on the large language model, on the basis of the data lake constructed in embodiment 1, a data analysis and search method for the financial report of the data lake is provided, which is used for quickly analyzing and searching the constructed data lake, and outputting the analysis and search answers obtained based on the user questions.

[0048] The data analysis and search method for the financial report in this embodiment specifically includes: Based on the enterprise entity related information in the user question, a set of financial reports is obtained; this part is implemented by the locator in the agent. Specifically, the locator needs to discover the involved financial report according to the question submitted by the user, and then obtain and generate a set of financial reports (including the codes of listed companies and years, etc.).

[0049] The working process of the locator here includes multiple cases, and the specific cases are described as follows: Case 1: Directly locate the financial report data based on the enterprise entity and time in the user question, and form a set of financial reports; for example: based on the specific financial report that can be directly located in the user question, for example: the 2024 operating income of TCL Technology. In this way, the locator uses the large language model to extract the enterprise entity name and year, and can directly locate a financial report.

[0050] Case 2: Based on the enterprise entity in the user question, query the enterprise association graph of the enterprise entity in the graph database in the data lake, then obtain the financial report data of all enterprises in the enterprise association graph, and form a financial report set; for example, the user question is: What are the associated companies of TCL Technology? In this case, the specific company involved, TCL Technology, is first located, and then the associated companies of TCL are queried in the data lake. The implementation method of finding associated companies is that the large language model locates which database needs to be searched according to the question and the semantic layer of the data lake, for example, the current question is located to the enterprise association graph, and then an operator (i.e., a function call) for searching in the graph database is generated.

[0051] Case 3: Based on the industry information in the user question, query the enterprise entity information in the industry in the second vector database in the data lake, obtain the financial report data of all enterprise entities in the industry, and form a financial report set. In this case, the user question does not mention a specific company, and according to the content of the question, a corresponding operator is generated to retrieve the corresponding financial report. For example, the user question is: What is the average profit of the photovoltaic industry in 2024? An operator needs to be generated to search for companies belonging to the photovoltaic industry in the second vector database.

[0052] Case 4: Based on the product information in the user question, query the enterprise entity information producing the product in the third vector database in the data lake, obtain the financial report data of all enterprise entities producing the product, and form a financial report set. In this case, the user question also does not mention a specific company, and according to the content of the question, a corresponding operator is generated to retrieve the corresponding financial report. For example, the user question is: Which company has the highest profit margin among the companies producing photovoltaic panels? An operator needs to be generated to search for companies with photovoltaic panel products in the third vector database.

[0053] It should be noted that the above cases are only examples and scheme designs of common cases, and users can further extend the above method ideas to set more locator working methods. And when the locator performs work based on the user question, at least one of the above cases is executed.

[0054] After obtaining the specific financial report set data through the locator, the locator will generate a financial report list cList, cList = {financial report 1, …, financial report n}. Then, a task list is obtained according to the user question and the financial report set. The method here is executed by the task decomposition module in the agent. Specifically, through the large language model and the context learning technology, the user's question and the financial report list cList are submitted, the execution of the user's question is decomposed into multiple tasks, and a task list tList based on the execution order is obtained, tList = {task 1, …, task m}. For example: for the user question: What is the average profit of the photovoltaic industry in 2024? and the financial report list cList generated by the locator unit cList = {financial report 1, …, financial report n}, the generated task list is: tList = {task 1: retrieve the company's 2024 profit from financial report 1, …, task n: retrieve the company's 2024 profit from financial report n}.

[0055] It should be noted that the average of the n profit data obtained is not directly calculated at this time, and in the task decomposition module, only the task list is obtained by decomposing how to obtain the required basic data from the corresponding financial report.

[0056] It should be noted that in the above method of decomposing the user's question into multiple tasks by the large language model and the context learning technology, the task decomposition method realized by the large language model combined with the context learning technology can be realized by the existing technology, which is not the innovation point of the present application, and therefore the specific implementation principle will not be described. It can be understood that its principle is similar to the related process in the processing of large models such as DeepSeek, Douba, etc. based on user questions.

[0057] After obtaining the task list tList, the task information in the task list is used to query whether there is a same historical task in the long-term memory, if there is, the analysis and retrieval answer is extracted and saved in the short-term memory, otherwise an operator (i.e. a calling function in the semantic layer) is generated according to the task information, and an operator list oList is obtained, oList = {operator 1, …, operator k}; this part of the method is realized by the operator generation module in the agent. Here, the purpose of establishing long-term memory is to avoid the agent from repeating work.

[0058] Specifically, operator generation is a multi-classification task, i.e. the process of mapping the given user question and related conditions to a calling function in the operator list oList. Therefore, a pre-trained cross-encoder (cross-encoder), such as BGE-reranker, is used to calculate a matching score for the task and the operator, and the operator is generated according to the task information, including: Input the task description, the question, and the description of the selected operator into the classifier to obtain a score. It should be noted that the input data format is as follows: Task Description + User Question | Operator Description; that is, use a separator to separate the operator description from the task description + user question. For example... Figure 2 As shown, the classifier includes a pre-trained cross encoder and a connected Sigmoid layer.

[0059] The operator with the highest score is selected as the classification result. That is, the operator with the highest score is selected as the operator corresponding to the user's question and task description, and this operator is added to the operator list oList.

[0060] It should be noted that a pre-trained cross-encoder can be understood as a Transformer model (such as BERT, RoBERTa, etc.) that has already been pre-trained on a large-scale general corpus. Pre-training allows for fine-tuning of parameters for the specific scenario, resulting in the final usable pre-trained cross-encoder.

[0061] The training data samples include two categories: positive samples (i.e., task descriptions match operator descriptions) and negative samples (i.e., task descriptions do not match operator descriptions). The specific training process is well known to those skilled in the art and will not be described in detail here.

[0062] Each operator in the operator list is executed, and the operator corresponding to each task and the execution result of the operator are stored in short-term memory and long-term memory; this part of the method is implemented by the task execution module in the agent.

[0063] Specifically, the task execution module executes each operator in the operator list oList, that is, it calls functions similar to those in Table 1 above. The operator corresponding to each task and the execution result of the operator are stored in short-term memory and also in long-term memory.

[0064] Short-term memory (STM) is stored in a JSONL file. When a new user question is entered, the JSONL file containing STM is cleared. During the execution of the current user question, the result of each task is saved. Each line is a list of tasks and their results, for example: {“Task”: “Retrieve TCL Technology’s 2024 Revenue”, “Result”: “166,552,785,829”}; {“Task”: “Calculate TCL Technology’s operating profit margin in 2024”, “Result”: “0.26”}.

[0065] And the long-term memory data is stored in the fourth vector database, and the fourth vector database stores historical user questions, analysis retrieval answers corresponding to the user questions, tasks, and task execution results. The task execution result here includes the operator corresponding to the task and the execution result of the operator.

[0066] Finally, the analysis retrieval answer is generated according to the definition of each task saved in the short-term memory, the execution result of the operator corresponding to each task, and the user question. This part of the method is executed by the answer generation module in the agent. It should be noted that the analysis retrieval answer is generated by a large language model with the definition of each task, the execution result of the operator corresponding to each task, and the user question as the prompt word, and the data in the data lake as the basic data information. The specific principle is as before, which belongs to the prior art, and the principle improvement thereof is not involved in the present application.

[0067] Embodiment 2 proposes a data analysis retrieval method based on a large language model based on the constructed financial report data lake, to quickly generate corresponding financial report analysis retrieval answers based on user questions; to quickly realize the financial report analysis needs of users.

[0068] Embodiment 3 The agent provided in Embodiment 3 is used to implement the method proposed in Embodiment 2 based on the data lake constructed in Embodiment 1; as shown in Figure 3 The architecture of the agent is as follows: The locator is used to obtain a set of financial reports based on the enterprise entity related information in the user question; The task decomposition module is used to obtain a task list according to the user question and the set of financial reports; The operator generation module is used to query whether there is a same historical task in the long-term memory according to the task information in the task list, and if so, extract and save the analysis retrieval answer in the short-term memory, otherwise generate an operator according to the task information, and obtain an operator list; The task execution module is used to execute each operator in the operator list, and save the operator corresponding to each task and the execution result of the operator in the short-term memory and the long-term memory; The answer generation module is used to generate an analysis retrieval answer according to the definition of each task saved in the short-term memory, the execution result of the operator corresponding to each task, and the user question.

[0069] For the specific working process of the agent, please refer to the description of the method in Embodiment 2, which will not be repeated here.

[0070] The above merely describes the preferred embodiments of the present application, and is not used to limit the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A method of data lake construction for financial reporting, characterized by, The method comprises the following steps: Based on the content of the financial report data and the preprocessing of the entity on the financial report data, a plurality of databases representing different information are obtained; Set up a semantic layer, which includes the function description of each database and the calling function; Based on the financial report data, the plurality of databases and the semantic layer, a data lake is constructed.

2. The data lake construction method for financial reporting of claim 1, wherein, The database at least includes: A first vector database constructed based on the content of the financial report; A graph database with a corporate association graph constructed based on the relationship between the corporate entities in the financial report; A relational database with corporate financial information constructed based on the corporate entities and corresponding financial indicators in the financial report; A second vector database constructed based on the industry information content of the corporate entities in the financial report; A third vector database constructed based on the product information content of the corporate entities in the financial report.

3. The data lake construction method for financial reporting of claim 2, wherein, The first vector database constructed based on the content of the financial report is specifically: The content of the financial report is divided into a block sequence including text paragraphs and tables to form a block list; Text paragraphs with more than a first preset number of characters are segmented into text paragraphs with partially overlapping content, and the segmented text paragraphs are stored as independent blocks; Text paragraphs with less than a second preset number of characters are merged with the previous text paragraph to form a new text paragraph, and the merged text paragraph is stored as an independent block; The vertical line symbol is used as the separator of the cells in the table to convert the table content into text format, and the text content obtained by converting each table is stored as an independent block; The text content in each independent block is converted into a vector and stored in the first vector database.

4. The data lake construction method for financial reporting of claim 3, wherein, The block is stored in JSON format, and each block includes the following key values: Type key value, used to identify whether the block is a table or a text paragraph; Text key value, used to store text content; Context key value, used to provide context information for the block.

5. The data lake construction method for financial reporting of claim 4, wherein, The context key value of the text paragraph includes the text content of the corresponding context and the title information of the chapter; The context key value of the table includes the text content of the text paragraphs before and after the corresponding table and the title information of the chapter.

6. A data analysis retrieval method for financial reports, characterized by, The method is used for analyzing and retrieving the data lake constructed by the data lake construction method of the financial report according to any one of claims 1-5; specifically comprising: Based on the enterprise entity related information in the user question, a set of financial reports is obtained; Then, according to the user question and the set of financial reports, a task list is obtained; According to the task information in the task list, it is queried in the long-term memory whether there is a same historical task, if there is, the analysis and retrieval answer is extracted and saved in the short-term memory, otherwise, an operator is generated according to the task information, and an operator list is obtained; Each operator in the operator list is executed, and the operator corresponding to each task and the execution result of the operator are saved in the short-term memory and the long-term memory; According to the definition of each task saved in the short-term memory, the execution result of the operator corresponding to each task and the user question, an analysis and retrieval answer is generated.

7. The method of claim 6, wherein the data analysis retrieval of the financial report is characterized by, The way of obtaining a set of financial reports based on the enterprise entity related information in the user question at least includes one of the following ways: directly locate to the financial report data based on the enterprise entity and time in the user question, and form a financial report set; query the enterprise association graph of the enterprise entity in the graph database in the data lake based on the enterprise entity in the user question, and obtain the financial report data of all enterprises in the enterprise association graph, and form a financial report set; query the enterprise entity information in the second vector database in the data lake based on the industry information in the user question, and obtain the financial report data of all enterprise entities in the industry, and form a financial report set; query the enterprise entity information in the third vector database in the data lake based on the product information in the user question, and obtain the financial report data of all enterprise entities producing the product, and form a financial report set.

8. The method for retrieving data analysis of financial reporting of claim 6, wherein, The production operator according to the task information specifically includes: input the task description, question and description of the selected operator into the classifier to obtain a score; select the operator with the highest score as the classification result; The classifier includes a pre-trained cross-encoder and a Sigmoid layer connected thereto.

9. The data analysis retrieval method for financial reporting of claim 6, wherein, The short-term memory is stored through a JSONL file, and when a new user question is input, the JSONL file storing the short-term memory is emptied; The data of the long-term memory is stored in a fourth vector database, and the fourth vector database stores historical user questions, analysis and retrieval answers corresponding to the user questions, tasks and task execution results.

10. An agent, characterized in that A method for analyzing and retrieving a data lake constructed by a data lake construction method using the financial report according to any one of claims 1-5, comprising: a locator for obtaining a financial report set based on enterprise entity related information in the user question; a task decomposition module for obtaining a task list according to the user question and the financial report set; an operator generation module for querying whether there is a same historical task in the long-term memory according to the task information in the task list, and if so, extracting and saving the analysis and retrieval answer in the short-term memory, otherwise generating an operator according to the task information, and obtaining an operator list; a task execution module for executing each operator in the operator list, and saving each task corresponding operator and the execution result of the operator in the short-term memory and the long-term memory; an answer generation module for generating an analysis and retrieval answer according to the definition of each task saved in the short-term memory, the execution result of each task corresponding operator and the user question.