A personalized complex report generation method based on multi-agent system

Through the collaborative operation of multi-agent systems, the existing technology solves the diversified user needs and multi-modal data integration problems, realizes the efficient generation and optimization of personalized and complex reports, and improves the quality of reports and user satisfaction.

CN118569237BActive Publication Date: 2024-10-29ZHEJIANG UNIV OF TECH
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202411038346.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-07-31
Publication Date
2024-10-29
Estimated Expiration
2044-07-31

Smart Images

  • Figure CN118569237B_ABST
    Figure CN118569237B_ABST
Patent Text Reader

Abstract

The present invention discloses a personalized complex report generation method based on a multi-agent system, the method comprising: receiving a user's demand description expressed in natural language; using an agent based on a large language model to convert unstructured natural language requirements into report generation sentences, accurately obtaining the user's expected report content through interactive iteration with the user, and generating clear outline content; relying on the synergy of the multi-agent system, extracting and inferring the required exact data from the multimodal data source according to the outline planning, and generating a target report according to the report outline and exact data; after the report generation is completed, allowing the user to evaluate and propose modification opinions or suggestions; collecting relevant data such as user feedback to guide the optimization of user tasks or fine-tune the base large language model of the multi-agent system to enhance its personalized capabilities. The present invention can reduce the difficulty of complex report writing, speed up report generation, and has broad application prospects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of artificial intelligence application technology, and in particular relates to a personalized complex report generation method based on a multi-agent system. Background Art

[0002] With the rapid development of the information age, the demand for high-quality, professional and complex reports in fields such as corporate decision-making and academic research is growing. The traditional report writing model relies heavily on manual operations, including multiple tedious links such as information collection, data analysis, and content arrangement. This process is not only time-consuming and costly, but also subject to personal professional knowledge and time and energy, which can easily lead to uneven report quality and even inaccurate and incomplete information. In addition, in the face of the explosive growth of information in the big data environment, it is even more difficult to manually organize and analyze multi-source and multi-modal data (such as structured data, text, images, videos, etc.), which greatly limits the efficiency and depth of report production.

[0003] In recent years, the rapid development of natural language processing technology has brought new hope for automated document generation. Some existing solutions attempt to use machine learning and natural language generation technology to automatically generate report content. However, most of these technologies focus on a single type of data processing or the generation of simple templated reports. For complex reports that require in-depth analysis, high customization, and multi-dimensional comprehensive information, there are still many limitations. For example, they often find it difficult to accurately understand the personalized needs of users, especially when dealing with vague or highly specific instructions, which can easily lead to misunderstandings or omissions of key information. At the same time, the integration capabilities across data modalities are limited, and it is impossible to effectively extract and integrate relevant information from massive heterogeneous data, resulting in the generated reports being empty and lacking in depth.

[0004] In addition, existing report generation methods generally ignore the dynamic interaction process with users and lack an effective mechanism to receive and respond to user feedback and correction instructions in real time, resulting in a large deviation between the final report and user expectations. User satisfaction and participation, especially in terms of report customization, content accuracy, and precision of expression, are key factors in determining the success of a report.

[0005] In view of this, building an intelligent report generation method that can overcome the above technical barriers has become the key to solving current market needs and improving report production efficiency and quality. The ideal method should be able to integrate advanced natural language processing, big data processing and multi-agent collaborative technology to form an overall solution that can accurately understand user needs, efficiently integrate multiple data sources, support dynamic interactive feedback, and continuously optimize personalized content generation. This is not only a reflection of technological innovation, but also a positive response to current market challenges. Summary of the invention

[0006] The purpose of the present invention is to provide a personalized complex report generation method based on a multi-agent system in view of the limitations of the existing technology in dealing with the diversified needs of users, multimodal data integration, report personalization and dynamic interaction. The present invention builds a comprehensive, highly intelligent, flexible and efficient report automation generation framework and process, emphasizes the collaborative operation between modules, and ensures the fluency and accuracy from user input to the final personalized report output through the close cooperation of various agents, without going into the underlying implementation of each technical detail.

[0007] The object of the present invention is achieved through the following technical solution: a method for generating a personalized complex report based on a multi-agent system, comprising the following steps:

[0008] S1. A user interaction interface is preset for seamless connection between the user and the front end, and receives the report generation requirement description input by the user in natural language;

[0009] S2. The report requirement parsing agent improves the report generation requirement description through multiple rounds of communication dialogues with the user and generates a set of structured report generation instructions;

[0010] S3, the multimodal data extraction agent uses a hybrid information retrieval method to accurately extract the information and data retrieval sources required for the report generation instruction set from the multimodal data source;

[0011] S4. The outline retrieval and planning agent locates and plans the content structure based on the report generation instruction set and the information and data retrieval sources extracted by the multimodal data extraction agent to generate a report outline, and records the data retrieval sources and data integrity in detail at the corresponding locations;

[0012] S5. The report construction and verification agent synthesizes the target report based on the report outline and the specific data extracted by the multimodal data extraction agent. During the synthesis process of the target report, a dual-track verification strategy is used to verify the data consistency and logical correctness of the target report.

[0013] S6. The user can preview, edit, modify and download the generated target report in real time through the user interaction interface, and conduct a detailed evaluation of the initially generated report, collect user feedback on the report content, structure and format, so as to optimize and adjust the generated target report;

[0014] S7. Through feedback learning and personalized enhancement agents, user feedback data is desensitized, summarized and analyzed. Based on the desensitized data and analysis results, the outline retrieval and planning agents and the report construction and verification agent's base language model are continuously fine-tuned, as well as the prompt word template for optimizing personalized report generation.

[0015] Furthermore, the report requirement parsing agent, the outline retrieval and planning agent, the multimodal data extraction agent, the report construction and verification agent, and the feedback learning and personalized enhancement agent are all constructed based on the base big language model; wherein, the base big language model is trained by using the data set of the field or task corresponding to the agent to train the big language model.

[0016] Furthermore, the step S2 specifically includes: the report requirement parsing agent conducts multiple rounds of communication dialogues with the user, during which the report requirement parsing agent deeply understands the user's deep language needs and captures their true intentions; by conducting dialogues with the user in the form of questions and answers, using preset model query prompts and system control logic, the report requirement parsing agent gradually refines and clarifies the user's expected report generation requirement description, comprehensively covers the user's expected report theme, key points, format and key elements of specific requirements, accurately defines the specific scope, objectives and required key intent entities of the report generation task, and generates a set of structured report generation instruction sets;

[0017] The report generation instruction set includes a refined report generation requirement description and key intent entities extracted therefrom.

[0018] Further, the hybrid information retrieval method includes a retrieval enhancement generation method, a multimodal large language model, an optical character recognition method, and a table structure understanding method;

[0019] The multimodal data source includes text, table and image data types, and the multimodal data source includes internal enterprise databases, internal enterprise files, user historical feedback data and data from public retrieval sources on the Internet.

[0020] Furthermore, in step S3, when the multimodal data extraction agent extracts the information and data retrieval sources required for the report generation instruction set, it sets the information data that cannot be directly obtained to blank and marks its associated contextual information, and establishes a data missing record; the extracted information data is preliminarily cleaned and standardized to ensure the consistency of its format.

[0021] Furthermore, the content of the report outline is closely related to the report topic. The report outline includes a detailed and logically rigorous report structure, chapter titles and key data descriptions, and data retrieval sources to plan subsequent data acquisition tasks; among them, the data names mentioned in the report outline are only described and explained, and no specific data are listed.

[0022] Furthermore, in step S4, the outline retrieval and planning agent also retrieves the report generation situation that is most similar to the current task in its historical task data as a reference prompt word, and dynamically fills the similar data into a pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base language model of the outline retrieval and planning agent to generate a report outline;

[0023] In step S5, the report construction and verification agent further retrieves the report generation situation in the user's historical tasks that is most similar to the current task as a reference prompt word, and dynamically fills the similar data into a pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base large language model of the report construction and verification agent to generate a target report;

[0024] Among them, the report generation situation that is most similar to the current task is obtained through the following steps: by using the Embedding-based retrieval algorithm to retrieve historical task data, using the embedding model to convert the historical task data and the relevant text of the current task into a vector representation, by calculating the similarity between the vector representation of the historical task data and the vector representation of the current task, the report generation situation of the historical task data corresponding to the maximum similarity is selected as the report generation situation that is most similar to the current task.

[0025] Furthermore, in step S5, the report construction and verification agent also locates the data missing position in the target report based on the data missing record constructed by the multimodal data extraction agent when extracting the information required for the report generation instruction set and the data retrieval source, and fills or marks the data to be supplemented according to the preset supplementary rules;

[0026] The dual-track verification strategy includes a data-text mapping comparison strategy and a model reasoning verification strategy, wherein the data-text mapping comparison strategy is specifically: using semi-structured data matching and text comparison methods, the generated target report is compared with the original data one by one, and whether the numerical references, percentages, and chart descriptions are completely consistent with the original data; the model reasoning verification strategy is specifically: the original data and the generated target report are designed as two types of prompt words respectively, and the two types of prompt words are input into a dedicated large language model for reasoning to determine whether the target report is consistent with the original data.

[0027] Furthermore, the user interaction interface includes at least an online dialog box, a report outline interaction interface and a complete report interaction interface; wherein, the user interacts with the system through the online dialog box, and after generating the report outline or target report, performs real-time preview, editing, modification and download operations on the report outline or target report to achieve on-demand adjustment of the target report content.

[0028] Furthermore, the desensitized data includes user feedback, user original requirements, report generation instructions clarified by the report requirement parsing agent, and a complete report outline generated by the outline planning and retrieval agent;

[0029] The feedback learning and personalized enhancement agent fine-tunes the base large language model of the outline retrieval and planning agent and the report construction and verification agent when the following preset conditions are met: in the generation of a fixed number of consecutive reports, the user feedback satisfaction is less than a preset satisfaction threshold; or, within a fixed time period, the common problems pointed out in the user feedback reach a preset minimum tolerance number.

[0030] The beneficial effects of the present invention are as follows: the present invention utilizes the close cooperation of a multi-agent system, starting from receiving diversified user inputs to generating highly personalized and accurate reports, and the whole chain is efficiently and automatically processed; the present invention integrates a large language model fine-tuning method, and each agent can deepen the processing capability for specific tasks, whether it is parsing requirements, integrating multi-source data, or constructing and verifying report content, it can be both professional and efficient; the system design of the present invention focuses on user interaction, and allows users to provide real-time feedback during the generation process, dynamically adjust the report content, and ensure that the final results meet expectations; the present invention utilizes user feedback for system self-learning and optimization, continuously upgrades the service experience, reduces human errors, and improves the accuracy of data processing and the speed of report generation; the present invention can not only innovate the traditional report preparation model, but also can be widely empowered in the fields of enterprise decision-making, scientific research analysis, etc. with its intelligent and efficient characteristics, saving time and cost for users and enhancing the value of reports; the present invention achieves automatic conversion from user natural language requirements to high-quality personalized complex reports through natural language processing and multi-agent collaborative methods, which can reduce the difficulty of complex report writing, speed up report generation, and has broad application prospects. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 It is a schematic diagram of the architecture of the method for generating personalized complex reports based on a multi-agent system of the present invention;

[0032] Figure 2 The figure is a flowchart of an embodiment of the present invention. DETAILED DESCRIPTION

[0033] The following will be combined with the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. The described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0034] Example 1

[0035] like Figure 1 As shown, the general architecture of the personalized complex report generation method based on the multi-agent system of the present invention is illustrated, and the core components of the present invention and their interaction mechanism are shown, which are built on an efficient and coordinated multi-agent system. Among them, the multi-agent system includes a report requirement parsing agent, an outline retrieval and planning agent, a multimodal data extraction agent, a report construction and verification agent, and a feedback learning and personalized enhancement agent. The above-mentioned multiple types of agents together constitute a highly coordinated multi-agent system, providing users with a full range of efficient personalized complex report generation services.

[0036] In this embodiment, the report requirement parsing agent, outline retrieval and planning agent, multimodal data extraction agent, report construction and verification agent, and feedback learning and personalized enhancement agent are all constructed based on a specific base large language model (LLM).

[0037] Furthermore, a specific base big language model is formed by fine-tuning the general big language model combined with the corresponding specific domain knowledge, or a professional domain big language model trained for a specific task. Its core purpose is to give each intelligent agent the ability to handle its duties professionally and efficiently.

[0038] Furthermore, the large language model that is fine-tuned for specific domain knowledge refers to building a specific data set for intelligent agents with different functions based on a specific general large language model, where the data set mainly includes three parts: instructions, replies, and history. By inputting different data to re-train the original general large language model, a fine-tuned model with enhanced performance in a specific domain is obtained.

[0039] It should be understood that during the fine-tuning of the large language model, a specific data set containing instructions, replies, and historical records is used to specifically enhance the performance of the large language model in a specific field, thereby improving the professional processing capabilities of the overall system. The large language model can convert unstructured natural language requirements into clear report generation sentences, and then combine specific domain knowledge or data sets collected for specific tasks, use this data set to train the large language model, and obtain the base large language model corresponding to each intelligent agent, so that each intelligent agent can perform its own duties.

[0040] See also Figure 1 , the method specifically comprises the following steps:

[0041] S1. A user interaction interface is preset for seamless connection between the user and the front end, and the report generation requirement description input by the user in natural language is received.

[0042] Specifically, the multi-agent system achieves seamless connection with users through the front-end interactive interface. The interface is carefully designed with chat dialog boxes, outline preview and edit boxes, and report preview and edit boxes to meet the full interactive needs from user demand communication, outline construction to report generation. Among them, the chat dialog box mainly undertakes the instant communication between users and the multi-agent system, the outline interactive interface mainly undertakes the user to view and edit the preview outline generated by the multi-agent system, and the report interactive interface mainly undertakes the user to view and edit the preview report generated by the multi-agent system.

[0043] S2. The report requirement parsing agent improves the report generation requirement description through multiple rounds of communication and dialogue with the user, and generates a set of structured report generation instruction sets.

[0044] Specifically, the report requirement parsing agent conducts multiple rounds of communication and dialogue with the user. During the multiple rounds of communication and dialogue, the report requirement parsing agent deeply understands the user's deep language needs and captures their true intentions; by conducting dialogues with the user in the form of questions and answers, and using preset model query prompts and system control logic, the report requirement parsing agent gradually refines and clarifies the user's expected report generation requirement description, comprehensively covering key elements such as the user's expected report topic, key points, format and specific requirements, accurately defining the specific scope, objectives and required key intent entities of the report generation task, and generating a set of structured report generation instruction sets.

[0045] It should be understood that the report demand parsing agent demonstrates a high level of semantic understanding ability, can deeply understand the essence of user needs, has the ability to deeply understand the deep needs of user language, and can accurately capture its true intentions even when faced with vague or complex expressions.

[0046] Furthermore, the report generation instruction set includes a refined report generation requirement description and key intent entities extracted therefrom.

[0047] Specifically, the report demand parsing agent is the initial contact point, responsible for parsing user input and deeply understanding the user's intention with the help of a large language model. The report demand parsing agent is equipped with preset query prompts to guide users to clearly and clearly state their report requirements. For example, when the user input is vague, such as "I want to make a sales report", the agent will take the initiative to initiate a dialogue and ask: "Which time period do you want to focus on sales data? Are there any specific product lines or regional requirements?" Through such rounds of iterative dialogues, the report demand parsing agent can build a structured report generation instruction set, such as: "Generate a sales analysis report for the mobile phone product line in North America in the second quarter of 2023, which must include revenue, sales and market share." At the same time, the agent accurately identifies and records key slot information such as time (2023 Q2), product line (mobile phone), region (North America), key intent entities (revenue, sales, market share), etc., to provide strong support for the smooth progress of subsequent steps.

[0048] S3. The multimodal data extraction agent uses a hybrid information retrieval method to accurately extract the information and data retrieval sources required for the report generation instruction set from the multimodal data source.

[0049] Furthermore, the hybrid information retrieval method includes a retrieval-augmented generation (RAG) method, a multimodal large language model, an optical character recognition (OCR) method, and a table structure understanding method.

[0050] Furthermore, multimodal data sources are rich and diverse. Multimodal data sources include data types such as text, tables, and images. Multimodal data sources include data from internal enterprise databases, internal enterprise files, user historical feedback data, and Internet public retrieval sources. The system effectively integrates and utilizes these data sources to meet users' diverse report generation needs.

[0051] In this embodiment, the multimodal data extraction agent accurately extracts the information and data retrieval sources required for the report generation instruction set from the multimodal data source by adopting a hybrid information retrieval method. That is, the multimodal data extraction agent uses different methods to process data of different modalities, and based on the report generation instruction set, accurately extracts data closely related to the report content from the multimodal data source, and strictly requires the extracted data to give specific representations or values ​​to extract the information and data retrieval sources required for the report generation instruction set.

[0052] Specifically, for text data types, the retrieval ideas in the general RAG method are adopted, that is, using efficient retrieval algorithms to find information fragments that are highly relevant to the query from a huge knowledge base. This process usually involves two widely used retrieval algorithms, namely the BM25 algorithm and the Embedding-based retrieval algorithm; and finally the information and data retrieval sources required for the report generation instruction set are extracted. Among them, the BM25 algorithm is used to evaluate the relevance between documents and queries. It accurately locates the most relevant documents based on statistical indicators such as word frequency and inverse document frequency; while the Embedding-based retrieval algorithm is used to convert text into vector representation using an embedding model, and identify the most matching text fragment by calculating the similarity between vectors. For image data types, the image content is converted into an understandable and retrievable text form through a multimodal large language model, and the data and labels in it are accurately parsed with the help of the OCR method, and the text information is extracted from the image. Then, the RAG method of the text data type is used to process the extracted text information, thereby enhancing the understanding and generation capabilities of the image content, and finally extracting the information and data retrieval sources required for the report generation instruction set. For tabular data types, that is, complex situations such as multiple tables in complex tabular data and extra-long fields in a single table, we first use the table structure understanding method to screen effective fields and accurately identify column headers, row data, etc. to convert the tabular data into text, and then use the RAG method to extract the converted text data, which can effectively improve the accuracy and efficiency of data extraction.

[0053] It should be noted that the multimodal data extraction agent is connected to the multimodal large language model, which natively supports the processing of text and image modal data. For table-type data structures where the current multimodal large language model has limited capabilities, the table structure understanding method can be used to convert the table data into text data, and then the RAG method can be used for processing. Although the multimodal large language model natively supports the processing of image modal data, due to the limited capabilities of the current multimodal large language model, the recognition effect may not be good, so the OCR method is used for assistance.

[0054] Furthermore, when the multimodal data extraction agent extracts the information and data retrieval sources required for the report generation instruction set, it will blank out the information data that cannot be directly obtained and mark its associated contextual information; and establish a record of missing data to facilitate targeted supplementation or adjustment in subsequent steps; and perform preliminary cleaning and standardization on the extracted information data to ensure the consistency of its format.

[0055] It should be noted that, based on the information and data retrieval sources required for the report generation instruction set extracted by the multimodal data extraction agent, the multimodal data extraction agent, under the premise of a deep understanding of the context, conducts comprehensive preliminary cleaning and standardization of the extracted data to ensure the consistency and applicability of its format. For example, the "sales volume" data obtained from different sources will be unified in units, which effectively ensures the accuracy of data comparison.

[0056] S4. The outline retrieval and planning agent locates and plans the content structure based on the report generation instruction set and the information and data retrieval sources extracted by the multimodal data extraction agent to generate a report outline, and records the data retrieval sources and data integrity in detail at the corresponding locations.

[0057] Furthermore, the content in the report outline is closely related to the report theme. The report outline contains a detailed and logically rigorous report structure, chapter titles and key data descriptions, and data retrieval sources to plan subsequent data acquisition tasks. Among them, the report structure in the report outline is logically clear, rich in content and complete; the data names mentioned in the report outline are only explained and explained, and no specific data is listed.

[0058] Furthermore, the outline retrieval and planning agent also retrieves the report generation situation that is most similar to the current task in its historical task data as a reference prompt word, and dynamically fills the similar data into the pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base language model of the outline retrieval and planning agent to generate a report outline. The following steps are used to obtain the report generation situation that is most similar to the current task: retrieve the historical task data by using an Embedding-based retrieval algorithm, convert the historical task data and the relevant text of the current task into a vector representation by using an embedding model, and calculate the similarity between the vector representation of the historical task data and the vector representation of the current task, and select the report generation situation of the historical task data corresponding to the maximum similarity as the report generation situation that is most similar to the current task.

[0059] It should be understood that drawing on the output of the user's past similar tasks as an auxiliary reference can further enhance the personalization of the report.

[0060] Specifically, the outline retrieval and planning agent works closely with the multimodal data extraction agent. First, the multimodal data extraction agent analyzes the report generation instruction set generated by the agent according to the report requirements and determines the information required for report generation. Based on this, the report generation instruction set related information fragments are comprehensively retrieved from data sources such as the enterprise's internal database, internal documents, external resource library, user historical feedback data and Internet public search. In this retrieval process, special emphasis is placed on the description of the data itself rather than the data itself; through methods such as keyword expansion, synonym matching and context understanding, the breadth and depth of the retrieval can be effectively increased to ensure that comprehensive information related to the report generation instruction set is covered. Then, the information data retrieved by the multimodal data extraction agent is preliminarily cleaned and standardized to ensure the consistency of its format; multiple search results after standardization are merged together to obtain a fused search result. In the process of merging multiple search results, semantically similar or repeated content is merged to avoid information redundancy; for example, if multiple sources mention different aspects of the same event, the core information of the event is extracted to construct a comprehensive description instead of presenting each fragment in isolation. Secondly, the outline retrieval and planning agent uses the retrieved high-quality fragments as key knowledge clues to guide its base language model to fully integrate more external knowledge when generating the report outline, significantly enhancing the richness and feasibility of the report content. When constructing the outline based on the acquired data summary description through its base language model, the outline retrieval and planning agent not only considers the logical coherence and hierarchical structure of the information, but also flexibly adjusts the display order and importance ranking of the information according to the specific needs of the user, ensuring that the outline structure conforms to both conventional logic and the customized requirements of the user. In addition, the outline retrieval and planning agent also has excellent dynamic adjustment capabilities. It can obtain new data summary requirements in a timely manner based on the quality feedback of the initial generation of the report outline (such as user confirmation or modification instructions), thereby realizing iterative optimization of the report outline. Through this two-way feedback mechanism of retrieval and generation, the report outline can not only accurately respond to the user's initial needs, but also gradually approach the ideal report framework in the user's mind in the subsequent interaction process, achieving an ideal state of both personalization and high quality.

[0061] S5. The report construction and verification agent synthesizes the target report based on the report outline and the specific data extracted by the multimodal data extraction agent. During the synthesis process of the target report, a dual-track verification strategy is used to verify the data consistency and logical correctness of the target report to ensure that every detail, data reference and analysis in the target report accurately reflects the actual situation of the original data.

[0062] It should be noted that the report construction and verification agent generates high-quality target report content in sequence, and adopts a dual-track verification strategy to verify the data consistency and logical correctness of the target report by comparing the original data and the target report.

[0063] Furthermore, the report construction and verification agent also retrieves the report generation situation that is most similar to the current task in the user's historical tasks as reference prompt words, and dynamically fills similar data into the pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base language model of the report construction and verification agent to generate the target report. The report generation situation that is most similar to the current task is obtained through the following steps: by using the Embedding-based retrieval algorithm to retrieve the historical task data, using the embedding model to convert the historical task data and the relevant text of the current task into a vector representation, by calculating the similarity between the vector representation of the historical task data and the vector representation of the current task, the report generation situation of the historical task data corresponding to the maximum similarity is selected as the report generation situation that is most similar to the current task.

[0064] It should be understood that the report building and verification agent provides personalized generation prompts for the current task based on the user's history, which can optimize the report generation effect.

[0065] Furthermore, the report construction and verification agent also locates the missing data in the target report based on the data missing records constructed by the multimodal data extraction agent when extracting the information required for the report generation instruction set and the data retrieval source, and reasonably fills in or marks the missing data according to the preset supplementary rules.

[0066] Furthermore, the dual-track verification strategy includes a data-text mapping comparison strategy and a model reasoning verification strategy, wherein the data-text mapping comparison strategy is specifically as follows: using semi-structured data matching and text comparison methods, the generated target report is compared with the original data one by one, and checking whether the numerical references, percentages, chart descriptions, etc. are completely consistent with the original data; the model reasoning verification strategy is specifically as follows: the original data and the generated target report are designed as two types of prompt words respectively, and the two types of prompt words are input into a dedicated large language model for reasoning to determine whether the target report is consistent with the original data.

[0067] Specifically, the report construction and verification agent relies on the base large language model and closely combines business rules and logical constraints. It generates a draft of the target report based on the established report outline and the specific data extracted by the multimodal data extraction agent. In view of the high standards of professionalism and factuality of the target report, and the illusion problem of the current large language model, especially the model with small parameters, in order to strictly verify the accuracy of the content, a two-track verification strategy is adopted - data-text mapping comparison strategy and model reasoning verification strategy. By comparing the original data and the target report, the target report is verified for data consistency and logical correctness. Once a problem is found in any of the above methods, the problem is input as part of the prompt word into the base large language model of the report construction and verification agent to regenerate the target report.

[0068] S6. Users can preview, edit, modify and download the generated target report in real time through the user interaction interface, and conduct a detailed evaluation of the initially generated report, collect user feedback on the report content, structure, format, etc., to further optimize and adjust the generated target report.

[0069] Furthermore, the user interaction interface includes at least an online dialog box, a report outline interaction interface and a complete report interaction interface. The user interacts with the system through the online dialog box throughout the process, and after generating the report outline or the complete target report, the user can preview, edit, modify and download the report outline or the target report in real time, and finally realize the on-demand adjustment of the target report content.

[0070] S7. Through feedback learning and personalized enhancement agents, user feedback data is desensitized, summarized and analyzed. Based on the desensitized data and analysis results, the outline retrieval and planning agents and the report construction and verification agents' base large language model are continuously fine-tuned, as well as the prompt word templates for personalized report generation are optimized to adapt to users' changing needs and improve the ability to generate personalized reports.

[0071] It should be understood that the optimization of feedback learning and personalized enhanced agents is specifically to deeply learn user feedback and drive the system to perform self-optimization, which is mainly reflected in providing prompt word supplements for the report requirement parsing agent and the report construction and verification agent, as well as providing continuous fine-tuning data for the base large language model of the outline retrieval and planning agent and the report construction and verification agent.

[0072] Furthermore, the desensitized data includes user feedback, user original requirements, report generation instructions clarified by the report requirement parsing agent, and a complete report outline generated by the outline planning and retrieval agent.

[0073] It should be understood that desensitization refers to replacing user privacy information with similar content that will not expose user privacy. In the field of information technology and data protection, it refers to the process of modifying or replacing sensitive data to protect personal privacy or business secrets while maintaining the basic structure and function of the data.

[0074] Furthermore, the feedback learning and personalized enhancement agent will only fine-tune the base large language model of the outline retrieval and planning agent and the report construction and verification agent when the following preset conditions are met: in the generation of a fixed number of consecutive reports, the satisfaction of user feedback is less than the preset satisfaction threshold; or, within a fixed time period, the common problems pointed out in the user feedback reach the preset minimum tolerance number.

[0075] It should be understood that the optimization trigger conditions of the feedback learning and personalized enhanced agent are flexible and can be set according to actual conditions, such as data accumulation or time period, etc. After fine-tuning the base language model of the feedback learning and personalized enhanced agent, the quality and efficiency of report generation can be improved.

[0076] Specifically, feedback learning and personalized enhancement agents are constructed as a strict closed-loop feedback loop system. Each user interaction (such as ratings, modification requests) will be fully recorded and used for the optimization of the multi-agent system after strict privacy protection processing (such as data desensitization). Using online learning methods, user-specific preferences and correction suggestions are instantly fed back to the personalized history records, significantly optimizing the future report generation experience of individual users. When the collected desensitized feedback data reaches a specific threshold, such as in the continuous generation of a fixed number of reports, the user feedback satisfaction is lower than a certain threshold (i.e., the preset satisfaction threshold), or in a specific time period, the number of common problems pointed out in user feedback reaches a certain number (i.e., the preset minimum fault tolerance number), the base large language model of the outline retrieval and planning agent and the report construction and verification agent will be fine-tuned, so that the corresponding base large language model is more adapted to the preferences of specific report types and user groups, and the personalization and generation quality of the report are continuously improved.

[0077] Example 2

[0078] like Figure 2 As shown, the specific workflow of an embodiment of the method of the present invention is disclosed.

[0079] S1. The user first describes the requirements of the target report in words, such as "please generate a report around a certain electric field". The system receives and passes the requirement to the report requirement parsing agent.

[0080] S2. Report requirement analysis The agent first determines whether the input is related to generating a report. If not, it refuses to proceed to the next step; if so, it performs requirement clarity analysis. To determine whether it is a report-related intention, the following prompt word (PROMPT) is used to guide the base language model:

[0081] PROMPT:

[0082] Please carefully analyze the following user input text content to determine whether it clearly expresses an intention related to report generation:

[0083] Input text: [user input text]

[0084] If the text contains keywords closely related to report generation, such as "report", "generate", "analysis", "summary", etc., and the text as a whole can form a clear and unambiguous report generation request, it is determined to have the intention to generate a report, and the response format is {'isReportIntent': true}; otherwise, it is determined not to have the intention to generate a report, and the response format is {'isReportIntent': false}.

[0085] Example:

[0086] Input text: "I need a report on the company's sales in the first half of the year"

[0087] Response: {'isReportIntent': true}

[0088] S3. For demand clarity analysis, the base language model of the report demand parsing agent is implemented through the following prompt words:

[0089] PROMPT:

[0090] For the current intent description given below, please perform in-depth analysis and return the data in the JSON format specified below.

[0091] Current intent description: [Current intent description]

[0092] JSON format data:

[0093] {

[0094] "Is the intention complete": [bool value], / / true if the intention is complete and clear; otherwise false

[0095] "Full intent description": "[full intent description]", / / After the intent is clear, provide a complete intent description

[0096] "Slot Description List": [

[0097] {

[0098] "Slot Name": "[Slot 1 Name]",

[0099] "Slot Description": "[Slot 1 description or example value]",

[0100] "Is it filled": [bool value] / / If the slot already has a value, it is true; otherwise, it is false

[0101] },

[0102] / / ... Other slot information, continue to add in the same format...

[0103] {

[0104] "Slot Name": "[Slot N Name]",

[0105] "Slot Description": "[Slot N description or example value]",

[0106] "Is it filled": [bool value]

[0107] } ]

[0109] }

[0110] Notice:

[0111] 1. If the intent is complete, clear, and unambiguous, the value of "Is the intent complete" is true, and a detailed and accurate "Complete intent description" is provided, as well as a "Slot description list" that lists all slots.

[0112] 2. If the intent is not yet complete and clear, the value of "Is the intent complete" is false, and a partial description of the intent that has been clarified is provided, and a "Slot Description List" that still needs to be supplemented is listed.

[0113] 3. Each slot in the slot description list should include the slot name, slot description (or example value), and status of whether it is filled or not.

[0114] S4. The report requirement parsing agent interacts with the user through multiple rounds until the base large language model returns a description, indicating that the intention is complete, and transmits the report generation requirement with complete intention and the corresponding slot information to the outline retrieval and planning agent, for example, "Instruction: Please generate a [quality] report on [a certain equipment] around [a certain electric field]. Scope: a certain electric field object: a certain equipment type: quality report".

[0115] S5. The outline retrieval and planning agent receives the input, sends the instruction and slot description to the multimodal data extraction agent for retrieval operation, and integrates the retrieved information into the prompt words to guide the base language model to generate the outline. The corresponding prompt words are as follows:

[0116] PROMPT:

[0117] Please follow the instructions and slot information provided below, make full use of the retrieved relevant materials and information, and generate a detailed and complete report outline.

[0118] Command: [input command]

[0119] Slot information:

[0120] - [Slot Description]: [Slot Entity]

[0121] - [Other necessary slot information]

[0122] Retrieve information:

[0123] - [Slot entity]: [Retrieved relevant information and description]

[0124] - [Other necessary search information]

[0125] Requirements: The generated report outline should be rigorously structured, clearly organized, rich in content and fully cover the relevant points.

[0126] S6. After the report outline is generated, it will be displayed in the report outline interactive box for users to preview. Users can directly modify and improve the report outline in this area, or make modification suggestions through the dialog box. The outline retrieval and planning agent will refer to the user's suggestions and regenerate the report outline. When the user confirms that the report outline meets the requirements, the complete report outline and slot information will be used as input for the report construction and verification agent.

[0127] S7. Report Construction and Verification Agent first constructs prompt words to reason about the input report outline and slot information, and obtains a list of data required for the complete report outline. This list is given as input to the multimodal data extraction agent. The prompt words here are as follows:

[0128] PROMPT:

[0129] Based on the outline and slot information provided below, construct an exhaustive list of data needed to cover a complete outline.

[0130] Outline:

[0131] [Insert synopsis here]

[0132] Slot information:

[0133] - [Slot Description]: [Slot Entity]

[0134] - [Other necessary slot information]

[0135] Require:

[0136] 1. The list must include all the data points required in the outline.

[0137] 2. The data of each slot must accurately correspond to the corresponding description and entity.

[0138] 3. Strictly follow the instructions in the notes / requirements to ensure the data is complete, accurate and in the specified format.

[0139] 4. If necessary, a source reference or verification method must be provided for each data point in the inventory.

[0140] reply:

[0141] Inference results (data list):

[0142] [The data list after inference will be generated here]

[0143] Data source reference:

[0144] [The main source of information when retrieving information is generated here]

[0145] S8, the multimodal data extraction agent receives the data list, and obtains specific data values ​​or close information from the limited data source according to the instructions in the list by designing prompt words. For the content that cannot be directly obtained, it is first blanked. The corresponding prompt words for this step are as follows:

[0146] PROMPT:

[0147] Please use the following data checklist to accurately extract relevant information from the specified multimodal data source.

[0148] Data list:

[0149] [List of data received from the report building and verification agent]

[0150] Data source reference:

[0151] - Database: [database name]

[0152] - Document library: [document library name]

[0153] - [Other possible data sources]

[0154] Only extract data, and do not modify the original data. For numerical data that cannot be directly obtained, set them blank, and give the top-[k] related data description as a note for the blank item.

[0155] S9. When the multimodal data extraction agent obtains the data in the data list, it will be returned to the report construction and verification agent. The report construction and verification agent will first determine whether it contains blank data. If so, it will infer according to the remarks attached to the item to obtain the calculation formula for the blank item data. The new entity in the calculation formula will be given as a new data list to the multimodal data extraction agent for data extraction until all the data in the list is clear.

[0156] S10. Take the complete data list and report outline as input, and put in prompt words to guide the base language model to generate the final report. The prompt words are as follows:

[0157] PROMPT:

[0158] Please carefully write a complete and high-quality report based on the data list and outline provided below. Make sure that the report content is logically rigorous, well-structured, complete and accurate, and truthfully reflect the information in the data list.

[0159] Data list:

[0160] [Insert data list content here]

[0161] Report Outline:

[0162] [Insert report outline here]

[0163] Please note:

[0164] 1. All citations and analyses must be based solely on the information in the data list.

[0165] 2. The report should use professional, precise and clear language, and avoid using overly complex or ambiguous words.

[0166] 3. Make sure the report has good logical coherence and readability, and optimize it by using formatting tools such as paragraphs, headings and lists appropriately.

[0167] S11. After the report building and verification agent verifies the generated report, a report preview will be displayed in the report interaction box. The user can modify it directly or enter suggestions in the dialog box to guide the report building and verification agent to modify the report until the user believes that the generated report meets the requirements and the process is completed.

[0168] S12. Throughout the entire process, the Feedback Learning and Personalization Enhancement Agent will collect feedback, modification suggestions, and historical context at the time. For example, when a user is satisfied with a generated outline, the agent will collect a triple containing the complete intention, the outline, and the user's evaluation, and merge it into the prompt word in the form of a few-shot to guide the large model to complete the specified task.

[0169] The above embodiments are only used to illustrate the design ideas and features of the present invention, and their purpose is to enable those skilled in the art to understand the content of the present invention and implement it accordingly. The protection scope of the present invention is not limited to the above embodiments. Therefore, any equivalent changes or modifications made based on the principles and design ideas disclosed by the present invention are within the protection scope of the present invention.

[0170] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.

Claims

1. A personalized complex report generation method based on a multi-agent system, characterized in that: The following steps are involved: S1. A user interaction interface is preset for seamless connection between the user and the front end, and receives the report generation requirement description input by the user in natural language; S2. The report requirement parsing agent improves the report generation requirement description through multiple rounds of communication dialogues with the user and generates a set of structured report generation instructions; Among them, the step S2 specifically includes: the report demand parsing agent conducts multiple rounds of communication dialogues with the user. During the multiple rounds of communication dialogues, the report demand parsing agent deeply understands the deep language needs of the user and captures his true intentions; by conducting dialogues with the user in the form of questions and answers, using the preset model query prompt words and system control logic, the report demand parsing agent gradually refines and clarifies the user's expected report generation requirements, comprehensively covers the user's expected report theme, key points, format and key elements of specific requirements, accurately defines the specific scope, objectives and required key intent entities of the report generation task, and generates a set of structured report generation instruction sets; S3, the multimodal data extraction agent uses a hybrid information retrieval method to accurately extract the information and data retrieval sources required for the report generation instruction set from the multimodal data source; Among them, in the step S3, when the multimodal data extraction agent extracts the information and data retrieval sources required for the report generation instruction set, for the information data that cannot be directly obtained, it is blanked and its associated context information is marked, and a data missing record is established; the extracted information data is preliminarily cleaned and standardized to ensure the consistency of its format; S4. The outline retrieval and planning agent locates and plans the content structure based on the report generation instruction set and the information and data retrieval sources extracted by the multimodal data extraction agent to generate a report outline, and records the data retrieval sources and data integrity in detail at the corresponding locations; S5. The report construction and verification agent synthesizes the target report based on the report outline and the specific data extracted by the multimodal data extraction agent. During the synthesis process of the target report, a dual-track verification strategy is used to verify the data consistency and logical correctness of the target report. S6. The user can preview, edit, modify and download the generated target report in real time through the user interaction interface, and conduct a detailed evaluation of the initially generated report, collect user feedback on the report content, structure and format, so as to optimize and adjust the generated target report; S7. Desensitize, summarize and analyze user feedback data through feedback learning and personalized enhancement agents, and continuously fine-tune the outline retrieval and planning agents and the base language model of the report construction and verification agents and optimize the prompt word template for personalized report generation based on the desensitized data and analysis results; Among them, in the step S4, the outline retrieval and planning agent also retrieves the report generation situation that is most similar to the current task in its historical task data as a reference prompt word, and dynamically fills the similar data into a pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base language model of the outline retrieval and planning agent to generate a report outline; In step S5, the report construction and verification agent also retrieves the report generation situation in the user's historical tasks that is most similar to the current task as a reference prompt word, and dynamically fills similar data into a pre-set prompt word template, and then uses the prompt words filled with similar data to guide the base large language model of the report construction and verification agent to generate a target report.

2. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The report requirement parsing agent, the outline retrieval and planning agent, the multimodal data extraction agent, the report construction and verification agent, and the feedback learning and personalized enhancement agent are all constructed based on the base large language model; wherein the base large language model is trained by using the data set of the field or task corresponding to the agent to train the large language model.

3. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The report generation instruction set includes a refined report generation requirement description and key intent entities extracted therefrom.

4. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The hybrid information retrieval method includes a retrieval enhancement generation method, a multimodal large language model, an optical character recognition method, and a table structure understanding method; The multimodal data source includes text, table and image data types, and the multimodal data source includes internal enterprise databases, internal enterprise files, user historical feedback data and data from public retrieval sources on the Internet.

5. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The content of the report outline is closely related to the report theme. The report outline includes a detailed and logically rigorous report structure, chapter titles and key data descriptions, and data retrieval sources to plan subsequent data acquisition tasks; among them, the data names mentioned in the report outline are only described and explained, and no specific data are listed.

6. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The following steps are used to obtain the report generation situation that is most similar to the current task: historical task data is retrieved by using an Embedding-based retrieval algorithm, and the historical task data and the relevant text of the current task are converted into vector representations using an embedding model. The similarity between the vector representation of the historical task data and the vector representation of the current task is calculated, and the report generation situation of the historical task data corresponding to the maximum similarity is selected as the report generation situation that is most similar to the current task.

7. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: In step S5, the report construction and verification agent also locates the data missing position in the target report based on the data missing record constructed by the multimodal data extraction agent when extracting the information required for the report generation instruction set and the data retrieval source, and fills or marks the data missing position in the target report according to the preset supplementary rules; The dual-track verification strategy includes a data-text mapping comparison strategy and a model reasoning verification strategy, wherein the data-text mapping comparison strategy is specifically: using semi-structured data matching and text comparison methods, the generated target report is compared with the original data one by one, and whether the numerical references, percentages, and chart descriptions are completely consistent with the original data; the model reasoning verification strategy is specifically: the original data and the generated target report are designed as two types of prompt words respectively, and the two types of prompt words are input into a dedicated large language model for reasoning to determine whether the target report is consistent with the original data.

8. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The user interaction interface includes at least an online dialog box, a report outline interaction interface and a complete report interaction interface; wherein the user interacts with the system through the online dialog box, and after generating a report outline or a target report, the user performs real-time preview, editing, modification and download operations on the report outline or the target report to achieve on-demand adjustment of the target report content.

9. The method for generating personalized complex reports based on a multi-agent system according to claim 1, characterized in that: The desensitized data includes user feedback, user original requirements, report generation instructions clarified by the report requirement parsing agent, and a complete report outline generated by the outline planning and retrieval agent; The feedback learning and personalized enhancement agent fine-tunes the base large language model of the outline retrieval and planning agent and the report construction and verification agent when the following preset conditions are met: in the generation of a fixed number of consecutive reports, the user feedback satisfaction is less than a preset satisfaction threshold; or, within a fixed time period, the common problems pointed out in the user feedback reach a preset minimum tolerance number.

Citation Information

Patent Citations

  • Method and system for generating intelligent analysis report based on large language model and process mining data

    CN116955597A

  • Personalized traffic report dynamic generation method and device based on AI intelligent agent and medium

    CN117785965A

  • Statistical report generation method and system based on large language model

    CN117875296A

  • Long text generation method based on large language model agent

    CN118210873A

  • Table data interactive processing method based on large language model

    CN118394909A