Business analysis report generation method and device and computer storage medium

By mapping report requirements information into business statistical indicators and generating target prompt words, the problem that large language models are difficult to understand professional terms is solved, and the accuracy of business analysis reports is improved.

CN119646209APending Publication Date: 2025-03-18AGRICULTURAL BANK OF CHINA
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411740033.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-29
Publication Date
2025-03-18

AI Technical Summary

Technical Problem

In the prior art, it is difficult for large language models to accurately understand professional terms or specific vocabulary in business analysis reports, resulting in low accuracy of generated business analysis reports.

Method used

By obtaining report requirements information, map it into multiple business statistical indicators based on the preset indicator relationship tree, and obtaining indicator data. Then, based on the indicator data and preset prompt word templates, the target prompt word is generated, and a large language model is input for analysis and reasoning, and a business analysis report is generated.

Benefits of technology

Improve the accuracy of business analysis report generation and avoid the problem of low accuracy caused by the difficulty of understanding specific vocabulary by large language models.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119646209A_ABST
    Figure CN119646209A_ABST
Patent Text Reader

Abstract

The invention discloses a service analysis report generation method and device and a computer storage medium. In the scheme, report demand information is acquired; the report demand information comprises key information required for generating the service analysis report; mapping the report demand information into a plurality of service statistical indexes according to a preset index relation tree; the preset index relation tree is used for representing a corresponding relation between the business statistical indexes; obtaining index data corresponding to each service statistical index; generating a target cue word based on the index data and a preset cue word template; and inputting the target cue word into the large language model, and performing analysis and reasoning on the target cue word by the large language model to generate a business analysis report. According to the technical scheme, the problem that the accuracy of the generated service analysis report is low due to the fact that a large language model is difficult to accurately understand specific vocabularies in the report demand information is solved, and the accuracy of generation of the service analysis report is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of financial technology, and in particular to a method, device and computer storage medium for generating a business analysis report. Background Art

[0002] In order to regulate various business activities, effectively conduct corporate governance and prevent risks, financial institutions have relevant systems on a monthly, quarterly and annual basis, requiring business personnel to submit business analysis reports.

[0003] At present, the existing technology usually uses a large language model to understand and process the text information input by business personnel, and then generates the corresponding SQL query statements, and generates business analysis reports by executing these SQL queries. However, since it is difficult for a large language model to accurately understand the professional terms or specific words in the text information, the accuracy of the generated business analysis report is low. Summary of the invention

[0004] Based on the above problems, the present application provides a method, device and computer storage medium for generating a business analysis report, the purpose of which is to improve the accuracy of generating a business analysis report.

[0005] The embodiments of the present application disclose the following technical solutions:

[0006] In a first aspect of the present application, a method for generating a business analysis report is provided, the method comprising:

[0007] Obtain report requirement information; the report requirement information includes key information required to generate business analysis reports;

[0008] The report requirement information is mapped into a plurality of business statistical indicators according to a preset indicator relationship tree; the preset indicator relationship tree is used to characterize the corresponding relationship between various business statistical indicators;

[0009] Obtain the indicator data corresponding to each business statistical indicator;

[0010] Generate target prompt words based on indicator data and preset prompt word templates;

[0011] The target prompt word is input into the large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report.

[0012] In an optional implementation, the report requirement information is mapped to multiple business statistical indicators according to a preset indicator relationship tree, including:

[0013] Extract multiple keywords from report requirement information;

[0014] Matching the multiple keywords with each indicator index node in the preset indicator relationship tree to obtain a matching result; the matching result includes multiple target indicator index nodes matching the multiple keywords;

[0015] A plurality of business statistical indicators are determined based on the matching results.

[0016] In an optional implementation, multiple keywords are matched with each indicator index node in a preset indicator relationship tree to obtain matching results, including:

[0017] Step 1, creating a keyword list based on multiple keywords;

[0018] Step 2: Create a queue of nodes to be matched, and add the indicator index node in the preset indicator relationship tree to the queue of nodes to be matched;

[0019] Step 3, traverse the queue of nodes to be matched, and determine whether the index node word of the index node matches any keyword in the keyword list;

[0020] Step 4: if the index node word of the indicator index node matches any keyword, the indicator index node is used as a matching node, and it is determined whether the matching node is a leaf node in the preset indicator relationship tree;

[0021] Step 5: If the matching node is a leaf node, use the matching node as the target index node;

[0022] Step 6: If the matching node is a non-leaf node, all child nodes of the matching node are added to the queue of nodes to be matched, and the matching node is deleted from the queue of nodes to be matched, and the keywords that match the index node word of the matching node are deleted from the keyword list;

[0023] Step 7: Repeat steps 3 to 6 until there are no indicator index nodes in the to-be-matched node queue, and determine the matching result based on all target indicator index nodes.

[0024] In an optional implementation, before determining whether the index node word of the indicator index node matches any keyword, the method for generating the business analysis report further includes:

[0025] Performing vectorization processing on each keyword in the keyword list and the index node word to obtain a first vector corresponding to each keyword and a second vector corresponding to the index node word; determining the similarity between each keyword and the index node word based on the first vector and the second vector;

[0026] Determine whether the index node word of the index node matches any keyword, including:

[0027] Based on the similarity between each keyword and the index node word, it is determined whether the index node word matches any keyword.

[0028] In an optional implementation, the method for generating a business analysis report further includes:

[0029] If the index node word of the indicator index node does not match any keyword, the indicator index node is deleted from the queue of nodes to be matched.

[0030] In an optional implementation, before mapping the report requirement information to a plurality of business statistical indicators according to a preset indicator relationship tree, the method for generating a business analysis report further includes:

[0031] Obtain a statistical indicator configuration table; the statistical indicator configuration table includes multiple business statistical indicators and the corresponding relationship between each business statistical indicator;

[0032] Build a preset indicator relationship tree based on the statistical indicator configuration table.

[0033] In a second aspect of the present application, a device for generating a business analysis report is provided, the device comprising:

[0034] The first acquisition module is used to acquire report requirement information; the report requirement information includes key information required to generate a business analysis report;

[0035] An indicator mapping module is used to map the report requirement information into multiple business statistical indicators according to a preset indicator relationship tree; the preset indicator relationship tree is used to characterize the corresponding relationship between various business statistical indicators;

[0036] The second acquisition module is used to obtain the indicator data corresponding to each business statistical indicator;

[0037] A first generating module, used for generating a target prompt word based on the indicator data and a preset prompt word template;

[0038] The second generation module is used to input the target prompt word into the large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report.

[0039] Optionally, the indicator mapping module includes:

[0040] An extraction unit, used for extracting multiple keywords in the report requirement information;

[0041] A matching unit, used to match multiple keywords with each indicator index node in a preset indicator relationship tree to obtain a matching result; the matching result includes multiple target indicator index nodes matching the multiple keywords;

[0042] The determination unit is used to determine multiple business statistical indicators based on the matching results.

[0043] According to a third aspect of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program is executed by a processor, the above-mentioned method for generating a business analysis report is implemented.

[0044] In a fourth aspect of the present application, a processor is provided for running a computer program, and when the computer program is running, the above-mentioned method for generating a business analysis report is executed.

[0045] Compared with the prior art, this application has the following beneficial effects:

[0046] In the technical solution of the present application, firstly, report requirement information is obtained; the report requirement information includes key information required for generating a business analysis report; then, the report requirement information is mapped into a plurality of business statistical indicators according to a preset indicator relationship tree. Since the preset indicator relationship tree can be used to characterize the correspondence between various business statistical indicators, the key information in the report requirement information can be accurately mapped into a plurality of business statistical indicators based on the preset indicator relationship tree, thereby being able to accurately obtain indicator data corresponding to each business statistical indicator; then, based on the accurate indicator data and the preset prompt word template, a target prompt word is generated, and the target prompt word is input into a large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report, thereby avoiding the problem of low accuracy of the generated business analysis report due to the difficulty of the large language model in accurately understanding specific words in the text information (i.e., the report requirement information), thereby improving the accuracy of the generated business analysis report. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.

[0048] Figure 1 A flowchart of a method for generating a business analysis report provided in an embodiment of the present application;

[0049] Figure 2 A flowchart of another method for generating a business analysis report provided in an embodiment of the present application;

[0050] Figure 3 A schematic diagram of a preset indicator relationship tree provided in an embodiment of the present application;

[0051] Figure 4A flowchart of a business statistical indicator mapping process provided in an embodiment of the present application;

[0052] Figure 5 A flowchart of another business statistical indicator mapping process provided in an embodiment of the present application;

[0053] Figure 6 A schematic diagram of the structure of a device for generating a business analysis report provided in an embodiment of the present application. DETAILED DESCRIPTION

[0054] As described above, currently, the existing technology usually uses a large language model to understand and process the text information input by business personnel, and then generates corresponding SQL query statements, and generates business analysis reports by executing these SQL queries. However, since it is difficult for a large language model to accurately understand the professional terms or specific words in the text information, the accuracy of the generated business analysis report is low.

[0055] After research, the inventor proposed a method for generating a business analysis report, which obtains report requirement information input by a user, wherein the report requirement information includes key information required for generating a business analysis report; then, based on a preset indicator relationship tree, the report requirement information is mapped into a plurality of business statistical indicators. Since the preset indicator relationship tree can be used to characterize the correspondence between various business statistical indicators, the key information in the report requirement information can be accurately mapped into a plurality of business statistical indicators based on the preset indicator relationship tree, thereby accurately obtaining indicator data corresponding to each business statistical indicator; then, based on accurate indicator data and a preset prompt word template, a target prompt word is generated, and the target prompt word is input into a large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report, thereby avoiding the problem of low accuracy of the generated business analysis report due to the difficulty of the large language model in accurately understanding specific words in text information (i.e., report requirement information), thereby improving the accuracy of the generated business analysis report.

[0056] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0057] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant laws, regulations and standards in the relevant regions.

[0058] It is understandable that in the specific implementation of this application, related data such as user information is involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of relevant data need to comply with relevant laws, regulations and standards of the relevant regions.

[0059] Keyword definitions:

[0060] Large language model: a model composed of a large-scale language model and a large number of neurons, which can predict and generate input text or other similar video, picture, voice, etc., in order to provide more information to users.

[0061] RAG: Retrieval-Augmented Generation. It is used to provide an external data source for the large language model. For questions raised by users, some information retrieval technologies are used to retrieve information related to the user's questions to form an additional external data source, which serves as the context for the large language model's question input, so as to improve the large language model's ability to provide more accurate answers to some professional field data.

[0062] Method Embodiment

[0063] An embodiment of the present application provides an embodiment of a method for generating a business analysis report. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.

[0064] See also Figure 1 , which is a flow chart of a method for generating a business analysis report provided in an embodiment of the present application, such as Figure 1 As shown, the method comprises the following steps:

[0065] Step S101, obtaining report requirement information.

[0066] In an optional embodiment, a system for generating a business analysis report can be used as the execution subject of the method for generating a business analysis report in the embodiment of the present application. For the convenience of description, the system for generating a business analysis report is referred to as a system below.

[0067] In step S101, the report requirement information includes key information required to generate a business analysis report. Figure 2 As shown, the report requirement information is text information input by the user for generating a business analysis report. For example, the user inputs text information: "Statistical report on the amount and number of first-level risk events in all risk events of each first-level branch in the operational risk module this year."

[0068] Step S102: Mapping the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree.

[0069] In step S102, a preset indicator relationship tree is used to characterize the corresponding relationship between various business statistical indicators.

[0070] In this embodiment, the preset indicator relationship tree is a relationship tree constructed based on the statistical indicator configuration table. Figure 2 In the indicator pool shown in , a statistical indicator configuration table including a plurality of the business statistical indicators and the corresponding relationship between the respective business statistical indicators is obtained, and a statistical indicator configuration table is constructed based on the statistical indicator configuration table. Figure 3 The preset indicator relationship tree shown in . The system can construct the preset indicator relationship tree according to the statistical indicator fields (e.g., measure, dimension, attribute, section, etc.) in the statistical indicator configuration table. Figure 3 Take the five-level preset indicator relationship tree shown in as an example. The fifth level of the preset indicator relationship tree is a leaf node. Except for the leaf node, each indicator index node is marked with an index node word. For example, the index node words marked with the overall situation node (i.e., the root node) are operational risk, inspection management, case management, etc., the index node words marked with the operational risk node are operational risk, and the index node words marked with the risk event node are risk events.

[0071] Alternatively, if Figure 3As shown, the first layer in the indicator relationship tree is the overall situation, specifying the modules that need to be counted in the report requirement information input by the user, including operational risk, inspection management, case management, etc.; the second layer is the field blocks that need to be counted under the specific modules, for example, field block 1: inspection management, field block 2: operational risk, field block n: case management, etc.; then the third layer is specific to the attributes based on the second layer, for example, operational risk can be specifically divided into attribute 1: risk event, attribute 2: risk level, attribute n: risk loss, etc.; then each attribute is divided into dimensions in detail, for example, risk level can be specifically divided into dimension 1: first-level event, dimension 2: second-level event, etc. The leaf nodes of the preset indicator relationship tree can be counted from the amount, quantity and proportion. If the report requirement information input by the user contains a certain metric (such as quantity), the system can match it to the specific metric node; if the report requirement information does not contain a metric, the system can count specific data from the three metrics of amount, quantity and proportion.

[0072] In this embodiment, the business statistical indicators in the statistical indicator configuration table are indicators established according to the standards of the business data, such as the business data of the "operational risk event" type, the types of operational risk events include credit events, regulatory penalty events, sued events, etc.; the business data of operational risk events can be classified into level 1 events, level 2 events, level 3 events, level 4 events, level 5 events, etc. according to the risk level; the business data of operational risk events can also be classified into the amount of loss caused by risk events and the number of risk events occurring in the same year, etc. according to the amount and quantity. Based on the above classification, business statistical indicators for operational risk events can be established, as shown in Table 1.

[0073] Table 1

[0074]

[0075] Optionally, in this embodiment, the system may obtain a statistical indicator data table, and construct a preset indicator relationship tree based on the statistical indicator configuration table and the statistical indicator data table. The system may store the above-mentioned business statistical indicators in the statistical indicator configuration table, and then periodically and batch-calculate the number of events and the amount of loss corresponding to the business statistical indicators, and include the number of events and the amount of loss in the statistical indicator data table. The statistical indicator configuration table may be shown in Table 2, and the statistical indicator data table may be shown in Table 3.

[0076] Table 2

[0077]

[0078] Table 3

[0079] Index No. mechanism time data z001 Institution A 202301 300 z002 Institution B 202301 500 … … … …

[0080] In order to solve the problem that the large language model of the prior art is difficult to accurately understand specific vocabulary in the report requirement information, in this embodiment, the system can map the report requirement information into multiple business statistical indicators based on the preset indicator relationship tree. For example, when the user inputs text information such as "Statistical operational risk module, report on the amount and number of first-level risk events among all risk events of the first-level branches in Southwest China this year", the system can map the text information into "the amount and number of first-level risk events of Southwest F4 Branch in 2024" through the preset indicator relationship tree.

[0081] Specifically, see Figure 4 , which is a flowchart of a mapping process of a business statistical indicator provided in an embodiment of the present application, and the process includes the following steps:

[0082] Step S1021, extracting multiple keywords in the report requirement information.

[0083] In this embodiment, the system can extract multiple keywords by segmenting the report demand information. For example, when the user inputs the report demand information as "amount and quantity report of first-level risk events in all risk events of first-level branches in the current year in the statistical operational risk module", the keywords extracted from the report demand information are: operational risk, current year, first-level branch, risk event, first-level risk event, amount, quantity.

[0084] Step S1022, matching the multiple keywords with each indicator index node in the preset indicator relationship tree to obtain a matching result.

[0085] In step S1022, the matching result includes multiple target indicator index nodes that match the multiple keywords.

[0086] In order to map the key information in the report requirement information into accurate business statistical indicators and avoid the problem of low accuracy of the generated business analysis report due to the difficulty of the large language model to accurately understand the specific vocabulary in the report requirement information, in this embodiment, the system can match multiple keywords with each indicator index node in the preset indicator relationship tree, and determine multiple target indicator index nodes that match the keyword based on the similarity between the index node words of each indicator index node and the keyword.

[0087] Specifically, see Figure 5 , which is a flowchart of another business statistical indicator mapping process provided in an embodiment of the present application, and the process includes the following steps:

[0088] Step 1: Create a keyword list based on multiple keywords.

[0089] Step 2: Create a queue of nodes to be matched, and add the indicator index node in the preset indicator relationship tree to the queue of nodes to be matched.

[0090] For example, Figure 3 Taking the root node (ie, the overall situation node) in the preset indicator relationship tree shown in as an example, after the system creates a queue of nodes to be matched, the system can add the overall situation node to the queue of nodes to be matched for matching.

[0091] Step 3, traverse the queue of nodes to be matched, and determine whether the index node word of the index node matches any keyword in the keyword list.

[0092] In order to accurately determine the index nodes that match multiple keywords, in this embodiment, the system can determine whether the index node word matches any keyword based on the similarity between each keyword and the index node word.

[0093] Optionally, before determining whether the index node word of the indicator index node matches any keyword, the system may vectorize each keyword in the keyword list and the index node word to obtain a first vector corresponding to each keyword and a second vector corresponding to the index node word; then, based on the first vector and the second vector, determine the similarity between each keyword and the index node word.

[0094] In this embodiment, the system may use Word2vec to perform vectorization processing on each keyword in the keyword list and the index node words.

[0095] Step 4: If the index node word of the indicator index node matches any keyword, the indicator index node is used as a matching node, and it is determined whether the matching node is a leaf node in the preset indicator relationship tree.

[0096] In this embodiment, if the indicator index node is determined to be the node with the highest similarity to the keyword based on the similarity between the index node word of the indicator index node and each keyword, the indicator index node is used as a matching node, and by judging whether the matching node is a leaf node in the preset indicator relationship tree, it is determined whether the matching node is the target indicator index node. For example, taking the keywords extracted from the report requirement information as: operational risk, risk event, and first-level risk event as an example, if the system calculates the above keywords and Figure 3The similarities between the index node words of "Domain Section 2: Operational Risk Node" are 99%, 55%, and 50% respectively, and the similarities between the index node words of "Domain Section n: Case Management Node" are 20%, 30%, and 22% respectively. The system can determine that the "Domain Section 2: Operational Risk Node" with the highest similarity matches the keyword "operational risk", and take the "Domain Section 2: Operational Risk Node" as the matching node, and then determine whether the node is a leaf node.

[0097] In this embodiment, if the index node word of the indicator index node does not match any keyword, the system may determine that the node is a non-matching node and delete the indicator index node from the queue of nodes to be matched.

[0098] Step 5: If the matching node is a leaf node, use the matching node as the target index node.

[0099] For example, if the matching node is Figure 3 As shown in the preset indicator relationship tree, the system can use the "Measurement 1 (Amount) Node" as the target indicator index node.

[0100] Step 6: If the matching node is a non-leaf node, all child nodes of the matching node are added to the queue of nodes to be matched, and the matching node is deleted from the queue of nodes to be matched, and the keywords that match the index node word of the matching node are deleted from the keyword list.

[0101] For example, if the matching node is Figure 3 The "Domain Section 2: Operational Risk Node" in the preset indicator relationship tree shown has child nodes, so the node is a non-leaf node. The system can add all the child nodes of the node: attribute 1 (risk event) node, attribute 1 (risk level) node,... attribute n (risk loss) node to the queue of nodes to be matched, and delete the "Domain Section 2: Operational Risk Node" from the queue of nodes to be matched, and delete the keyword "operational risk" from the keyword list.

[0102] Step 7: Repeat steps 3 to 6 until there are no indicator index nodes in the to-be-matched node queue, and determine the matching result based on all target indicator index nodes.

[0103] Step S1023, determining multiple business statistical indicators based on the matching results.

[0104] In this embodiment, the system can determine multiple business statistical indicators based on the node identifier of the target indicator index node in the matching result, wherein the node identifier of the target indicator index node includes the identifier of the target indicator index node and the identifiers of all parent nodes of the target indicator index node. In this embodiment, each indicator index node in the preset indicator relationship tree corresponds to a node identifier, and the node identifier includes the identifier of the indicator index node and the identifiers of all parent nodes of the indicator index node. Figure 3 Taking the "Measurement 1 (Amount) Node" in the preset indicator relationship tree shown as an example, the node identifier of the indicator index node is "Operational Risk_Risk Level_Level 1 Event_Amount", so according to the node identifier, the business statistical indicator can be determined as "Amount of Level 1 Risk Event".

[0105] Optionally, during the process of matching index nodes, if the index nodes of a certain layer cannot be matched, the system can prompt the user to complete the keywords according to the index node words of this layer, and Figure 2 The user-completed keywords shown are added back to the keyword list for matching.

[0106] Step S103, obtaining indicator data corresponding to each business statistical indicator.

[0107] In this embodiment, if Figure 2 As shown, the system can obtain the indicator data corresponding to each business statistical indicator from the business database based on the indicator statistical logic and business statistical indicators. For example, when the business statistical indicators are "the amount and number of first-level risk events of Southwest F4 Branch in 2024", the indicator data corresponding to each business statistical indicator obtained are "first-level risk events in A: amount 100, number 10; first-level risk events in B: amount 200, number 20; first-level risk events in C: amount 200, number 20; first-level risk events in E: amount 200, number 20".

[0108] Optionally, in this embodiment, the time standard of the indicator data adopts the latest time, and the institutional attribute standard adopts the institution to which the user belongs. If the report requirement information input by the user contains time attributes and regional terms, the system can standardize the above data.

[0109] Step S104: generating a target prompt word based on the indicator data and a preset prompt word template.

[0110] In order to avoid the problem of low accuracy of the generated business analysis report due to the non-standard input text of the large language model or the difficulty in accurately understanding specific vocabulary in the text information (such as specific indicator data), in an embodiment of the present application, the system can adopt the RAG method to generate target prompt words through preset prompt word templates and indicator data to standardize the input text of the large language model so that the large language model can accurately understand the specific indicator data.

[0111] Optionally, the preset prompt word template may include the following types:

[0112] (1) Chart: Please create a bar chart based on [xx indicator] under [xx institution] in [xx year].

[0113] (2) Report: Please create a statistical report based on [xx year] [xx organization] [xx indicator], with the horizontal axis being [xx indicator] [amount, quantity, percentage] and the vertical axis being [xx organization]. Create a report.

[0114] (3) Summary: Compare [xx indicator...] of [xx institution] in [xx year] with [xx indicator] of [xx institution] to generate an analysis report.

[0115] For example, when the indicator data are "Level 1 risk events of Branch A: amount 100, quantity 10; Level 1 risk events of Branch B: amount 200, quantity 20; Level 1 risk events of Branch C: amount 200, quantity 20; Level 1 risk events of Branch E: amount 200, quantity 20", and the preset prompt word template is a report, the target prompt words generated by the system are: "Please create a statistical report based on the Level 1 risk events of Branch A in 2024: amount 100, quantity 10; Level 1 risk events of Branch B: amount 200, quantity 20; Level 1 risk events of Branch C: amount 200, quantity 20; Level 1 risk events of Branch E: amount 200, quantity 20, with the horizontal axis being the amount of Level 1 risk events and the number of Level 1 risk events, and the vertical axis being the name of the institution".

[0116] Step S105: input the target prompt word into the large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report.

[0117] For example, when the target prompt word is "Please create a statistical report based on the first-level risk events of Branch A in 2024: amount 100, quantity 10; first-level risk events of Branch B: amount 200, quantity 20; first-level risk events of Branch C: amount 200, quantity 20; first-level risk events of Branch E: amount 200, quantity 20, with the horizontal axis being the amount of first-level risk events and the number of first-level risk events, and the vertical axis being the name of the institution", the system language model analyzes and infers the target prompt word, and the generated business analysis report can be as shown below.

[0118] The following is a table of the amount and number of first-level risk events for Branch A, Branch B, Branch C, and Branch E:

[0119] Institution Name Amount of Level 1 risk event Number of Level 1 risk events Branch A 100 10 Branch B 200 20 Branch C 200 20 E Branch 200 20

[0120] The horizontal axis is the amount of the first-level risk event, and the vertical axis is the name of the institution.

[0121] Through the method for generating a business analysis report provided in the embodiment of the present application, it is achieved that based on the preset indicator relationship tree, the key information in the report requirement information is accurately mapped to multiple business statistical indicators, so that the indicator data corresponding to each business statistical indicator can be accurately obtained; then, based on the accurate indicator data and the preset prompt word template, the target prompt word is generated, and the target prompt word is input into the large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report, thereby avoiding the problem of low accuracy of the generated business analysis report due to the difficulty of the large language model in accurately understanding specific words in the text information (i.e., the report requirement information), and improving the accuracy of the generated business analysis report.

[0122] The method for generating a business analysis report provided in the embodiment of the present application adopts the standardized management of the indicator pool quantification and analyzable content, and maps the keywords in the report requirement information input by the user to specific business statistical indicators based on the preset indicator relationship tree and indicator index algorithm, thereby obtaining accurate indicator data. The RAG method is adopted to generate standardized input text (i.e., target prompt words) based on accurate indicator data and preset prompt word templates to avoid hallucinations in the output results of the large language model, thereby improving the accuracy of the generated business analysis report. In addition, the method for generating a business analysis report provided in the embodiment of the present application can maximize the use of the analytical reasoning capabilities of the large language model to generate a customized and detailed business analysis report, thereby improving the flexibility and richness of the generated business analysis report.

[0123] Device Embodiment

[0124] The embodiment of the present application provides a device for generating a business analysis report, wherein: Figure 6 A schematic diagram of a structure of a device for generating a business analysis report provided in an embodiment of the present application, such as Figure 6 As shown, the device includes: a first acquisition module 11, an indicator mapping module 12, a second acquisition module 13, a first generation module 14 and a second generation module 15. Figure 6 You can see the connection relationship between several modules.

[0125] The first acquisition module 11 is used to acquire report requirement information; the report requirement information includes key information required for generating a business analysis report;

[0126] The indicator mapping module 12 is used to map the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree; the preset indicator relationship tree is used to characterize the corresponding relationship between various business statistical indicators;

[0127] The second acquisition module 13 is used to obtain the indicator data corresponding to each business statistical indicator;

[0128] A first generating module 14, for generating a target prompt word based on the indicator data and a preset prompt word template;

[0129] The second generating module 15 is used to input the target prompt word into the large language model, and the large language model analyzes and infers the target prompt word to generate a business analysis report.

[0130] Optionally, the indicator mapping module includes: an extraction unit, a matching unit and a determination unit.

[0131] An extraction unit, used for extracting multiple keywords in the report requirement information;

[0132] A matching unit, used to match multiple keywords with each indicator index node in a preset indicator relationship tree to obtain a matching result; the matching result includes multiple target indicator index nodes matching the multiple keywords;

[0133] The determination unit is used to determine multiple business statistical indicators based on the matching results.

[0134] Optionally, the matching unit includes: a first creating unit, a second creating unit, a first judging unit, a first determining unit, a second determining unit, an operating unit and a repeating executing unit.

[0135] A first creating unit, configured to execute step 1, creating a keyword list based on multiple keywords;

[0136] A first creation unit is used to execute step 2, create a to-be-matched node queue, and add the indicator index node in the preset indicator relationship tree to the to-be-matched node queue;

[0137] A first judgment unit is used to execute step 3, traverse the queue of nodes to be matched, and judge whether the index node word of the index node matches any keyword in the keyword list;

[0138] A first determination unit is used to execute step 4, if the index node word of the indicator index node matches any keyword, the indicator index node is used as a matching node, and whether the matching node is a leaf node in a preset indicator relationship tree;

[0139] A second determination unit is used to execute step 5, and if the matching node is a leaf node, use the matching node as a target indicator index node;

[0140] An operation unit, configured to execute step 6, if the matching node is a non-leaf node, then add all child nodes of the matching node to a queue of nodes to be matched, delete the matching node from the queue of nodes to be matched, and delete the keyword that matches the index node word of the matching node from the keyword list;

[0141] The repeating execution unit is used to execute step 7, repeatedly execute steps 3 to 6, until there is no indicator index node in the queue of nodes to be matched, and determine the matching result based on all target indicator index nodes.

[0142] Optionally, the device for generating a business analysis report further includes: a processing module and a similarity determination module.

[0143] The processing module is used to perform vectorization processing on each keyword in the keyword list and the index node word to obtain a first vector corresponding to each keyword and a second vector corresponding to the index node word;

[0144] The similarity determination module is used to determine the similarity between each keyword and the index node word based on the first vector and the second vector.

[0145] Optionally, the first judgment unit includes: a second judgment unit, configured to judge whether the index node word matches any keyword based on the similarity between each keyword and the index node word.

[0146] Optionally, the business analysis report generating device further includes: a deleting unit, configured to delete the indicator index node from the queue of nodes to be matched if the index node word of the indicator index node does not match any keyword.

[0147] Optionally, the device for generating a business analysis report further includes: an acquisition unit and a construction unit.

[0148] The acquisition unit is used to acquire a statistical indicator configuration table; the statistical indicator configuration table includes multiple business statistical indicators and the corresponding relationship between each business statistical indicator;

[0149] A construction unit is used to construct a preset indicator relationship tree based on the statistical indicator configuration table.

[0150] Storage Medium Embodiments

[0151] The embodiment of the present application provides a computer-readable storage medium, on which a program is stored, wherein when the program is executed by a processor, some or all of the steps in the method for generating a business analysis report described in the aforementioned method embodiment of the present application are implemented. The storage medium can be a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, and other media that can store program codes.

[0152] Processor Embodiments

[0153] An embodiment of the present application provides a processor, which is used to run a program, wherein when the program is running, some or all of the steps in the method for generating a business analysis report introduced in the aforementioned method embodiment are executed.

[0154] It should be noted that each embodiment in this specification is described in a progressive manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment. The device embodiment described above is merely schematic, in which the unit described as a separate component may or may not be physically separated, and the component prompted as a unit may or may not be a physical unit, that is, it may be located in one place, or it may be distributed on multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative work.

[0155] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for generating a business analysis report, characterized in that: include: Obtain information on reporting requirements; The report requirement information includes key information required for generating a business analysis report; Mapping the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree; the preset indicator relationship tree is used to characterize the corresponding relationship between each of the business statistical indicators; Obtaining indicator data corresponding to each of the business statistical indicators; Generate a target prompt word based on the indicator data and a preset prompt word template; The target prompt word is input into a large language model, and the large language model analyzes and infers the target prompt word to generate the business analysis report.

2. The method according to claim 1, characterized in that The mapping of the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree includes: extracting a plurality of keywords from the report requirement information; Matching the multiple keywords with each indicator index node in the preset indicator relationship tree to obtain a matching result; the matching result includes a plurality of target indicator index nodes matching the multiple keywords; A plurality of business statistical indicators are determined based on the matching results.

3. The method according to claim 2, characterized in that The matching of the plurality of keywords with each indicator index node in the preset indicator relationship tree to obtain a matching result includes: Step 1, creating a keyword list based on a plurality of the keywords; Step 2, creating a queue of nodes to be matched, and adding the indicator index nodes in the preset indicator relationship tree to the queue of nodes to be matched; Step 3, traversing the queue of nodes to be matched, and determining whether the index node word of the index node matches any of the keywords in the keyword list; Step 4: if the index node word of the indicator index node matches any of the keywords, the indicator index node is used as a matching node, and it is determined whether the matching node is a leaf node in the preset indicator relationship tree; Step 5: If the matching node is the leaf node, use the matching node as the target indicator index node; Step 6: If the matching node is a non-leaf node, all child nodes of the matching node are added to the queue of nodes to be matched, and the matching node is deleted from the queue of nodes to be matched, and the keywords that match the index node word of the matching node are deleted from the keyword list; Step 7: Repeat steps 3 to 6 until the indicator index node does not exist in the to-be-matched node queue, and determine the matching result based on all the target indicator index nodes.

4. The method according to claim 3, characterized in that Before determining whether the index node word of the indicator index node matches any of the keywords, the method further includes: Performing vectorization processing on each of the keywords in the keyword list and the index node words to obtain a first vector corresponding to each of the keywords and a second vector corresponding to the index node words; determining the similarity between each of the keywords and the index node words based on the first vector and the second vector; The determining whether the index node word of the indicator index node matches any of the keywords includes: Based on the similarity between each of the keywords and the index node words, it is determined whether the index node word matches any of the keywords.

5. The method according to claim 3, characterized in that: The method further comprises: If the index node word of the indicator index node does not match any of the keywords, the indicator index node is deleted from the queue of nodes to be matched.

6. The method according to claim 1, characterized in that Before mapping the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree, the method further includes: Obtaining a statistical indicator configuration table; the statistical indicator configuration table includes a plurality of the business statistical indicators and a corresponding relationship between the respective business statistical indicators; The preset indicator relationship tree is constructed based on the statistical indicator configuration table.

7. A device for generating a business analysis report, characterized in that: include: A first acquisition module is used to acquire report requirement information; The report requirement information includes key information required for generating a business analysis report; An indicator mapping module, used to map the report requirement information into a plurality of business statistical indicators according to a preset indicator relationship tree; the preset indicator relationship tree is used to characterize the corresponding relationship between each of the business statistical indicators; A second acquisition module is used to acquire indicator data corresponding to each of the business statistical indicators; A first generating module, used for generating a target prompt word based on the indicator data and a preset prompt word template; The second generating module is used to input the target prompt word into the large language model, and the large language model analyzes and infers the target prompt word to generate the business analysis report.

8. The device according to claim 7, characterized in that The indicator mapping module includes: An extraction unit, used to extract multiple keywords from the report requirement information; A matching unit, used to match the plurality of keywords with each indicator index node in the preset indicator relationship tree to obtain a matching result; the matching result includes a plurality of target indicator index nodes that match the plurality of keywords; A determination unit is used to determine a plurality of business statistical indicators based on the matching result.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method for generating a business analysis report according to any one of claims 1 to 6 is implemented.

10. A processor, characterized in that: Used to run a computer program, which, when running, executes the method for generating a business analysis report according to any one of claims 1 to 6.

Citation Information

Cited By

  • Rod pumped well working condition diagnosis and report generation method based on large language model

    CN120217123A