A multi-model-based audit flowchart question-and-answer generation method

CN122616559BActive Publication Date: 2026-10-20XIANGJIANG LAB
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611100748.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-07-23
Publication Date
2026-10-20
Estimated Expiration
2046-07-23

AI Technical Summary

Technical Problem

然而,现有流程图问答生成技术存在显著瓶颈:其一,模型调用缺乏智能调度,固定使用单一模型难以应对复杂流程图,而静态并行多模型则导致资源冗余,无法在响应速度与计算效率间取得平衡;其二,流程图解析与后续推理未有效解耦,易在后续阶段重复调用视觉大模型或重复解析图像,造成结果不一致与计算开销增加;其三,问题生成缺乏覆盖率与均衡度约束,未建立针对节点覆盖与覆盖差异的自适应补全机制,造成问题集对流程结构覆盖不足或分布不均,最终导致对审计流程图的问答生成不准确

Benefits of technology

[0004]有益效果:该方法在得到节点集与有向边集之后不再进行解析,避免了对审计流程图的重复解析,提高了处理一致性并降低了计算开销;基于所述节点集与所述有向边集计算出审计流程图的复杂度评分,并根据审计流程图的复杂度评分确定大模型数量,在提高问题生成全面性的同时,平衡了计算效率;对若干个大模型生成的候选问题集进行语义去重,并基于所述问题覆盖差异与所述节点覆盖差异对所述初始问题集进行补全,提高了问题集的多样性与覆盖性,进而提高了最终问答对的准确性和可信度。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122616559B_ABST
    Figure CN122616559B_ABST
Patent Text Reader

Abstract

The application relates to a multi-model-based audit flowchart question-answer generation method, which no longer performs analysis after obtaining a node set and a directed edge set, avoids repeated analysis of the audit flowchart, improves processing consistency, and reduces calculation overhead; the complexity score of the audit flowchart is calculated based on the node set and the directed edge set, and the number of large models is determined according to the complexity score of the audit flowchart, so that the problem generation comprehensiveness is improved, and the calculation efficiency is balanced; the candidate question sets generated by the several large models are subjected to semantic deduplication, and the initial question set is supplemented based on the problem coverage difference and the node coverage difference, so that the diversity and coverage of the question set are improved, and the accuracy and reliability of the final question-answer pair are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of audit flowchart question and answer generation technology, and in particular to a multi-model-based audit flowchart question and answer generation method. Background Technology

[0002] Audit flowcharts, as a structured representation of audit business processes, control point settings, and evidence flow relationships, serve as crucial evidence for audit execution, training, and knowledge accumulation. However, existing flowchart question-and-answer generation technologies suffer from significant bottlenecks: First, model calls lack intelligent scheduling; using a single model is insufficient for complex flowcharts, while static parallel multi-models lead to resource redundancy, failing to balance response speed and computational efficiency. Second, flowchart parsing and subsequent reasoning are not effectively decoupled, easily resulting in repeated calls to large visual models or repeated image parsing in later stages, leading to inconsistent results and increased computational overhead. Third, question generation lacks coverage and balance constraints; no adaptive completion mechanism for node coverage and coverage differences has been established, resulting in insufficient or uneven coverage of the process structure in the question set, ultimately leading to inaccurate question-and-answer generation for audit flowcharts. Summary of the Invention

[0003] Therefore, it is necessary to provide a multi-model-based audit flowchart question-and-answer generation method, including: S1: Parse the image data of the audit flowchart uploaded by the user to obtain the node set and directed edge set in the audit flowchart; S2: Calculate the complexity score of the audit flowchart based on the node set and the directed edge set, and determine the number of large models based on the complexity score; the large models are used to generate a candidate question set based on the audit flowchart; S3: When the number of large models is 1, the candidate question set generated by the corresponding large model is used as the initial question set. When the number of large models is two or more, semantic deduplication is performed on the candidate question sets generated by all large models to obtain the initial question set. S4: Construct a relationship matrix between problems and nodes based on the initial problem set and the node set; calculate the problem coverage difference and node coverage difference based on the relationship matrix, and complete the initial problem set based on the problem coverage difference and node coverage difference to obtain the final problem set; S5: Process the final question set through the large model to generate the final question-answer pairs.

[0004] Beneficial effects: This method eliminates the need for repeated parsing of the audit flowchart after obtaining the node set and directed edge set, thus improving processing consistency and reducing computational overhead. It calculates the complexity score of the audit flowchart based on the node set and directed edge set, and determines the number of large models based on the complexity score, balancing computational efficiency while improving the comprehensiveness of question generation. Semantic deduplication is performed on the candidate question sets generated by several large models, and the initial question set is completed based on the differences in question coverage and node coverage, improving the diversity and coverage of the question set, thereby enhancing the accuracy and credibility of the final question-answer pairs. Attached Figure Description

[0005] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0006] Figure 1 This is a flowchart of the multi-model-based audit flowchart question-and-answer generation method in this application embodiment.

[0007] Figure 2 This is a schematic diagram of the audit flowchart in the embodiments of this application. Detailed Implementation

[0008] To make the above-mentioned objectives, features, and advantages of this application more apparent and understandable, the specific embodiments of this application are described in detail below with reference to the accompanying drawings. Many specific details are set forth in the following description to provide a thorough understanding of this application. However, this application can be implemented in many other ways different from those described herein, and those skilled in the art can make similar modifications without departing from the spirit of this application. Therefore, this application is not limited to the specific embodiments disclosed below.

[0009] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "multiple" means at least two, such as two, three, etc., unless otherwise explicitly specified.

[0010] like Figure 1 As shown, this embodiment provides a multi-model-based audit flowchart question-and-answer generation method, including: S1: Parse the image data of the audit flowchart uploaded by the user to obtain the node set and directed edge set in the audit flowchart.

[0011] In this embodiment, the image data of the audit flowchart is an image file of the audit business process, such as screenshots or scans of audit flowcharts for procurement payment process, expense reimbursement process, revenue recognition process, etc.

[0012] In some embodiments of this application, image data of audit flowcharts uploaded by users can be obtained through the upload interface of the audit system.

[0013] Specifically, the parsing of the image data of the audit flowchart uploaded by the user includes: The visual big data model is invoked to parse the image data of the audit flowchart, formalizing the audit flowchart into a directed graph. The directed graph includes a set of nodes. Directed edge set Node type set Edge type set The node types in the node type set include judgment nodes and processing nodes; the edge types in the edge type set include normal directed edges, abnormal edges, and backtracking edges. The normal directed edge is the edge that the judgment node is deemed qualified and points to the processing node, or the directed edge between processing nodes pointing to each other in node order. The abnormal edge is a directed edge that is judged as unqualified by the judgment node and points to the processing node; The back edge is a directed edge between processing nodes that points in reverse order of the nodes.

[0014] In some embodiments of this application, the visual large model is used to identify node text, decision / branch structure, arrow connection direction and connection relationship between nodes in the flowchart, thereby outputting node set and directed edge set.

[0015] It should be noted that after obtaining the set of nodes and the set of directed edges, subsequent steps are all based on the structured data formed by the set of nodes and the set of directed edges, and the large visual model is no longer called, nor is the image data of the audit flowchart parsed again.

[0016] For example, the flowchart of this embodiment is "Student Exchange Application and Credit Recognition Flowchart", and the set of nodes and the set of directed edges obtained by visual parsing are shown in Table 1; Table 1. Audit Flowchart Node Contents v1 College students submit applications v2 Approval by the college and the academic affairs office v3 Office of International Exchange and Cooperation reviews materials v4 Language ability v5 Learning a language v6 The Office of International Exchange and Cooperation organized an expert review. v7 Students sign study abroad agreements with the school, and the college and students develop course selection plans. v8 The college is responsible for providing full guidance and management, with the Office of International Exchange and Cooperation assisting in the management. v9 Students submit learning summaries to the college upon returning to their home countries. v10 The Academic Affairs Office handles credit transfer and recognition. Based on Table 1, to facilitate the subsequent statistics of "rework / return" edges, this embodiment will be as follows: Figure 2In the audit flowchart shown, the rework semantics of "non-compliant → language learning" and "return to language proficiency reassessment after language learning" are explicitly represented as back edges. An example of the process is as follows: (v1→v2), (v2→v3), (v3→v4), (v4→v6) (qualified), (v4→v5) (unqualified), (v5→v4) (reworked back to language ability), (v6→v7), (v7→v8), (v8→v9), (v9→v10).

[0017] S2: Calculate the complexity score of the audit flowchart based on the node set and the directed edge set, and determine the number of large models based on the complexity score; the large models are used to generate a candidate question set based on the audit flowchart.

[0018] Specifically, the calculation of the complexity score of the audit flowchart based on the node set and the directed edge set includes: An adjacency matrix is ​​constructed based on the node set and the directed edge set. The formula for calculating the element values ​​in the adjacency matrix is: ; in, Represents a node i Pointing to node j The element value corresponding to the directed edge, Indicates the first i 1 node Indicates the first j 1 node Represents a node i With nodes j The directed edges formed.

[0019] In this embodiment, an adjacency matrix is ​​constructed based on the directed graph, and the adjacency matrix A is shown in Table 2; Table 2 Adjacency Matrix v1 0 1 0 0 0 0 0 0 0 0 v2 0 0 1 0 0 0 0 0 0 0 v3 0 0 0 1 0 0 0 0 0 0 v4 0 0 0 0 1 1 0 0 0 0 v5 0 0 0 1 0 0 0 0 0 0 v6 0 0 0 0 0 0 1 0 0 0 v7 0 0 0 0 0 0 0 1 0 0 v8 0 0 0 0 0 0 0 0 1 0 v9 0 0 0 0 0 0 0 0 0 1 v10 0 0 0 0 0 0 0 0 0 0 The in-degree and out-degree of each node are calculated based on the adjacency matrix, using the following formula: ; ; in, Represents a node i The degree of exit, Represents a node i in-degree, Indicates the number of nodes. Represents a node j Pointing to node i The element value corresponding to the directed edge.

[0020] Based on the data shown in Table 2, the out-degree vector is dout = [1,1,1,2,1,1,1,1,1,1,0], with in-degree vector as d in = [0,1,1,2,1,1,1,1,1,1].

[0021] The number of nodes and the number of directed edges are determined based on the node set and the directed edge set. The formula for calculating the number of directed edges is: ; in, The modulus of a directed edge set is represented.

[0022] The density of a directed graph is calculated based on the number of nodes and the number of directed edges. The formula is as follows: ; ; ; in, Represents the density of a directed graph. This indicates the number of directed edges. Indicates the number of nodes. The modulus of the node set is represented; in this embodiment, N=10, M=10, Den(G)=0.111111.

[0023] Calculate the first proportion of any node type based on the number of occurrences of that node type in the node set, and calculate the node type entropy based on the first proportion of all node types in the node type set. The calculation formula is as follows: ; ; in, Represents the node type entropy. Represents a set of node types. This represents the first percentage of the t-th node type. This represents the node type mapping function. In this embodiment, v4 "language ability" is considered a judgment node, and all other nodes are considered processing nodes. Therefore, there are 9 processing nodes and 1 judgment node, and the node type entropy is... .

[0024] The branch load is calculated based on the out-degree of all nodes, and the merge load is calculated based on the in-degree of all nodes. The calculation formula is as follows: ; ; in, Indicates branch load. Indicates the convergence of loads. Indicates the out-degree of all nodes. This represents the in-degree of all nodes. In this embodiment, only node v4 has both a branch (out-degree of 2) and a merge (in-degree of 2), therefore, B=1, J=1.

[0025] The cyclomatic complexity is calculated based on the number of nodes, the number of directed edges, and the number of connected components. The formula is as follows: ; in, Indicate cyclomatic complexity, This represents the number of connected components (P=1). In this embodiment, .

[0026] The maximum or average depth of nodes in the node set is used as the nesting depth indicator, and the calculation formula is as follows: ; ; in, Indicates the maximum depth of the node. Indicates the average depth of the node. This represents the depth recognition function. In this embodiment, , .

[0027] Identify abnormal edges and back edges. The ratio of the sum of the number of abnormal edges and back edges to the number of directed edges is taken as the abnormal edge ratio, calculated as follows: ; in, Indicates the proportion of abnormal edges. This represents the sum of the number of abnormal edges and backoff edges. In this embodiment, node v4 is the judgment node. The directed edge pointing from node v4 to node v5 that is deemed unqualified is considered an abnormal edge, i.e., "language ability (unqualified) → learning language" is considered an abnormal edge. The directed edge pointing from node v5 to node v4 is considered a backoff edge, i.e., "learning language → language ability" is considered a backoff edge. ,therefore, 0.2.

[0028] In this embodiment, the criteria for determining whether something is qualified or unqualified are as follows: the value in the judgment node is compared with the corresponding threshold. If the value exceeds the threshold, it is determined to be qualified; otherwise, it is determined to be unqualified.

[0029] The backtracking edges are identified, and the rework loop strength is calculated based on the number of backtracking edges and the loop itself. The calculation formula is as follows: ; in, Indicates the strength of the rework circuit. Indicates the return edge. Indicates empty, Indicates the loop index. Indicates the total number of loops. Indicates an indicator function, This indicates that there is a loop containing a back edge in this embodiment, namely v4→v5→v4. Therefore, the rework loop strength is... The value is 1. The circuit is a directed edge path that passes through several directed edges and points back to itself.

[0030] Identify the responsible parties corresponding to the nodes, specifically by establishing a mapping of responsible parties. The responsible parties are mapped based on the node content. In this embodiment, the responsible parties for v1, v4, v5, and v9 are students, the responsible parties for v2 are the college and the academic affairs office, the responsible parties for v3 and v6 are the office of international exchange and cooperation, the responsible parties for v7 and v8 are the college, and the responsible party for v10 is the academic affairs office.

[0031] The number of directed edges where two nodes belong to the same directed edge but have different responsible parties is counted as the number of cross-party interaction edges; the quotient of the number of cross-party interaction edges and the number of directed edges is the cross-party interaction rate, calculated as follows: ; ; in, Indicates the cross-subject interaction rate. This represents the number of cross-subject interaction edges. In this embodiment, , 0.7.

[0032] The second proportion of a responsible entity is calculated based on the number of occurrences of any responsible entity in the node set, and the subject diversity entropy is calculated based on the second proportion of all responsible entities in the responsible entity set. The calculation formula is as follows: ; ; in, Represents the entropy of subject diversity. Indicates the total number of responsible parties. This represents the second percentage of the responsible party. In this embodiment, .

[0033] The control point nodes and evidence nodes in the processing nodes are identified. The third proportion of control point nodes in the node set is used as the control point density, and the fourth proportion of evidence nodes in the node set is used as the evidence node density. The calculation formula is as follows: ; ; in, Indicates the density of control points. Indicates the density of evidence nodes. Indicates the number of control point nodes. This indicates the number of evidence nodes. In this embodiment, nodes of the "Approval / Review / Approval" type are used as control point nodes (such as v2, v6, v10), and nodes of the "Review Materials / Learning Summary" type are used as evidence nodes (such as v3, v9). , .

[0034] The evidence load is calculated based on the number of evidence items carried by all evidence nodes, using the following formula: ; in, Indicates the evidentiary load, Indicates evidence nodes, This represents the number of evidence items carried by any given evidence node. In this embodiment, the material required for node v3 includes 3 items, and node v9 requires only one summary item, thus constituting the evidence payload. .

[0035] The complexity score is obtained by weighted summing of the normalized number of nodes, number of directed edges, directed graph density, node type entropy, branch load, merging load, cyclomatic complexity, nesting depth index, abnormal edge ratio, rework loop strength, cross-subject interaction rate, subject diversity entropy, control point density, evidence node density, and evidence load.

[0036] The process of calculating the complexity score by weighted summation is as follows: The normalized values ​​of the number of nodes, the number of directed edges, the directed graph density, and the node type entropy are summed to obtain the score for the structure size dimension. In this embodiment, the structure size dimension score is... ; The normalized branch load, merge load, cyclomatic complexity, and nesting depth (maximum depth) values ​​are summed to obtain the control flow logic dimension score. In this embodiment, the control flow logic dimension score is... ; The normalized abnormal edge ratio and the rework loop strength are summed to obtain the abnormal rework dimension score. In this embodiment, the abnormal rework dimension score is... ; The normalized cross-subject interaction rate and the subject diversity entropy are summed to obtain the organizational interaction dimension score. In this embodiment, the organizational interaction dimension score is... ; The normalized control point density, evidence node density, and evidence load are summed to obtain the control evidence dimension score. In this embodiment, the control evidence dimension score is... ; A corresponding fusion weight is assigned to each dimension score, and the scores of all dimensions are weighted and summed based on the fusion weight to obtain the complexity score. The calculation formula is as follows: ; ; in, Indicates the complexity score. This represents the fusion weight of the score in the k-th dimension. This represents the score for the k-th dimension. In this embodiment, let the fusion weights be... ,but .

[0037] Furthermore, determining the number of large models based on the complexity score includes: The first complexity threshold and the second complexity threshold are determined based on the distribution of complexity scores in the historical audit flowchart, and the first complexity threshold is less than the second complexity threshold. In this embodiment, the complexity scores in the complexity score set of the historical audit flowchart are arranged from smallest to largest. The first complexity threshold is the 1 / 3 quantile of the complexity score set, and the second complexity threshold is the 2 / 3 quantile of the complexity score set.

[0038] When the complexity score is less than or equal to the first complexity threshold, the number of large models is a first preset value (e.g., 1). When the complexity score is greater than the first complexity threshold and less than or equal to the second complexity threshold, the number of large models is a second preset value (e.g., 3). When the complexity score is greater than the second complexity threshold, the number of large models is a third preset value (e.g., 5).

[0039] In this embodiment, First complexity threshold Second complexity threshold Therefore, the number of large models is 3.

[0040] S3: When the number of large models is 1, the candidate question set generated by the corresponding large model is used as the initial question set. When the number of large models is two or more, semantic deduplication is performed on the candidate question sets generated by all large models to obtain the initial question set.

[0041] In this embodiment, the number of large models, m, is 3, and the candidate problem sets generated by each large model are shown in Table 3. Table 3. Output results of the candidate question set (partial examples) 1 "What's the next step after a student submits an application?"; "What's the next step after the college and the Academic Affairs Office approve the application?"; "What's the next step after the Office of International Exchange and Cooperation reviews the application materials?" 2 "What's the next step after achieving satisfactory language proficiency?"; "What's the next step after failing to achieve satisfactory language proficiency?"; "What's the next step after learning the language?"; "What's the next step after the Office of International Exchange and Cooperation organizes expert reviews?"; "What's the next step after students sign study abroad agreements with the university and the college and students develop course selection plans?" 3 "What's the next step after the college provides full guidance and management, with the Office of International Exchange and Cooperation assisting?"; "What's the next step after students submit their learning summaries to the college upon returning home?"; "What's the step before the Academic Affairs Office processes credit transfer and recognition?" Specifically, the semantic deduplication of the candidate question sets generated by all large models includes: Encode each candidate question in the set of all candidate questions into a corresponding semantic vector, and calculate the cosine similarity between any two semantic vectors; When the cosine similarity is greater than or equal to a preset similarity threshold When the time comes, delete the candidate question corresponding to either of the two corresponding semantic vectors, until all candidate questions have been traversed, resulting in an initial question set. In this embodiment, it is set that... Therefore, after performing semantic deduplication on all candidate problems, the initial problem set contains a total of 24 initial problems.

[0042] In this embodiment, when the cosine similarity is greater than or equal to a preset similarity threshold... When determining if two candidate problems are duplicates, deduplication can be performed by comparing their quality scores. Specifically, the candidate problem with the higher quality score among the duplicates is retained. The quality score formula is: ; ; ; ; ; ; in, Representing candidate problems Quality rating Representing candidate problems Clarity rating Representing candidate problems Specificity score Representing candidate problems Graph structure association scoring, Representing candidate problems Length, This indicates the preset ideal problem length. Representing candidate problems The extracted keyword set represents a dictionary consisting of a node name dictionary and audit process terminology. Representing candidate problems Graph structure association scoring, Representation and candidate problem The set of successfully matched nodes The weighting of the clarity score indicates the weighting of the score. This indicates the weight of the specificity score. This represents the weight of the graph structure association score.

[0043] S4: Construct a relationship matrix between problems and nodes based on the initial problem set and the node set; calculate the problem coverage difference and node coverage difference based on the relationship matrix, and complete the initial problem set based on the problem coverage difference and node coverage difference to obtain the final problem set.

[0044] Specifically, constructing the relationship matrix between problems and nodes based on the initial problem set and the node set includes: Each initial question in the initial question set is hard-matched or soft-matched with the name dictionary of any node. If the match is successful, the relationship value between the corresponding initial question and the node is set to 1; otherwise, it is set to 0. The hard matching is to determine whether the name in the name dictionary of the node is contained in the initial question. The soft matching is to determine whether the maximum cosine similarity between the semantic vector of the initial question and the semantic vector of the name in the name dictionary of the node is greater than or equal to the semantic threshold. The matching expression is: ; ; ; ; in, Indicates the first i An initial question With the j Nodes Relationship value, This represents the matching function. This represents a hard-match function. This represents a soft-matching function. Indicates an indicator function, Indicates the first j Nodes The first in the name dictionary A name, Represents semantic encoding, Represents cosine similarity. This indicates that it exists. Indicates that it is included in, Indicates or, Indicates the semantic threshold.

[0045] The relationship matrix is ​​constructed by sequentially traversing each initial problem in the initial problem set and each node in the node set, based on the relationship value between any initial problem and any node.

[0046] Furthermore, the calculation of problem coverage difference and node coverage difference based on the relation matrix includes: Summing the relation values ​​corresponding to all nodes that successfully match any initial problem yields the number of covered nodes for that initial problem. The formula is: ; in, Indicates the first i The number of nodes covered by the initial problem.

[0047] Summing the relation values ​​corresponding to all initial problems that successfully match any node yields the number of problems involved in the corresponding node, calculated as follows: ; in, Indicates the first j The number of nodes involved in the problem. Indicates the relationship with the first j The number of initial questions that each node successfully matched.

[0048] Calculate the first mean of the number of nodes covered by all initial problems, and the second mean of the number of nodes involved in the problems, using the following formulas: ; ; in, This represents the first mean. This represents the second mean.

[0049] Calculate the first variance between the number of covered nodes for each initial problem and the first mean. The first variance is the problem coverage difference, and the calculation formula is: ; in, This indicates differences in the coverage of the issue.

[0050] Calculate the second variance between the number of issues involved in each node and the second mean. The second variance is the node coverage difference, calculated as follows: ; in, This indicates differences in node coverage.

[0051] Furthermore, the step of completing the initial problem set based on the problem coverage difference and the node coverage difference includes: The first coefficient of variation is calculated based on the problem coverage difference and the first mean, and the calculation formula is as follows: ; in, This represents the first coefficient of variation. This represents a constant used to prevent the denominator from being zero.

[0052] The second coefficient of variation is calculated based on the node coverage difference and the second mean, and the calculation formula is as follows: ; in, This represents the second coefficient of variation. Represents a constant.

[0053] The node coverage rate is calculated as the percentage of nodes in the node set whose number of nodes involved in the problem is greater than 0, which is the fifth highest percentage of such nodes. The formula is as follows: ; in, This represents node coverage. In this embodiment, .

[0054] Nodes whose number of issues is less than or equal to a preset node coverage threshold will be considered under-covered nodes. Based on the first coefficient of variation, the second coefficient of variation, and the node coverage rate, the completion trigger command value is determined using the following formula: ; in, This indicates that the trigger command value has been completed. Indicates an indicator function, This represents the first coefficient of variation. This represents the second coefficient of variation. Indicates node coverage. Indicates the first threshold. This represents the second threshold. This represents the third threshold. Indicates or; For each undercovered node, a supplementary question is generated, and the relation matrix is ​​updated until the completion trigger instruction value is not 1 or the maximum number of iterations is reached, resulting in the final question set. In this embodiment, the final question set contains 16 final questions, and the relation matrix corresponding to the final question set is shown in Table 4, where 1 indicates that the final question involves the corresponding node.

[0055] Table 4 Relationship Matrix q1 1 0 0 0 0 0 0 0 0 0 q2 0 1 0 0 0 0 0 0 0 0 q3 0 0 1 0 0 0 0 0 0 0 q4 0 0 0 1 0 0 0 0 0 0 q5 0 0 0 1 0 0 0 0 0 0 q6 0 0 0 1 0 0 0 0 0 0 q7 0 0 0 0 1 0 0 0 0 0 q8 0 0 0 0 0 1 0 0 0 0 q9 0 0 0 0 0 1 0 0 0 0 q10 0 0 0 0 0 0 1 0 0 0 q11 0 0 0 0 0 0 1 0 0 0 q12 0 0 0 0 0 0 0 1 0 0 q13 0 0 0 0 0 0 0 0 1 0 q14 0 0 0 0 0 0 0 0 1 0 q15 0 0 0 0 0 0 0 0 0 1 q16 0 0 0 0 0 0 0 0 0 1 S5: Process the final question set through the large model to generate the final question-answer pairs.

[0056] Specifically, the steps include: The final answer is generated by passing any one of the final questions in the final question set through a large model, and the final question and its corresponding final answer are used as the final question-answer pair. Alternatively, any one of the final questions in the final question set can be processed by several large models to generate several candidate answers. Based on the consistency of evidence and the consistency between models, the final answer can be selected from the candidate answers, and the final question and the corresponding final answer can be used as the final question-answer pair.

[0057] Furthermore, the step of selecting the final answer from several candidate answers based on evidence consistency and inter-model consistency includes: Based on the directed graph, an evidence consistency verification function is constructed, with the expression: ; ; ; in, Indicates the consistency score of evidence. Indicates the first i The final question, Indicates the first i The first final question corresponds to the... t 10 candidate answers Indicates candidate answers Evidence path, This represents a directed graph. Indicates an indicator function, Indicates and, This represents the path compliance determination function. Indicates that by node u Pointing to node v , Represents any directed edge. Indicates that by node u With nodes v The directed edges formed Represents a directed edge set. This represents the node consistency determination function. This indicates a preset consistency threshold; the evidence consistency verification function means that a candidate answer passes the evidence consistency verification only when both node consistency and path compliance are satisfied.

[0058] All nodes that successfully match the corresponding final question are selected to form a question-related node set, and candidate answers are obtained based on the evidence path. The referenced nodes form a reference node set; the node consistency ratio is calculated based on the problem-related node set and the reference node set, using the following formula: ; in, Indicates candidate answers The node consistency ratio, This indicates that the problem involves a set of nodes. The number of nodes in the middle, Represents the set of reference nodes The number of nodes in the middle, Represents a constant; When the node consistency ratio is greater than or equal to a preset threshold, candidate answers are determined. Through node consistency verification; For candidate answers that pass the node consistency check, a further evidence consistency check is performed. Based on the candidate answers that pass the evidence consistency check, an inter-model consistency score is calculated using the following formula: ; ; ; in, Indicates candidate answers The inter-model consistency score, This represents the first set of answers, consisting of candidate answers that pass the evidence consistency check. This indicates the number of candidate answers in the first answer set. This represents the total number of candidate answers. Indicates the first i The first final question corresponds to the... k 10 candidate answers Represents the set of candidate answers. This represents the semantic implication discriminant function. This represents semantic similarity, which can be calculated by measuring the cosine similarity between the semantic vectors of two candidate answers. This indicates a preset semantic implication threshold; A comprehensive score is calculated based on the evidence consistency score, node consistency ratio, and inter-model consistency score. The calculation formula is as follows: ; ; in, Indicates candidate answers Overall score Indicates the first weight. Indicates the second weight. Indicates the third weight. Indicates the fourth weight. Indicates the confidence score. Indicates the first i The first final question corresponds to the... t The original confidence scores of the candidate answers, Indicates the first i The first final question corresponds to the... kThe original confidence scores of the candidate answers, This represents a constant; the higher the original confidence score of the candidate answer, the greater the corresponding confidence score. The candidate answer with the highest overall score is selected as the final answer.

[0059] It is worth noting that in this embodiment, all indicator functions have a value of 1 when all conditions are met, and a value of 0 otherwise.

[0060] In this embodiment, the final question-answer pair is also stored in a knowledge base and can be reused: The final question, the corresponding final answer, the semantic vector of the final question, and the semantic vector of the final answer are stored as a quadruple in the knowledge base; When storing data, the semantic cosine similarity between the semantic vector of the final question in the newly added quadruple and the semantic vector of each of the previously stored final questions is calculated. When the semantic cosine similarity is greater than or equal to the second semantic threshold, the final answer corresponding to the previously stored final question is reused or used as a hint context to assist in the generation.

[0061] The following is an excerpt of the final question-and-answer example: 1) Question: What is the next step after a student submits an application? Answer: The next step is for the college and the academic affairs office to approve it.

[0062] 2) Question: What is the next step after the college and the Academic Affairs Office approve the application? Answer: The next step is for the Office of International Exchange and Cooperation to review the application materials.

[0063] 3) Question: What is the next step after the Office of International Exchange and Cooperation reviews the application materials? Answer: The next step is language proficiency.

[0064] 4) Question: What is the next step after passing the language proficiency test? Answer: The next step is for the Office of International Exchange and Cooperation to organize an expert review.

[0065] 5) Question: What is the next step if one's language skills are inadequate? Answer: The next step is to learn the language.

[0066] 6) Question: What is the next step in learning a language? Answer: The next step is to go back to language proficiency for reassessment.

[0067] 7) Question: What is the next step after the Office of International Exchange and Cooperation organizes expert reviews? Answer: The next step is for students to sign study abroad agreements with the university, and for the college and students to develop course selection plans.

[0068] 8) Question: What is the next step after the student signs a study abroad agreement with the school and the college and student develop a course selection plan? Answer: The next step is for the college to provide full guidance and management, with the Office of International Exchange and Cooperation assisting in the management.

[0069] 9) Question: The college is responsible for the entire guidance and management process, and the Office of International Exchange and Cooperation is assisting with the management. What is the next step? Answer: The next step is for students to return to their home countries and submit a learning summary to the college.

[0070] 10) Question: What is the next step after a student submits a learning summary to the college upon returning to their home country? Answer: The next step is for the Academic Affairs Office to process the credit transfer and recognition.

[0071] 11) Question: What is the step before the Academic Affairs Office processes credit transfer and recognition? Answer: The step before the student returns to their home country and submits a learning summary to the college.

[0072] Furthermore, to ensure the final problem set comprises 16 problems, this embodiment includes supplementary problems (consistent with the node set / directed edge set), such as: Supplementary Question 1: What is the step before language proficiency? Answer: The step before language proficiency is the review of materials by the Office of International Exchange and Cooperation.

[0073] Supplementary Question 2: What is the step before the Office of International Exchange and Cooperation organizes expert reviews? Answer: The step before that is passing the language proficiency test.

[0074] Supplementary Question 3: What is the step before the student signs the study abroad agreement with the school and the college and the student develop the course selection plan? Answer: The step before that is the Office of International Exchange and Cooperation organizing expert review.

[0075] Supplementary Question 4: What is the step before students submit their learning summary to the college upon returning home? Answer: The college is responsible for providing full guidance and management, with the Office of International Exchange and Cooperation assisting in the management.

[0076] Supplementary Question 5: What is the next step in the Academic Affairs Office's processing of credit transfer and recognition? Answer: This is the final step; there are no subsequent steps.

[0077] The multi-model-based audit flowchart question-and-answer generation method provided in this embodiment has the following beneficial effects: This method parses the image data of the audit flowchart uploaded by the user to obtain the node set and directed edge set in the audit flowchart; calculates the complexity score of the audit flowchart based on the node set and directed edge set, and determines the number of large models based on the complexity score; the large models are used to generate a candidate question set based on the audit flowchart; when the number of large models is 1, the candidate question set generated by the corresponding large model is used as the initial question set; when the number of large models is two or more, semantic deduplication is performed on the candidate question sets generated by all large models to obtain the initial question set; a relationship matrix between questions and nodes is constructed based on the initial question set and the node set; the question coverage difference and node coverage difference are calculated based on the relationship matrix, and the initial question set is completed based on the question coverage difference and node coverage difference to obtain the final question set; the final question set is passed through one or more large models. When it passes through one large model, the final answer is directly generated; when it passes through multiple large models, the final answer is selected from several candidate answers based on evidence consistency and inter-model consistency, and the final question and the corresponding final answer are used as the final question-answer pair. This method avoids repeated parsing of the audit flowchart after obtaining the node set and directed edge set, thus improving processing consistency and reducing computational overhead. Based on the node set and directed edge set, the complexity score of the audit flowchart is calculated, and the number of large models is determined according to the complexity score, balancing computational efficiency while improving the comprehensiveness of question generation. Semantic deduplication is performed on the candidate question sets generated by several large models, and the initial question set is completed based on the differences in question coverage and node coverage, improving the diversity and coverage of the question set, thereby enhancing the accuracy and credibility of the final question-answer pairs.

[0078] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0079] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this patent application should be determined by the appended claims.

Claims

1. A method for generating audit flowcharts and questions based on multiple models, characterized in that, include: S1: Parse the image data of the audit flowchart uploaded by the user to obtain the node set and directed edge set in the audit flowchart; The parsing of the image data of the audit flowchart uploaded by the user includes: The audit flowchart is formalized as a directed graph, which includes a node set, a directed edge set, a node type set, and an edge type set. The node types in the node type set include judgment nodes and processing nodes. The edge types in the edge type set include normal directed edges, abnormal edges, and backtracking edges. The normal directed edge is the edge that the judgment node is deemed qualified and points to the processing node, or the directed edge between processing nodes pointing to each other in node order. The abnormal edge is a directed edge that is judged as unqualified by the judgment node and points to the processing node; The back edge is a directed edge between processing nodes that points in reverse order of the nodes; S2: Calculate the complexity score of the audit flowchart based on the node set and the directed edge set, including: An adjacency matrix is ​​constructed based on the node set and the directed edge set, and the in-degree and out-degree of each node are calculated based on the adjacency matrix. The number of nodes and the number of directed edges are determined based on the node set and the directed edge set; The density of the directed graph is calculated based on the number of nodes and the number of directed edges; Calculate the first proportion of the corresponding node type based on the number of occurrences of any node type in the node set, and calculate the node type entropy based on the first proportion of all node types in the node type set. The branch load is calculated based on the out-degree of all nodes, and the merge load is calculated based on the in-degree of all nodes. The cyclic complexity is calculated based on the number of nodes, the number of directed edges, and the number of connected components. Use the maximum or average depth of nodes in the node set as the nesting depth indicator. Identify abnormal edges and back edges, and use the ratio of the number of abnormal edges and back edges to the number of directed edges as the ratio of abnormal edges; The rework loop strength is calculated based on the number of back edges and loops. Identify the responsible entities corresponding to the nodes, and count the number of directed edges where two nodes belong to the same directed edge but have different responsible entities as the number of cross-entity interaction edges; the quotient of the number of cross-entity interaction edges and the number of directed edges is the cross-entity interaction rate; The second proportion of the corresponding responsible entity is calculated based on the number of occurrences of any responsible entity in the node set, and the subject diversity entropy is calculated based on the second proportion of all responsible entities in the responsible entity set. Identify control point nodes and evidence nodes in the processing nodes, and use the third proportion of control point nodes in the node set as the control point density, and the fourth proportion of evidence nodes in the node set as the evidence node density. The evidence load is calculated based on the number of evidence items carried by all evidence nodes; The complexity score is obtained by weighted summing of the normalized number of nodes, number of directed edges, directed graph density, node type entropy, branch load, merge load, cyclomatic complexity, nesting depth index, abnormal edge ratio, rework loop strength, cross-subject interaction rate, subject diversity entropy, control point density, evidence node density, and evidence load. The number of large models is determined based on the complexity score, including: The first complexity threshold and the second complexity threshold are determined based on the distribution of complexity scores in the historical audit flowcharts, and the first complexity threshold is less than the second complexity threshold. When the complexity score is less than or equal to the first complexity threshold, the number of large models is a first preset value; When the complexity score is greater than the first complexity threshold and less than or equal to the second complexity threshold, the number of large models is a second preset value; When the complexity score is greater than the second complexity threshold, the number of large models is a third preset value; the large models are used to generate a set of candidate questions based on the audit flowchart; S3: When the number of large models is 1, the candidate question set generated by the corresponding large model is used as the initial question set. When the number of large models is two or more, semantic deduplication is performed on the candidate question sets generated by all large models to obtain the initial question set. S4: Construct a relationship matrix between problems and nodes based on the initial problem set and the node set, including: Each initial question in the initial question set is hard-matched or soft-matched with the name dictionary of any node. If the match is successful, the relationship value between the corresponding initial question and the node is set to 1; otherwise, it is set to 0. The hard matching is to determine whether the name in the name dictionary of the node is contained in the initial question. The soft matching is to determine whether the maximum cosine similarity between the semantic vector of the initial question and the semantic vector of the name in the name dictionary of the node is greater than or equal to the semantic threshold. The relationship matrix is ​​constructed by sequentially traversing each initial problem in the initial problem set and each node in the node set, based on the relationship value between any initial problem and any node. The problem coverage difference and node coverage difference are calculated based on the aforementioned relationship matrix, including: Sum the relation values ​​corresponding to all nodes that successfully match any initial problem to obtain the number of covered nodes for the corresponding initial problem; Sum the relation values ​​corresponding to all initial problems that successfully match any node to obtain the number of problems involved in the corresponding node; Calculate the first mean of the number of nodes covered by all initial problems, and calculate the second mean of the number of nodes involved in problems. Calculate the first variance between the number of covered nodes for each initial problem and the first mean; the first variance is the problem coverage difference. Calculate the second variance between the number of issues involved in each node and the second mean. The second variance is the node coverage difference. The initial problem set is completed based on the problem coverage difference and the node coverage difference, including: The first coefficient of variation is calculated based on the problem coverage difference and the first mean; A second coefficient of variation is calculated based on the node coverage difference and the second mean; The percentage of nodes in the node set whose number of issues is greater than 0 is the fifth highest percentage, which is used as the node coverage rate. Nodes whose number of issues is less than or equal to a preset node coverage threshold will be considered under-covered nodes. Based on the first coefficient of variation, the second coefficient of variation, and the node coverage rate, the completion trigger command value is determined using the following formula: ; in, This indicates that the trigger command value has been completed. Indicates an indicator function, This represents the first coefficient of variation. This represents the second coefficient of variation. Indicates node coverage. Indicates the first threshold. This represents the second threshold. This represents the third threshold. Indicates or; For each undercovered node, a supplementary problem is generated and the relation matrix is ​​updated until the completion trigger instruction value is not 1 or the maximum number of iterations is reached, thus obtaining the final problem set; S5: Process the final question set through the large model to generate the final question-answer pairs.

2. The method according to claim 1, characterized in that, The semantic deduplication of the candidate question sets generated by all large models includes: Encode each candidate question in the set of all candidate questions into a corresponding semantic vector, and calculate the cosine similarity between any two semantic vectors; When the cosine similarity is greater than or equal to a preset similarity threshold, the candidate question corresponding to either of the two semantic vectors is deleted until all candidate questions have been traversed to obtain the initial question set.

3. The method according to claim 1, characterized in that, The process of passing the final question set through a large model to generate the final question-answer pairs includes: The final answer is generated by passing any one of the final questions in the final question set through a large model, and the final question and its corresponding final answer are used as the final question-answer pair. Alternatively, any one of the final questions in the final question set can be processed by several large models to generate several candidate answers. Based on the consistency of evidence and the consistency between models, the final answer can be selected from the candidate answers, and the final question and the corresponding final answer can be used as the final question-answer pair.

4. The method according to claim 3, characterized in that, The process of selecting the final answer from several candidate answers based on evidence consistency and inter-model consistency includes: Based on the directed graph, an evidence consistency verification function is constructed, with the expression: ; ; ; in, Indicates the consistency score of evidence. Indicates the first i The final question, Indicates the first i The first final question corresponds to the... t 10 candidate answers Indicates candidate answers Evidence path, This represents a directed graph. Indicates an indicator function, Indicates and, This represents the path compliance determination function. Indicates that by node u Pointing to node v , Represents any directed edge. Indicates that by node u With nodes v The directed edges formed Represents a directed edge set. This represents the node consistency determination function. Indicates the preset consistency threshold; All nodes that successfully match the corresponding final question are selected to form a question-related node set, and candidate answers are obtained based on the evidence path. The referenced nodes form a reference node set; the node consistency ratio is calculated based on the problem-related node set and the reference node set, using the following formula: ; in, Indicates candidate answers The node consistency ratio, This indicates that the problem involves a set of nodes. The number of nodes in the middle, Represents the set of reference nodes The number of nodes in the middle, Represents a constant; When the node consistency ratio is greater than or equal to a preset threshold, candidate answers are determined. Through node consistency verification; For candidate answers that pass the node consistency check, a further evidence consistency check is performed. Based on the candidate answers that pass the evidence consistency check, an inter-model consistency score is calculated using the following formula: ; ; ; in, Indicates candidate answers The inter-model consistency score, This represents the first set of answers, consisting of candidate answers that pass the evidence consistency check. This indicates the number of candidate answers in the first answer set. This represents the total number of candidate answers. Indicates the first i The first final question corresponds to the... k 10 candidate answers Represents the set of candidate answers. This represents the semantic implication discriminant function. Indicates semantic similarity. This indicates a preset semantic implication threshold; A comprehensive score is calculated based on the evidence consistency score, node consistency ratio, and inter-model consistency score. The calculation formula is as follows: ; ; in, Indicates candidate answers Overall score Indicates the first weight. Indicates the second weight. Indicates the third weight. Indicates the fourth weight. Indicates the confidence score. Indicates the first i The first final question corresponds to the... t The original confidence scores of the candidate answers, Indicates the first i The first final question corresponds to the... k The original confidence scores of the candidate answers; The candidate answer with the highest overall score is selected as the final answer.

Citation Information

Patent Citations

  • Intelligent question answering method and system based on multi-model collaboration

    CN121071079A

  • Multi-model collaborative evaluation method based on intelligent agent and related equipment

    CN121706941A