A contract auditing method and system based on multi-agent cooperation

By using a multi-agent collaborative architecture for contract review, the problems of low efficiency, incomplete coverage, fragmented results, and insufficient information protection in existing technologies are solved, achieving efficient, accurate, and automated contract review and meeting the multi-dimensional needs of enterprises.

CN122114583APending Publication Date: 2026-05-29SHANGHAI (BEIJING) ARTIFICIAL INTELLIGENCE TECHNOLOGY RESEARCH INSTITUTE CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHANGHAI (BEIJING) ARTIFICIAL INTELLIGENCE TECHNOLOGY RESEARCH INSTITUTE CO LTD
Filing Date
2026-02-06
Publication Date
2026-05-29

Smart Images

  • Figure CN122114583A_ABST
    Figure CN122114583A_ABST
Patent Text Reader

Abstract

The application provides a contract auditing method and system based on multi-agent cooperation, comprising the following steps: receiving a contract document uploaded by a user, performing analysis, text cleaning, encoding conversion and content structuring preprocessing on the contract document to obtain a preprocessed contract document; sending the preprocessed contract document to a legal agent, a commercial agent and a format agent respectively, and performing auditing operations in parallel; receiving the auditing results of the agents, integrating the auditing results of the agents into an auditing report through a data integration model and a conflict resolution mechanism; highlighting key information and risk points in the auditing report, and outputting the highlighted auditing report in a preset format; the application adopts a multi-agent cooperation mechanism, can realize multi-dimensional comprehensive auditing of contracts, improve auditing efficiency and accuracy, reduce manual risk, supports custom configuration, adapts to different industry scene requirements, and has high practicability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of natural language processing technology, specifically to a contract review method and system based on multi-agent collaboration. Background Technology

[0002] Currently, contracts serve as the core carrier of commercial activities and legal relationships, and the quality of their review directly affects transaction security, protection of legitimate rights and interests, and prevention of commercial risks. With the rapid development of the market economy, the number of contracts has surged and their types have become increasingly complex, covering multiple dimensions such as legal compliance, business logic, and format specifications, thus placing higher demands on review efficiency and accuracy.

[0003] In existing technologies, contract review mainly relies on manual labor, which has significant limitations: on the one hand, manual review is inefficient and cannot meet the needs of large-scale batch processing of contracts. Moreover, it is affected by the professional level and energy level of the reviewers, which can easily lead to problems such as omission of legal clauses, misjudgment of commercial risks, and neglect of format specifications; on the other hand, contract review involves professional knowledge in multiple fields such as law, commerce, and format, and a single reviewer cannot fully cover all professional dimensions, resulting in a one-sided review.

[0004] To address the drawbacks of manual review, some intelligent review solutions have emerged, but they still have significant shortcomings: First, existing intelligent methods often focus on single-dimensional review (such as only legal clause verification or only format checking), lacking a multi-dimensional collaborative review mechanism, and failing to achieve comprehensive coverage of legal compliance, commercial rationality, and format standardization; second, the review results from different dimensions are independent of each other, lacking effective data integration and conflict resolution mechanisms, resulting in fragmented review results that require users to manually integrate and analyze, increasing usage costs; third, there is insufficient protection of sensitive information, and personal identity information and trade secrets in contracts are easily leaked; fourth, the output format of review results is monotonous, and key risk points and core information are not prominently displayed, making it difficult for users to quickly locate key issues.

[0005] In summary, existing technologies lack a contract review solution that is multi-dimensional, collaborative, efficient in data integration, accurate in risk identification, and easy to use. This makes it difficult to balance the comprehensiveness, accuracy, and efficiency of contract review, and fails to meet the needs of enterprises for large-scale and refined contract management. Summary of the Invention

[0006] To address the aforementioned technical problems, this invention proposes a contract review method based on multi-agent collaboration, comprising: The system receives contract documents uploaded by users, parses, cleans, converts, and preprocesses the contract documents to obtain preprocessed contract documents. The preprocessed contract documents are sent to a legal agent, a business agent, and a format agent respectively, and the review operations are performed in parallel. The legal agent, based on a pre-set legal knowledge base and case reasoning technology, is used to review the legal clauses in the contract documents and identify legal risks. The business agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review the business clauses in the contract documents and assess their commercial reasonableness. The format agent, based on pre-set format specifications and format checking algorithms, is used to review the format compliance of the contract documents. Receive the audit results from the legal agent, commercial agent, and format agent, and integrate the audit results of each agent into an audit report through a preset data integration model and conflict resolution mechanism; The key information and risk points in the audit report are highlighted, and the highlighted audit report is output in a preset format.

[0007] Optionally, the step of parsing, cleaning, encoding conversion, and content structuring preprocessing of the contract document to obtain a preprocessed contract document includes: The contract document is formatted and its constituent elements are extracted and parsed; the constituent elements include one or more of the following: text content, tables, and image elements; The parsed text content is cleaned to obtain the cleaned text content. The cleaned text content is converted to UTF-8 standard encoding format to obtain the format-converted contract document; Natural language processing technology is used to identify the chapter structure, clause hierarchy, and key element location of the contract document after format conversion, and to generate structured document content; The sensitive information identification model is used to identify sensitive information in the structured document content, and the identified sensitive information is encrypted or decrypted. By integrating the document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing, a preprocessed contract document is obtained.

[0008] Optionally, the legal agent, based on a pre-set legal knowledge base and case reasoning technology, is used to review legal clauses in contract documents and identify legal risks, including: Based on a pre-set legal knowledge base, the legal agent uses natural language processing algorithms to parse the legal clauses in the contract document and extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The key legal elements are semantically matched with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risks. Based on the clauses that do not comply with legal regulations and the potential legal risks, a case reasoning model is invoked to perform secondary verification of the legal clauses in the contract document, generating a legal risk assessment result.

[0009] Optionally, the business agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review the business terms in contract documents and assess their commercial reasonableness, including: The business agent uses a pre-built clause evaluation model based on a business rule base to obtain a reasonableness score for the business clauses in the contract document; Obtain external market data based on the preset external market interface; The commercial terms in the contract document are compared and analyzed with the external market data to obtain the clauses in the commercial terms that deviate from the external market data; Based on the clauses in the business terms that deviate from the external market data, output a business risk assessment report.

[0010] The clause evaluation model is based on a machine learning algorithm. It is trained by taking historical valid contract data and commercial dispute case data as inputs and taking the reasonableness quantification scores corresponding to the historical valid contract data and commercial dispute case data as outputs. The external market data includes one or more of the following: industry price indices, competitor quotes, and supply chain dynamics data; The business risk assessment report includes one or more of the following: price volatility risk, supply stability risk, and recommendations for protecting business interests.

[0011] Optionally, the format agent, based on preset format specifications and format checking algorithms, is used to review the format compliance of contract documents, including: The Format Agent uses a format verification algorithm to check each item of the contract document based on a preset format specification, and obtains contract documents containing format issues. Based on the contract document containing formatting issues, generate an error message; After user authorization, based on the error message, correct the formatting issue according to the preset specifications and generate a formatting adjustment log; The format specifications include one or more of the following: font type specifications, font size specifications, line spacing settings specifications, page margin parameter specifications, heading style specifications, and numbering specifications; The error message includes: the location of the problem and suggestions for fixing the problem; Optionally, the process of integrating the audit results of each Agent into an audit report through a preset data integration model and conflict resolution mechanism includes: By using a pre-defined data integration model, the review results of the legal agent, business agent, and format agent are mapped to standardized review results; When there are conflicts in the standardized audit results of different agents, a conflict resolution method is determined based on preset priority rules. An audit report is generated when there are no conflicts in the standardized audit results of each Agent; The audit report includes one or more of the following: audit overview, issue details, and improvement recommendations.

[0012] Optionally, the key information may include one or more of the following: contract subject information, core transaction terms, rights and obligations, breach of contract clauses, and supplementary agreements; The risk points include one or more of the following: legal risk points, commercial risk points, and format and standardization risk points; The legal risks mentioned include one or more of the following: risks of illegal clauses, risks of unclear rights and obligations, risks of invalid dispute resolution, and risks of compliance. The business risk points include one or more of the following: price reasonableness risk, performance risk, interest protection risk, and market linkage risk; The format specification risk points include one or more of the following: format non-standard risk, form problem risk, and document validity risk; The format includes one or more of the following: PDF, Word, HTML, and Excel.

[0013] Based on the same inventive concept, this invention also provides a contract review system based on multi-agent collaboration, comprising: The document preprocessing module is used to receive contract documents uploaded by users, and to parse, clean, encode, and preprocess the contract documents to obtain preprocessed contract documents. The collaborative review module sends the preprocessed contract documents to a legal agent, a business agent, and a format agent, respectively, and performs review operations in parallel. The legal agent, based on a pre-set legal knowledge base and case reasoning technology, reviews the legal clauses in the contract documents and identifies legal risks. The business agent, based on a business rule base and clause evaluation model, combined with external market data, reviews the business clauses in the contract documents and assesses their commercial reasonableness. The format agent, based on pre-set format specifications and format checking algorithms, reviews the format compliance of the contract documents. The conflict resolution module is used to receive the review results from the legal agent, commercial agent and format agent, and integrate the review results of each agent into a review report through a preset data integration model and conflict resolution mechanism. The audit output module is used to highlight key information and risk points in the audit report and output the highlighted audit report in a preset format.

[0014] Optionally, the document preprocessing module includes: The format parsing submodule is used to parse the format of the contract document, extract the constituent elements in the contract document and parse them; the constituent elements include one or more of the following: text content, table and image elements; The text cleaning submodule is used to clean the parsed text content to obtain the cleaned text content. The format conversion submodule is used to convert the cleaned text content into the UTF-8 standard encoding format to obtain the format-converted contract document. The structure generation submodule is used to identify the chapter structure, clause hierarchy and key element location of the contract document after format conversion using natural language processing technology, and generate structured document content. The sensitive information identification submodule is used to identify sensitive information in the structured document content using a sensitive information identification model, and to encrypt or decrypt the identified sensitive information. The data integration submodule is used to integrate document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing to obtain preprocessed contract documents.

[0015] Optionally, the system further includes: a legal review module, specifically including: The clause parsing submodule is used by a legal agent to parse the legal clauses in the contract document based on a preset legal knowledge base and using natural language processing algorithms to extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The semantic matching submodule is used to semantically match the key legal elements with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risk points. The secondary verification submodule is used to call the case reasoning model to perform secondary verification on the legal clauses in the contract document based on the content of the clauses that do not comply with legal regulations and potential legal risk points, and generate legal risk assessment results.

[0016] Optionally, the collaborative review module includes: a business review sub-module, including: The clause evaluation unit is used by a business agent to obtain a reasonableness score of the business clauses in the contract document based on a business rule base and using a pre-built clause evaluation model. The external data acquisition unit is used to acquire external market data according to a preset external market interface; The comparison and analysis unit is used to compare and analyze the commercial terms in the contract document with the external market data to obtain the content of the commercial terms that deviate from the external market data; The risk assessment unit is used to output a business risk assessment report based on the clauses in the business terms that deviate from the external market data.

[0017] The clause evaluation model is based on a machine learning algorithm. It is trained by taking historical valid contract data and commercial dispute case data as inputs and taking the reasonableness quantification scores corresponding to the historical valid contract data and commercial dispute case data as outputs. The external market data includes one or more of the following: industry price indices, competitor quotes, and supply chain dynamics data; The business risk assessment report includes one or more of the following: price volatility risk, supply stability risk, and recommendations for protecting business interests.

[0018] Optionally, the collaborative review module includes: a format checking submodule, including: The format verification unit is used to check the contract document item by item using a format verification algorithm based on a preset format specification and a format agent, and to obtain the contract document containing format problems. An error message unit is used to generate an error message based on the contract document containing formatting issues; The format correction unit is used to correct format problems according to preset specifications based on the error message after user authorization, and generate a format adjustment log; The format specifications include one or more of the following: font type specifications, font size specifications, line spacing settings specifications, page margin parameter specifications, heading style specifications, and numbering specifications; The error message includes: the location of the problem and suggestions for fixing the problem; Optionally, the conflict resolution module includes: The result mapping submodule is used to map the review results of the legal agent, business agent, and format agent into standardized review results through a preset data integration model; The solution generation submodule is used to determine conflict resolution based on preset priority rules when there are conflicts in the standardized audit results of various agents. The report output submodule is used to generate an audit report when there are no conflicts in the standardized audit results of each Agent; The audit report includes one or more of the following: audit overview, issue details, and improvement recommendations.

[0019] Optionally, the key information may include one or more of the following: contract subject information, core transaction terms, rights and obligations, breach of contract clauses, and supplementary agreements; The risk points include one or more of the following: legal risk points, commercial risk points, and format and standardization risk points; The legal risks mentioned include one or more of the following: risks of illegal clauses, risks of unclear rights and obligations, risks of invalid dispute resolution, and risks of compliance. The business risk points include one or more of the following: price reasonableness risk, performance risk, interest protection risk, and market linkage risk; The format specification risk points include one or more of the following: format non-standard risk, form problem risk, and document validity risk; The format includes one or more of the following: PDF, Word, HTML, and Excel.

[0020] In another aspect, the present invention also provides an electronic device, comprising: at least one processor and a memory; the memory and the processor are connected via a bus; The memory is used to store one or more programs; When the one or more programs are executed by the at least one processor, a contract auditing method based on multi-agent collaboration as described above is implemented.

[0021] In another aspect, the present invention also provides a computer device readable storage medium having an executable program stored thereon, wherein when the executable program is executed, it implements the contract review method based on multi-agent collaboration as described above.

[0022] Compared with the prior art, the beneficial effects of the present invention are as follows: This invention provides a contract review method and system based on multi-agent collaboration, comprising: receiving a contract document uploaded by a user; parsing, cleaning, encoding conversion, and content structuring preprocessing of the contract document to obtain a preprocessed contract document; sending the preprocessed contract document to a legal agent, a business agent, and a format agent respectively, and performing review operations in parallel; the legal agent, based on a preset legal knowledge base and case reasoning technology, is used to review the legal clauses in the contract document and identify legal risks; the business agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review the business clauses in the contract document and evaluate their commercial reasonableness; the format agent, based on preset format specifications and format checking algorithms, is used to review the format compliance of the contract document; receiving the review results from the legal agent, business agent, and format agent, and then... A pre-defined data integration model and conflict resolution mechanism integrate the audit results of each agent into an audit report. Key information and risk points in the audit report are highlighted, and the highlighted audit report is output in a pre-defined format. This invention, by employing a parallel audit architecture of legal agents, commercial agents, and format agents, avoids the time consumption of single-dimensional serial processing, significantly shortens the multi-dimensional audit cycle, and efficiently handles the needs of large-scale contract batch audits, improving efficiency several times compared to manual audits. Simultaneously, through automated document preprocessing and automatic format adjustment, manual intervention is reduced, further enhancing the automation of the audit process. By constructing a professional knowledge base combined with natural language processing algorithms and case reasoning models, accurate extraction of key clauses and risk identification can be achieved, reducing subjective errors and omissions in manual audits. Furthermore, by introducing a data integration model and conflict resolution mechanism, cross-validation and conflict reconciliation of multi-agent audit results can be performed, ensuring the consistency and reliability of audit conclusions. Attached Figure Description

[0023] Figure 1 A flowchart illustrating a contract review method based on multi-agent collaboration provided by the present invention; Figure 2 A schematic diagram illustrating the framework of a contract review method based on multi-agent collaboration, provided for a specific embodiment of the present invention; Figure 3 A schematic diagram illustrating the structural composition of a contract review system based on multi-agent collaboration provided by the present invention; Figure 4 This is a schematic diagram of the structure of an electronic device provided by the present invention. Detailed Implementation

[0024] This invention proposes a contract review method, system, device, and medium based on multi-agent collaboration. The specific embodiments of this invention will be further described in detail below with reference to the accompanying drawings.

[0025] Example 1: This invention provides a contract review method based on multi-agent collaboration, the flowchart of which is shown below. Figure 1 As shown, it includes: Step 1: Receive the contract document uploaded by the user, parse the contract document, clean the text, convert the encoding and perform content structuring preprocessing to obtain the preprocessed contract document; Step 2: The preprocessed contract documents are sent to the Legal Agent, Business Agent, and Format Agent respectively, and the review operations are performed in parallel. The Legal Agent, based on a preset legal knowledge base and case reasoning technology, is used to review the legal clauses in the contract documents and identify legal risks. The Business Agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review the business clauses in the contract documents and evaluate their commercial reasonableness. The Format Agent, based on preset format specifications and format checking algorithms, is used to review the format compliance of the contract documents. Step 3: Receive the audit results from the legal agent, business agent, and format agent, and integrate the audit results of each agent into an audit report through a preset data integration model and conflict resolution mechanism; Step 4: Highlight the key information and risk points in the audit report, and output the highlighted audit report in a preset format.

[0026] In one implementation, the process of parsing, cleaning, encoding conversion, and content structuring preprocessing of the contract document in step 1 above to obtain the preprocessed contract document may include: The contract document is formatted and its constituent elements are extracted and parsed; the constituent elements include one or more of the following: text content, tables, and image elements; The parsed text content is cleaned to obtain the cleaned text content. The cleaned text content is converted to UTF-8 standard encoding format to obtain the format-converted contract document; Natural language processing technology is used to identify the chapter structure, clause hierarchy, and key element location of the contract document after format conversion, and to generate structured document content; The sensitive information identification model is used to identify sensitive information in the structured document content, and the identified sensitive information is encrypted or decrypted. By integrating the document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing, a preprocessed contract document is obtained.

[0027] In one implementation, step 2 above, where the legal agent, based on a pre-set legal knowledge base and case reasoning technology, reviews legal clauses in contract documents and identifies legal risks, may include: Based on a pre-set legal knowledge base, the legal agent uses natural language processing algorithms to parse the legal clauses in the contract document and extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The key legal elements are semantically matched with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risks. Based on the clauses that do not comply with legal regulations and the potential legal risks, the case reasoning model is invoked to perform secondary verification of the legal clauses in the contract document and generate a legal risk assessment result. In this implementation, the legal knowledge base (organized and stored using semantic networks and ontology technologies for rapid retrieval and reasoning) can cover various laws, regulations, judicial interpretations, contract codes, etc. Natural language processing algorithms are used to perform in-depth analysis of contract clauses, extracting key elements (such as parties, rights and obligations, liability for breach of contract, etc.) and comparing and matching them with relevant clauses in the legal knowledge base. Clauses that do not comply with legal provisions or pose legal risks are identified. Combined with past legal case data, case reasoning techniques are used to further verify and evaluate the legality of the contract clauses. Based on the judgments of similar cases, the potential legal risks of the current contract clauses are predicted, and corresponding modification suggestions are provided. Therefore, the legal agent can monitor updates and changes in laws and regulations in real time, automatically updating the legal knowledge base to ensure that the review process is based on the latest legal requirements.

[0028] In one implementation, the process by which the aforementioned business agent, based on a business rule base and a clause evaluation model, and in conjunction with external market data, reviews the business terms in contract documents and assesses their commercial reasonableness may include: The business agent uses a pre-built clause evaluation model based on a business rule base to obtain a reasonableness score for the business clauses in the contract document; Obtain external market data based on the preset external market interface; The commercial terms in the contract document are compared and analyzed with the external market data to obtain the clauses in the commercial terms that deviate from the external market data; Based on the clauses in the business terms that deviate from the external market data, output a business risk assessment report.

[0029] The clause evaluation model is based on a machine learning algorithm. It is trained by taking historical valid contract data and commercial dispute case data as inputs and taking the reasonableness quantification scores corresponding to the historical valid contract data and commercial dispute case data as outputs. The external market data may include one or more of the following: industry price indices, competitor quotes, and supply chain dynamics data; The business risk assessment report may include one or more of the following: price volatility risk, supply stability risk, and recommendations for protecting business interests; In this implementation, a commercial agent reviews the commercial terms in the contract documents to assess the commercial rationale and feasibility of the contract. The specific process can be as follows: Establish a business rule base (a rule base containing various business rules and industry best practices, covering aspects such as pricing terms, delivery methods, payment terms, and confidentiality clauses). The rule base is classified and refined according to different industries and business types to adapt to diverse contract review needs. By using machine learning algorithms to build a commercial terms evaluation model, through learning and training on a large amount of historical contract data, the model can automatically evaluate the commercial reasonableness of contract terms and identify terms that may affect contract performance or lead to commercial disputes. We connect with external market data sources (such as industry reports, price indices, competitor information, etc.) to obtain real-time market dynamics data. During the review process, we compare and analyze contract terms with market data to determine whether the terms conform to market conditions and industry practices. Based on the evaluation results of the terms and comparison with market data, we predict the potential business risks of the contract (such as price fluctuation risk, supply risk, credit risk, etc.) and provide users with a detailed business risk assessment report and optimization suggestions.

[0030] In one implementation, the aforementioned Format Agent, based on preset format specifications and format checking algorithms, is used to review the format compliance of contract documents. This process may include: The Format Agent uses a format verification algorithm to check each item of the contract document based on a preset format specification, and obtains contract documents containing format issues. Based on the contract document containing formatting issues, generate an error message; After user authorization, based on the error message, correct the formatting issue according to the preset specifications and generate a formatting adjustment log; The format specifications include one or more of the following: font type specifications, font size specifications, line spacing settings specifications, page margin parameter specifications, heading style specifications, and numbering specifications; The error message includes: the location of the problem and suggestions for fixing the problem; Specifically, in this implementation, the Format Agent serves as the entry point for the contract review process. It receives and initially processes user-uploaded contract documents. During format parsing, it supports various document formats (such as PDF and Word), accurately extracting text content, tables, images, and other elements. Advanced document parsing algorithms ensure compatibility and accuracy across different document formats. Furthermore, it clearly defines the format specifications of contract documents, including font, font size, line spacing, margins, heading styles, numbering rules, table formats, and image embedding methods. These specifications are then converted into computer-readable rule templates for automatic checking and verification. The parsed document content also needs to be preprocessed, including text cleaning (removing extra spaces, line breaks, etc.), encoding conversion (unifying character encoding format), and content structuring (identifying the document's chapters and clauses structure), to provide clear and standardized data formats for subsequent review modules.

[0031] By using natural language processing technology and regular expression rules, sensitive information in documents, such as personal identification information and trade secrets, is identified and encrypted or declassified to ensure data security and privacy protection. When performing format checks, Format Agent uses a format checking algorithm to examine each item of the document. It can quickly and accurately identify areas that do not conform to format specifications and provide specific error messages and modification suggestions. It also has a certain degree of automated format adjustment capability. With user authorization, it can automatically correct the document's format to meet the prescribed format requirements. At the same time, it can provide a format adjustment log so that users can understand the details of the format modification.

[0032] In one implementation, step 3 above, which integrates the audit results of each Agent into an audit report using a pre-defined data integration model and conflict resolution mechanism, may include: By using a pre-defined data integration model, the review results of the legal agent, business agent, and format agent are mapped to standardized review results; When there are conflicts in the standardized audit results of different agents, a conflict resolution method is determined based on preset priority rules. An audit report is generated when there are no conflicts in the standardized audit results of each Agent; The audit report includes one or more of the following: audit overview, issue details, and improvement recommendations.

[0033] For example, the key information may include one or more of the following: contract subject information, core transaction terms, rights and obligations, liability for breach of contract clauses, and supplementary agreements; The risk points may include one or more of the following: legal risk points, commercial risk points, and format and specification risk points; The legal risks mentioned may include one or more of the following: risks of illegal clauses, risks of unclear rights and obligations, risks of invalid dispute resolution, and risks of compliance. The business risk points may include one or more of the following: price reasonableness risk, performance risk, interest protection risk, and market linkage risk; The format specification risk points may include one or more of the following: format non-standard risk, form problem risk, and document validity risk; The format may include one or more of the following: PDF, Word, HTML, and Excel; In this implementation method, the audit results of legal agents, commercial agents, and format agents are integrated to form a complete audit report. The specific process is as follows: A data integration model is constructed to merge and correlate audit result data from different agents. Through unified data format conversion and information mapping, it is ensured that the audit results can be accurately integrated to form a logically clear and complete audit report; During the integration process, if conflicts or inconsistencies are found between the audit results of different agents, the integration agent will activate the conflict resolution mechanism. Based on predefined priority rules, weighting algorithms, or expert system recommendations, the conflict will be automatically identified and handled to ensure the accuracy and reliability of the audit reports. During the report generation phase, a contract review report is generated according to the prescribed report template and format requirements. The report content includes basic contract information, an overview of the review process, specific results from each review module (such as legal risk points, unreasonable commercial clauses, formatting issues, etc.), a comprehensive evaluation conclusion, and improvement suggestions. Customized report generation is also supported to meet the needs of different users and scenarios.

[0034] In one implementation, the process of highlighting key information and risk points in the audit report in step 4 above may include: Based on natural language processing technology and machine learning algorithms, the text content in the audit report is analyzed to identify key information and important content, such as clauses with high risk levels and audit comments that require special attention. Furthermore, it allows for temporary modifications and adjustments to documents as needed, as well as editing, converting, merging, and splitting documents to ultimately generate different versions for comparison and reference. It also supports document version management and difference comparison, facilitating the tracking of contract modification history and review progress. Furthermore, users can customize highlight colors, styles, and priorities according to their needs and preferences. For example, high-risk clauses can be highlighted in red, while general issues can be highlighted in yellow. The audit report also employs an interactive highlighting method. Users can hover over the mouse, click, and other actions to view detailed information and explanations of the highlighted sections, improving their understanding and efficiency in using the audit report.

[0035] In this implementation, the process of outputting the highlighted audit report in a preset format may include: It supports exporting audit reports in multiple formats, such as PDF, Word, and HTML, making it convenient for users to view, print, and share. At the same time, it ensures that the output reports are formatted correctly, neatly laid out, and complete in content.

[0036] Visual charts are used to intuitively display key data and information in the audit results. For example, bar charts are used to show the distribution of contract risks, and pie charts are used to show the proportion of problems found in each audit module, helping users to understand the audit results more quickly. It also allows users to customize the output content, such as choosing the level of detail in the output report, the range of audit module results included, and whether to display highlighted content, to meet the specific needs of different users in different scenarios.

[0037] In summary, this invention addresses the technical problems of existing contract review technologies, such as incomplete multi-dimensional coverage, fragmented review results, inadequate protection of sensitive information, lack of prominent display of key information, and excessive and inefficient manual intervention. It proposes a multi-agent collaborative contract review method. Through document preprocessing (format parsing, cleaning, encoding conversion, structuring, and sensitive information desensitization), multi-agent parallel review (collaboration across legal / commercial / format dimensions), review result integration and conflict resolution, hierarchical highlighting of key information, and multi-format output, this collaborative technical solution can intuitively and visually output clear review reports, facilitating quick understanding and use of the review results by users. Furthermore, this invention's method boasts a high degree of automation and ease of operation during contract document review, requiring no deep professional knowledge from users, thus lowering the barrier to entry and improving user experience. Moreover, the agents and services in this invention are relatively independent, facilitating functional expansion and upgrades based on enterprise development and business changes; for example, industry-specific review agents can be added or the knowledge base and rule base can be updated to adapt to the needs of different business scenarios.

[0038] Example 2: The present invention provides a contract review method based on multi-agent collaboration, illustrated by a specific embodiment. A schematic diagram of the framework is shown below. Figure 2 As shown, the process may include: Users upload the contract documents that need to be reviewed to the system through the specified upload interface. The document processing agent parses and preprocesses the uploaded contract documents, extracts text content, identifies structure, etc., and sends the preprocessed documents to the McpService service through port 8080. The McpService service performs document highlighting and document processing operations to support subsequent review. The document processing agent simultaneously sends the pre-processed document to the legal agent via port 8081, to the business agent via port 8082, and to the format agent via port 8083; each agent reviews the contract according to its function and review logic. After receiving the documents, the legal agent uses a legal knowledge base and clause analysis algorithms to review each legal clause in the contract, identify clauses that do not comply with legal provisions or pose legal risks, and record the review results; the review results are then integrated by the integration agent. The business agent uses a business rule base and clause evaluation model to assess the reasonableness of the business clauses in the contract, analyzes whether the clauses are in line with market conditions and business logic, identifies clauses that may affect business interests, and sends the review results to the integration agent. The format agent checks the contract documents for formatting issues, such as inconsistent fonts or incorrect numbering, according to predefined formatting specifications and formatting checking algorithms, and then passes the format review results to the integration agent. The integration agent receives audit results from the legal agent, commercial agent, and formatting agent via port 8084. Using a data integration model and conflict resolution mechanism, it integrates these results into a complete audit report. Then, it invokes the highlighting agent via port 8084 to highlight key sections of the audit report, emphasizing important points and risk areas. The reviewed report, after being highlighted, is output through the output module and presented to the user in an intuitive and clear manner. This helps the user understand the review status of the contract and any existing problems, providing a basis for the modification and improvement of the contract.

[0039] This specific embodiment illustrates that the contract review method based on multi-agent collaboration provided by the present invention comprehensively reviews contracts from multiple dimensions such as legal, commercial, and format aspects. This ensures that contracts meet requirements in all aspects, which is beneficial to protecting the legitimate rights and commercial interests of enterprises, thereby reducing risks in the contract performance process, greatly shortening contract review time, and meeting the business needs of enterprises operating at high speed.

[0040] Example 3: Based on the same inventive concept, this invention also provides a contract review system based on multi-agent collaboration, the structural composition of which is shown in the schematic diagram below. Figure 3 As shown, it includes: The document preprocessing module is used to receive contract documents uploaded by users, and to parse, clean, encode, and preprocess the contract documents to obtain preprocessed contract documents. The collaborative review module sends the preprocessed contract documents to a legal agent, a business agent, and a format agent, respectively, and performs review operations in parallel. The legal agent, based on a pre-set legal knowledge base and case reasoning technology, reviews the legal clauses in the contract documents and identifies legal risks. The business agent, based on a business rule base and clause evaluation model, combined with external market data, reviews the business clauses in the contract documents and assesses their commercial reasonableness. The format agent, based on pre-set format specifications and format checking algorithms, reviews the format compliance of the contract documents. The conflict resolution module is used to receive the review results from the legal agent, commercial agent and format agent, and integrate the review results of each agent into a review report through a preset data integration model and conflict resolution mechanism. The audit output module is used to highlight key information and risk points in the audit report and output the highlighted audit report in a preset format.

[0041] In one implementation, the document preprocessing module may include: The format parsing submodule is used to parse the format of the contract document, extract the constituent elements in the contract document and parse them; the constituent elements include one or more of the following: text content, table and image elements; The text cleaning submodule is used to clean the parsed text content to obtain the cleaned text content. The format conversion submodule is used to convert the cleaned text content into the UTF-8 standard encoding format to obtain the format-converted contract document. The structure generation submodule is used to identify the chapter structure, clause hierarchy and key element location of the contract document after format conversion using natural language processing technology, and generate structured document content. The sensitive information identification submodule is used to identify sensitive information in the structured document content using a sensitive information identification model, and to encrypt or decrypt the identified sensitive information. The data integration submodule is used to integrate document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing to obtain preprocessed contract documents.

[0042] In one implementation, the system may further include a legal review module, which may specifically include: The clause parsing submodule is used by a legal agent to parse the legal clauses in the contract document based on a preset legal knowledge base and using natural language processing algorithms to extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The semantic matching submodule is used to semantically match the key legal elements with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risk points. The secondary verification submodule is used to call the case reasoning model to perform secondary verification on the legal clauses in the contract document based on the content of the clauses that do not comply with legal regulations and potential legal risk points, and generate legal risk assessment results.

[0043] In one implementation, the collaborative review module may include: a business review submodule, specifically including: The clause evaluation unit is used by a business agent to obtain a reasonableness score of the business clauses in the contract document based on a business rule base and using a pre-built clause evaluation model. The external data acquisition unit is used to acquire external market data according to a preset external market interface; The comparison and analysis unit is used to compare and analyze the commercial terms in the contract document with the external market data to obtain the content of the commercial terms that deviate from the external market data; The risk assessment unit is used to output a business risk assessment report based on the clauses in the business terms that deviate from the external market data.

[0044] The clause evaluation model is based on a machine learning algorithm. It is trained by taking historical valid contract data and commercial dispute case data as inputs and taking the reasonableness quantification scores corresponding to the historical valid contract data and commercial dispute case data as outputs. The external market data includes one or more of the following: industry price indices, competitor quotes, and supply chain dynamics data; The business risk assessment report includes one or more of the following: price volatility risk, supply stability risk, and recommendations for protecting business interests.

[0045] In one implementation, the collaborative review module may include: a format checking submodule, which may specifically include: The format verification unit is used to check the contract document item by item using a format verification algorithm based on a preset format specification and a format agent, and to obtain the contract document containing format problems. An error message unit is used to generate an error message based on the contract document containing formatting issues; The format correction unit is used to correct format problems according to preset specifications based on the error message after user authorization, and generate a format adjustment log; The format specifications include one or more of the following: font type specifications, font size specifications, line spacing settings specifications, page margin parameter specifications, heading style specifications, and numbering specifications; The error message includes: the location of the problem and suggestions for fixing the problem; In one implementation, the conflict resolution module may include: The result mapping submodule is used to map the review results of the legal agent, business agent, and format agent into standardized review results through a preset data integration model; The solution generation submodule is used to determine conflict resolution based on preset priority rules when there are conflicts in the standardized audit results of various agents. The report output submodule is used to generate an audit report when there are no conflicts in the standardized audit results of each Agent; The audit report includes one or more of the following: audit overview, issue details, and improvement recommendations.

[0046] For example, the key information may include one or more of the following: contract subject information, core transaction terms, rights and obligations, liability for breach of contract clauses, and supplementary agreements; The risk points may include one or more of the following: legal risk points, commercial risk points, and format and specification risk points; The legal risks mentioned may include one or more of the following: risks of illegal clauses, risks of unclear rights and obligations, risks of invalid dispute resolution, and risks of compliance. The business risk points may include one or more of the following: price reasonableness risk, performance risk, interest protection risk, and market linkage risk; The format specification risk points may include one or more of the following: format non-standard risk, form problem risk, and document validity risk; The format may include one or more of the following: PDF, Word, HTML, and Excel.

[0047] Example 4: like Figure 4 As shown, the present invention also provides an electronic device, which may be a computer device, a microcontroller device, a smart mobile device, etc. The electronic device in this embodiment may include a processor, a memory, a transceiver component, etc. The memory, processor, and transceiver component are connected via a bus; the memory can be used to store executable programs, and an exemplary executable program may include instructions; the processor is used to execute the instructions stored in the memory. The memory can also be used to store data, which can be accessed and / or modified when instructions are executed.

[0048] The processor may be a Central Processing Unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. It is the computing and control core of the terminal, and it is suitable for implementing one or more instructions. Specifically, it is suitable for loading and executing one or more instructions in the storage medium to implement the corresponding method flow or corresponding function, so as to implement the steps of a contract review method based on multi-agent collaboration in the above embodiments.

[0049] Example 5: Based on the same inventive concept, this invention also provides a readable storage medium, specifically an electronic device readable storage medium (Memory). This readable storage medium is a memory device within an electronic device used to store programs and data. It is understood that the storage medium here can include both built-in storage media within the electronic device and extended storage media supported by the electronic device. The storage medium provides storage space, which stores the terminal's operating system. Furthermore, this storage space also stores one or more instructions suitable for loading and execution by a processor. These instructions can be one or more executable programs (including program code). It should be noted that the storage medium here can be high-speed RAM or non-volatile memory, such as at least one disk storage device. Loading and executing one or more instructions stored in the storage medium by the processor can implement the steps of a multi-agent collaborative contract review method described in the above embodiments.

[0050] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0051] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0052] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1The function specified in one or more boxes.

[0053] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0054] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit its scope of protection. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that after reading the present invention, they can still make various changes, modifications or equivalent substitutions to the specific implementation methods of the application, but these changes, modifications or equivalent substitutions are all within the scope of protection of the claims pending approval.

Claims

1. A contract review method based on multi-agent collaboration, characterized in that, include: The system receives contract documents uploaded by users, parses, cleans, converts, and preprocesses the contract documents to obtain preprocessed contract documents. The preprocessed contract documents are sent to a legal agent, a business agent, and a format agent respectively, and the review operations are performed in parallel. The legal agent, based on a pre-set legal knowledge base and case reasoning technology, is used to review the legal clauses in the contract documents and identify legal risks. The business agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review the business clauses in the contract documents and assess their commercial reasonableness. The format agent, based on pre-set format specifications and format checking algorithms, is used to review the format compliance of the contract documents. Receive the audit results from the legal agent, commercial agent, and format agent, and integrate the audit results of each agent into an audit report through a preset data integration model and conflict resolution mechanism; The key information and risk points in the audit report are highlighted, and the highlighted audit report is output in a preset format.

2. The method as described in claim 1, characterized in that, The process of parsing, cleaning, encoding conversion, and structuring the contract document to obtain a preprocessed contract document includes: The contract document is formatted and its constituent elements are extracted and parsed; the constituent elements include one or more of the following: text content, tables, and image elements; The parsed text content is cleaned to obtain the cleaned text content. The cleaned text content is converted to UTF-8 standard encoding format to obtain the format-converted contract document; Natural language processing technology is used to identify the chapter structure, clause hierarchy, and key element location of the contract document after format conversion, and to generate structured document content; The sensitive information identification model is used to identify sensitive information in the structured document content, and the identified sensitive information is encrypted or decrypted. By integrating the document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing, a preprocessed contract document is obtained.

3. The method as described in claim 1, characterized in that, The legal agent, based on a pre-set legal knowledge base and case reasoning technology, is used to review legal clauses in contract documents and identify legal risks, including: Based on a pre-set legal knowledge base, the legal agent uses natural language processing algorithms to parse the legal clauses in the contract document and extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The key legal elements are semantically matched with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risks. Based on the clauses that do not comply with legal regulations and the potential legal risks, a case reasoning model is invoked to perform secondary verification of the legal clauses in the contract document, generating a legal risk assessment result.

4. The method as described in claim 1, characterized in that, The business agent, based on a business rule base and clause evaluation model, combined with external market data, is used to review business terms in contract documents and assess their commercial reasonableness, including: The business agent uses a pre-built clause evaluation model based on a business rule base to obtain a reasonableness score for the business clauses in the contract document; Obtain external market data based on the preset external market interface; The commercial terms in the contract document are compared and analyzed with the external market data to obtain the clauses in the commercial terms that deviate from the external market data; Based on the clauses in the aforementioned business terms that deviate from the external market data, generate a business risk assessment report; The clause evaluation model is based on a machine learning algorithm. It is trained by taking historical valid contract data and commercial dispute case data as inputs and taking the reasonableness quantification scores corresponding to the historical valid contract data and commercial dispute case data as outputs. The external market data includes one or more of the following: industry price indices, competitor quotes, and supply chain dynamics data; The business risk assessment report includes one or more of the following: price volatility risk, supply stability risk, and recommendations for protecting business interests.

5. The method as described in claim 1, characterized in that, The format agent, based on preset format specifications and format checking algorithms, is used to review the format compliance of contract documents, including: The Format Agent uses a format verification algorithm to check each item of the contract document based on a preset format specification, and obtains contract documents containing format issues. Based on the contract document containing formatting issues, generate an error message; After user authorization, based on the error message, correct the formatting issue according to the preset specifications and generate a formatting adjustment log; The format specifications include one or more of the following: font type specifications, font size specifications, line spacing settings specifications, page margin parameter specifications, heading style specifications, and numbering specifications; The error message includes: the location of the problem and suggestions for fixing it.

6. The method as described in claim 1, characterized in that, The process involves integrating the audit results of each agent into an audit report using a pre-defined data integration model and conflict resolution mechanism, including: By using a pre-defined data integration model, the review results of the legal agent, business agent, and format agent are mapped to standardized review results; When there are conflicts in the standardized audit results of different agents, a conflict resolution method is determined based on preset priority rules. An audit report is generated when there are no conflicts in the standardized audit results of each Agent; The audit report includes one or more of the following: audit overview, issue details, and improvement recommendations.

7. The method as described in claim 1, characterized in that, The key information includes one or more of the following: contract subject information, core transaction terms, rights and obligations, liability for breach of contract clauses, and supplementary agreements; The risk points include one or more of the following: legal risk points, commercial risk points, and format and standardization risk points; The legal risks mentioned include one or more of the following: risks of illegal clauses, risks of unclear rights and obligations, risks of invalid dispute resolution, and risks of compliance. The business risk points include one or more of the following: price reasonableness risk, performance risk, interest protection risk, and market linkage risk; The format specification risk points include one or more of the following: format non-standard risk, form problem risk, and document validity risk; The format includes one or more of the following: PDF, Word, HTML, and Excel.

8. A contract review system based on multi-agent collaboration, characterized in that, include: The document preprocessing module is used to receive contract documents uploaded by users, and to parse, clean, encode, and preprocess the contract documents to obtain preprocessed contract documents. The collaborative review module sends the preprocessed contract documents to a legal agent, a business agent, and a format agent, respectively, and performs review operations in parallel. The legal agent, based on a pre-set legal knowledge base and case reasoning technology, reviews the legal clauses in the contract documents and identifies legal risks. The business agent, based on a business rule base and clause evaluation model, combined with external market data, reviews the business clauses in the contract documents and assesses their commercial reasonableness. The format agent, based on pre-set format specifications and format checking algorithms, reviews the format compliance of the contract documents. The conflict resolution module is used to receive the review results from the legal agent, commercial agent and format agent, and integrate the review results of each agent into a review report through a preset data integration model and conflict resolution mechanism. The audit output module is used to highlight key information and risk points in the audit report and output the highlighted audit report in a preset format.

9. The system as described in claim 8, characterized in that, The document preprocessing module includes: The format parsing submodule is used to parse the format of the contract document, extract the constituent elements in the contract document and parse them; the constituent elements include one or more of the following: text content, table and image elements; The text cleaning submodule is used to clean the parsed text content to obtain the cleaned text content. The format conversion submodule is used to convert the cleaned text content into the UTF-8 standard encoding format to obtain the format-converted contract document. The structure generation submodule is used to identify the chapter structure, clause hierarchy and key element location of the contract document after format conversion using natural language processing technology, and generate structured document content. The sensitive information identification submodule is used to identify sensitive information in the structured document content using a sensitive information identification model, and to encrypt or decrypt the identified sensitive information. The data integration submodule is used to integrate document data that has undergone format parsing, text cleaning, encoding conversion, structure processing, and sensitive information processing to obtain preprocessed contract documents.

10. The system as described in claim 8, characterized in that, The system also includes a legal review module, specifically comprising: The clause parsing submodule is used by a legal agent to parse the legal clauses in the contract document based on a preset legal knowledge base and using natural language processing algorithms to extract the key legal elements of the contract document; the key legal elements include one or more of the following: subject information, rights and obligations agreement, and breach of contract liability clauses; The semantic matching submodule is used to semantically match the key legal elements with the legal knowledge base to locate clauses in the contract document that do not comply with legal provisions and potential legal risk points. The secondary verification submodule is used to call the case reasoning model to perform secondary verification on the legal clauses in the contract document based on the content of the clauses that do not comply with legal regulations and potential legal risk points, and generate legal risk assessment results.