Contract clause risk intelligent identification and evaluation method and system
By combining a pre-trained language model in the contract domain with a multi-dimensional risk feature library, the problems of inaccurate delineation of contract clause boundaries and insufficient analysis of the equivalence of rights and obligations are solved. This enables accurate identification and efficient assessment of contract clause risks, generates legally grounded modification suggestions, and improves the automation level of contract review.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- NANJING UNIV OF INFORMATION SCI & TECH
- Filing Date
- 2026-02-10
- Publication Date
- 2026-05-12
AI Technical Summary
Existing technologies suffer from inaccurate delineation of contract clause boundaries, lack of analysis on the equivalence of rights and obligations, limited risk assessment dimensions, and a lack of automatic generation of modification suggestions, resulting in low efficiency in contract review.
We employ a pre-trained language model in the contract domain for adaptive segmentation of clause boundaries. Combined with a multi-dimensional risk feature library and analysis of the equivalence of rights and obligations, we construct a two-dimensional assessment matrix of risk severity and probability of occurrence, and automatically generate modification suggestions based on a legal text knowledge base.
It has improved the accuracy of clause boundary identification, deepened the identification of rights and obligations risks, achieved multi-dimensional analysis of risk assessment, and automated generation of modification suggestions, significantly improving the efficiency and quality of contract review.
Smart Images

Figure CN121681812B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent contract review technology, and in particular to a method and system for intelligent identification and assessment of risks in contract terms. Background Technology
[0002] In today's business environment, contracts, as the core legal documents in economic activities between enterprises, directly affect the protection of a company's rights and interests and risk management. With the expansion of business scale and the increase in transaction complexity, the workload of contract review for enterprises has exploded, and the traditional model relying on manual review by legal personnel is no longer sufficient to meet actual needs.
[0003] Chinese invention patent CN118761735B discloses an electronic contract management method and system based on a deep learning model. This solution identifies contract clause categories, uses a clause risk information identification model matching the category to extract key risk information, determines a clause risk score based on a risk scoring model, generates an interactive review control when the score exceeds a threshold, and finally stores the contract in an archive database according to archival tags. This solution achieves a certain degree of automatic classification and risk identification of contract clauses, improving the automation level of contract review.
[0004] However, the aforementioned existing technologies still have the following technical shortcomings: First, at the clause classification level, existing solutions use TF-IDF and RAKE algorithms to extract keywords and then match them with a pre-set keyword list. This keyword-matching-based classification method is difficult to accurately identify clause boundaries, especially when contract clauses have diverse expressions and ambiguous boundaries, which can easily lead to errors in clause segmentation and affect the accuracy of subsequent risk identification. Second, at the risk identification level, although existing solutions introduce knowledge graph embedding technology to enhance semantic understanding, their risk identification scope is limited to extracting risk information from the clause text itself, failing to deeply analyze the equivalence of the rights and obligations of both parties to the contract, and making it difficult to identify the risk of unfavorable imbalances in rights and obligations hidden in the contract clauses. Third, at the risk assessment level, existing solutions use a single-dimensional risk scoring model, using key risk information and clause classification as input to generate a score. This single scoring method cannot comprehensively reflect the multidimensional characteristics of risk, especially failing to distinguish between the two key dimensions of risk severity and probability of occurrence, resulting in limited guiding value of the risk assessment results. Furthermore, at the output level, existing solutions stop at generating review controls and archiving, failing to automatically generate legally grounded modification suggestions for identified high-risk clauses. Legal personnel still need to spend a lot of time studying how to modify risky clauses, reducing the overall efficiency of contract review.
[0005] Therefore, there is an urgent need for a technical solution for intelligent identification and assessment of contractual risks that can achieve precise segmentation of multi-granularity clauses, in-depth analysis of the equivalence of rights and obligations, two-dimensional assessment of risk severity and probability of occurrence, and automatic generation of modification suggestions. Summary of the Invention
[0006] To address the technical problems in existing technologies, such as inaccurate delineation of contract clause boundaries, lack of analysis on the equivalence of rights and obligations, single risk assessment dimensions, and lack of automatic generation of modification suggestions, this invention proposes a method and system for intelligent identification and assessment of contract clause risks.
[0007] In a first aspect, the present invention provides a method for intelligent identification and assessment of risks in contract terms, comprising:
[0008] S1. Multi-granularity clause parsing: Obtain the target contract document to be reviewed, use a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document, obtain the clause boundary segmentation results, and identify the legal attribute category corresponding to each clause text segment. The legal attribute category includes at least one of the following: subject clause, subject matter clause, price clause, performance clause, breach of contract clause, dispute resolution clause, confidentiality clause, and force majeure clause.
[0009] S2. Risk Identification: Based on a multi-dimensional risk feature library, risk identification processing is performed on each clause text segment in the clause boundary segmentation result. The risk pattern matching result is identified from each clause text segment through semantic similarity matching. The risk pattern matching result includes at least one of the following: clauses with unequal rights and obligations, unilateral exemption trap clauses, unlimited joint and several liability clauses, clauses with unfavorable jurisdiction, and clauses with ambiguous intellectual property ownership. At the same time, structural defect detection is performed on each clause text segment to obtain structural defect detection results, and the value of the rights and obligations equivalence index of each clause text segment is calculated.
[0010] S3. Risk Assessment: Based on the risk pattern matching results and structural defect detection results, determine the risk severity level of each clause text segment, determine the occurrence probability level of each clause text segment based on the legal attribute category and the value of the rights and obligations equivalence index, construct a two-dimensional risk assessment matrix based on the risk severity level and the occurrence probability level, and calculate the clause risk level score of each clause text segment.
[0011] S4. Modification suggestion generation: Filter high-risk clauses whose risk level scores exceed the preset risk threshold, search the legal knowledge base for each high-risk clause to obtain matching legal provisions, and automatically generate modification suggestion text based on the legal provisions.
[0012] S5. Output Results: Generate a contract risk assessment report based on the risk level score of each clause text segment; generate clause annotation data based on risk pattern matching results and modification suggestions; and generate a list of key negotiation points based on high-risk clauses and legal provisions.
[0013] As a preferred option, the adaptive segmentation of clause boundaries in the multi-granularity clause parsing step includes:
[0014] The target contract document is preprocessed by text extraction to obtain a document text sequence;
[0015] A sliding window mechanism is used to calculate the semantic coherence score between adjacent text segments in a document text sequence;
[0016] Points with semantic coherence scores below a preset coherence threshold are identified as candidate clause boundaries.
[0017] Based on a pre-trained language model in the contract domain, the confidence level of candidate points for clause boundaries is evaluated. Candidate points whose confidence level exceeds a preset confidence threshold are retained as the final clause boundaries, generating clause boundary segmentation results.
[0018] As a preferred method, the calculation of semantic coherence score includes:
[0019] Input the preceding and following text segments within the sliding window into the pre-trained language model for the contract domain to obtain the preceding semantic vector and the following semantic vector, respectively.
[0020] The cosine similarity between the preceding and following semantic vectors is calculated as the semantic coherence score.
[0021] As a preferred option, semantic similarity matching in the risk identification step includes:
[0022] Input each clause text segment into a pre-trained language model in the contract domain to obtain clause semantic vectors;
[0023] By inputting the risk pattern templates from the multi-dimensional risk feature library into a pre-trained language model in the contract domain, risk pattern semantic vectors are obtained.
[0024] Calculate the semantic similarity between the semantic vector of the clause and the semantic vector of each risk pattern;
[0025] If the semantic similarity value exceeds the preset similarity threshold, it is determined that the text segment of the clause has a corresponding risk pattern, and a risk pattern matching result is generated.
[0026] As a preferred option, the calculation of the value of the rights and obligations equivalence index includes:
[0027] Extract the sets of rights elements and the sets of obligations elements from each clause text segment;
[0028] Calculate the strength of rights for the set of rights elements and the strength of obligations for the set of obligations elements, respectively.
[0029] The value of the rights and obligations equivalence index is calculated based on the weighted ratio of the rights strength value and the obligations strength value.
[0030] If the value of the rights and obligations equivalence index is lower than the preset equivalence threshold, the clause text is deemed to have a risk of unequal rights and obligations.
[0031] As a preferred option, the calculation of the risk level score for the clauses in the risk assessment step includes:
[0032] The risk severity level is determined based on the type and number of risk patterns in the risk pattern matching results, and the risk severity level is divided into five levels.
[0033] The probability level of occurrence is determined based on the deviation of the baseline probability corresponding to the legal attribute category and the value of the rights and obligations equivalence index. The probability level of occurrence is divided into five levels.
[0034] The severity level and probability level of occurrence are used as row and column indices in the two-dimensional risk assessment matrix;
[0035] The risk level score of a clause is calculated based on a two-dimensional matrix of risk assessment. The risk level score of a clause is equal to the weighted sum of the risk severity level and the probability of occurrence level.
[0036] As a preferred option, structural defect detection includes:
[0037] Check whether any clauses in the contract text are missing essential contract clauses, which include clauses on the subject matter, price, and performance period.
[0038] Check whether the key elements in each clause are completely expressed. Key elements include time, amount, subject, and location.
[0039] The absence of at least one of the essential clauses or incomplete description of key elements will be considered as a structural defect detection result.
[0040] As a preferred option, the modification suggestion generation steps include:
[0041] The modification direction label is determined based on the risk pattern matching results of high-risk clauses;
[0042] Based on the modification direction label, retrieve matching legal provisions from the legal provisions knowledge base;
[0043] A text generation model is used to generate suggested modification text based on the original text of high-risk clauses and legal provisions;
[0044] The proposed amendments are linked and annotated with the relevant legal provisions.
[0045] As a preferred approach, the generation of the negotiation key points list in the output step includes:
[0046] Extract the core points of contention from each high-risk clause;
[0047] Prioritize the core points of contention based on the risk level rating of the terms;
[0048] Based on legal provisions and information, we generate negotiation strategy suggestions for each core point of contention.
[0049] The key points of contention, priorities, and negotiation strategy suggestions are integrated into a list of key negotiation points.
[0050] Secondly, the present invention also provides a contract clause risk intelligent identification and assessment system, comprising:
[0051] The multi-granularity clause parsing module is used to obtain the target contract document to be reviewed. It uses a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document, obtain the clause boundary segmentation results, and identify the legal attribute category corresponding to each clause text segment.
[0052] The risk identification module is used to identify risks in each clause text segment in the clause boundary segmentation result based on a multi-dimensional risk feature library. It identifies risk pattern matching results from each clause text segment through semantic similarity matching, and performs structural defect detection on each clause text segment to obtain structural defect detection results. It also calculates the rights and obligations equivalence index value of each clause text segment.
[0053] The risk assessment module is used to determine the risk severity level of each clause text segment based on the risk pattern matching results and structural defect detection results, determine the occurrence probability level of each clause text segment based on the legal attribute category and the value of the rights and obligations equivalence index, construct a two-dimensional risk assessment matrix based on the risk severity level and the occurrence probability level, and calculate the clause risk level score of each clause text segment.
[0054] The modification suggestion generation module is used to filter high-risk clauses whose risk level scores exceed a preset risk threshold, search the legal knowledge base for each high-risk clause to obtain matching legal provisions, and automatically generate modification suggestion text based on the legal provisions.
[0055] The output module is used to generate a contract risk assessment report based on the risk level score of each clause text segment, generate clause annotation data based on risk pattern matching results and modification suggestions, and generate a list of key negotiation points based on high-risk clauses and legal provisions.
[0056] Compared with the prior art, the present invention, employing the above technical solution, has the following technical effects:
[0057] 1. By using a pre-trained language model in the contract domain for adaptive segmentation of clause boundaries, compared with the keyword matching method of existing technologies, it can accurately identify clause boundaries based on deep semantic understanding, avoid the adverse effects of clause segmentation errors on subsequent risk identification, and improve the accuracy of clause boundary identification to over 95%.
[0058] 2. By constructing a multi-dimensional risk feature database and introducing quantitative analysis of the equivalence of rights and obligations, compared with the existing technology that only extracts risk information, it can deeply identify the imbalance of rights and obligations between the two parties in the contract, effectively discover the adverse risks hidden in the terms, and the risk identification rate of unequal rights and obligations can reach more than 92%.
[0059] 3. By constructing a two-dimensional assessment matrix of risk severity and probability of occurrence, compared with the single scoring method of existing technologies, it is possible to comprehensively assess the risks of the terms from a multi-dimensional perspective, providing a scientific basis for differentiated risk management strategies, and significantly improving the differentiation and guidance value of risk assessment.
[0060] 4. By automatically generating modification suggestions based on a legal knowledge base and annotating the legal basis, compared to existing technologies that only stop at risk identification, it can provide legal personnel with legally supported modification solutions, extending contract review from identifying problems to solving them, and improving contract modification efficiency by more than 60%.
[0061] 5. By providing a three-in-one output system that includes contract risk assessment reports, clause annotations, and negotiation key point reminders, compared to the existing technology that only archives and stores information, we can provide comprehensive decision support for enterprise contract negotiations and significantly enhance the enterprise's proactive position in contract negotiations. Attached Figure Description
[0062] Figure 1 This is a flowchart of the intelligent identification and assessment method for contract terms risks according to the present invention.
[0063] Figure 2 This is a structural block diagram of the intelligent identification and assessment system for contract terms risks according to the present invention. Detailed Implementation
[0064] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of the application will be further described in detail below with reference to the accompanying drawings. The described embodiments are only a part of the embodiments involved in this invention. All non-innovative embodiments based on these embodiments by other researchers in the art are within the protection scope of this invention. Furthermore, the step numbers in the embodiments of this invention are only set for ease of explanation and do not limit the order of the steps. The execution order of each step in the embodiments can be adaptively adjusted according to the understanding of those skilled in the art.
[0065] Example 1
[0066] Provide a method for intelligent identification and assessment of risks in contract terms, the process of which is as follows: Figure 1 As shown. Regarding the executing entity of the method in this embodiment, it can be any controller or processor with computing or processing capabilities. Preferably, the executing entity can be a contract intelligent review system deployed on a cloud server or a local server. Through the collaborative processing of multi-granularity clause parsing, risk identification, risk assessment, modification suggestion generation, and three-in-one output, it realizes intelligent identification and assessment of contract clause risks.
[0067] Step S1: Multi-granularity clause parsing steps.
[0068] In this embodiment, the target contract document D to be reviewed is first obtained. The target contract document can be in PDF, Word, or scanned format. The system first preprocesses the target contract document. For PDF and Word documents, text parsing technology is used to directly extract the text content; for scanned documents, optical character recognition technology is used to recognize characters and then extract the text content. After preprocessing, a document text sequence is obtained, which retains the paragraph structure and text order of the original contract.
[0069] One of the core innovations of this invention lies in using a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document. Unlike existing technologies that use keyword extraction algorithms such as TF-IDF and RAKE, this embodiment fully utilizes the deep semantic understanding capabilities of the pre-trained language model to adaptively determine clause boundaries by analyzing the semantic coherence between adjacent text segments.
[0070] Specifically, in this embodiment, a sliding window mechanism is used to perform clause boundary detection on the document text sequence.
[0071] Preferably, the sliding window size is set to 512 characters, and the window step size is set to 128 characters. At each window position, the preceding and following text segments within the window are input into a pre-trained language model for the contract domain, respectively, to obtain the preceding semantic vector. and post-sequence semantic vector In this embodiment, the pre-trained language model for the contract domain is preferably a BERT model pre-trained on a large-scale Chinese contract corpus, with a hidden layer dimension of 768 and 12 attention heads.
[0072] The semantic coherence score is calculated using cosine similarity, and the formula is as follows:
[0073] ;
[0074] in, Indicates the location The semantic coherence score is calculated, with a value range of [-1, 1]. A higher value indicates a stronger semantic connection between the preceding and following text segments. Indicates position The semantic vector of the previous text segment has a dimension of 768. Indicates position The semantic vector of the subsequent text segment has a dimension of 768. This represents the L2 norm of a vector.
[0075] When the semantic coherence score is lower than the preset coherence threshold At this point, the location is marked as a candidate point for clause boundary. Preferably, a preset coherence threshold is used. The threshold is set to 0.65. This threshold was determined based on statistical analysis of a large number of business contract samples, which can strike a balance between accurate segmentation and avoiding over-segmentation.
[0076] Furthermore, to improve the accuracy of clause boundary identification, this embodiment performs a boundary confidence assessment on the candidate clause boundary points. The boundary confidence assessment uses a boundary classifier based on a pre-trained language model in the contract domain. This boundary classifier takes 256 characters of text before and after the candidate point as input and outputs a confidence score indicating whether the position is a true clause boundary.
[0077] The formula for calculating the boundary confidence score is:
[0078] ;
[0079] in, Indicates position The boundary confidence score at the point ranges from (0,1). This represents the Sigmoid activation function; This indicates that the pre-trained language model in the contract domain is located at... The output CLS vector has a dimension of 768. The weight matrix represents the boundary classifier, with a dimension of 768×1; This represents the bias term of the boundary classifier and is a scalar. Only boundary confidence values exceeding a preset confidence threshold are retained. The candidate points are used as the final clause boundaries. Preferably, a pre-set confidence threshold is used. Set to 0.80 to ensure high accuracy in identifying clause boundaries.
[0080] Through the above adaptive segmentation process of clause boundaries, the target contract document is segmented into... Each clause text segment These clause text segments constitute the clause boundary segmentation results. In this embodiment, for a typical business contract, the number of clauses N is usually between 30 and 80.
[0081] After segmenting the clause boundaries, this embodiment further identifies the legal attribute category corresponding to each clause text segment. The legal attribute category adopts a standardized contract clause classification system, including eight core clause types: Subject Matter Clauses, which stipulate the basic information of the contracting parties; Subject Matter Clauses, which stipulate the subject matter or service content of the contract transaction; Price Clauses, which stipulate the contract price, payment method, and payment period; Performance Clauses, which stipulate the method, place, and time limit for fulfilling contractual obligations; Breach of Contract Clauses, which stipulate the circumstances of breach of contract and the corresponding liability; Dispute Resolution Clauses, which stipulate the method of dispute resolution and the governing body; Confidentiality Clauses, which stipulate confidentiality obligations and the confidentiality period; and Force Majeure Clauses, which stipulate the definition of force majeure events and exemption from liability.
[0082] Legal attribute category identification employs a multi-label classifier based on a pre-trained language model in the contract domain. This embodiment identifies each clause text segment. Input a pre-trained language model in the contract domain to obtain semantic representation vectors of clauses. Then, the legal attribute category to which the clause belongs is predicted through a multi-label classification layer:
[0083] ;
[0084] in, Indicates the text of the terms and conditions The probability vectors belonging to each legal attribute category are 8-dimensional, corresponding to eight legal attribute categories; This represents the weight matrix of the classification layer, with dimensions of 768×8; This represents the bias vector for the classification layer, with 8 dimensions. When the probability value of a certain category exceeds the classification threshold of 0.50, the clause is determined to belong to the corresponding legal attribute category.
[0085] It should be noted that a clause text segment may belong to multiple legal attribute categories simultaneously, such as clauses involving both price and performance period. In this embodiment, the accuracy rate of legal attribute category identification can reach over 93%.
[0086] Step S2: Risk identification step.
[0087] After completing the multi-granularity clause parsing, this embodiment proceeds to the risk identification step. The risk identification step performs comprehensive risk identification processing on each clause text segment in the clause boundary segmentation result based on a multi-dimensional risk feature library. This mainly includes three parallel identification tasks: semantic similarity matching to identify risk patterns, structural defect detection, and rights and obligations equivalence analysis.
[0088] In this embodiment, the multi-dimensional risk feature library is a risk knowledge base constructed and continuously optimized by legal experts, containing various typical contract risk model templates. These risk model templates cover the most common and important risk types in corporate contract review, preferably including but not limited to the following five core risk models: Unequal rights and obligations clauses refer to clauses in the contract where one party bears excessive obligations while the other party gains excessive rights, such as Party B bearing all quality risks while Party A bears no inspection obligations; Unilateral exemption trap clauses refer to clauses where one party exempts itself from liability, such as Party A not being liable for any indirect losses; Unlimited joint and several liability clauses refer to clauses requiring one party to bear unlimited joint and several liability for the actions of the other party, such as Party B bearing unlimited joint and several liability for the actions of its subcontractors; Unfavorable jurisdiction clauses refer to clauses that stipulate the jurisdiction or governing body of a dispute that is unfavorable to one party, such as stipulating that the court in the other party's location has jurisdiction; Ambiguous intellectual property ownership clauses refer to clauses that do not clearly define the ownership of intellectual property rights, which can easily lead to subsequent intellectual property disputes.
[0089] Semantic similarity matching is the core step in risk identification in this invention. This embodiment will compare the text segments of each clause. Input a pre-trained language model in the contract domain to obtain clause semantic vectors. At the same time, various risk pattern templates from the multi-dimensional risk feature library will be used. Also input the pre-trained language model in the contract domain to obtain risk pattern semantic vectors. Subsequently, the semantic similarity between the semantic vector of the clauses and the semantic vectors of each risk pattern is calculated:
[0090] ;
[0091] in, Indicates the text of the terms and conditions With risk model template The semantic similarity between them, with values ranging from [-1, 1]; Indicates the text of the terms and conditions The semantic vector has a dimension of 768. Risk pattern template The semantic vector has 768 dimensions. When the semantic similarity exceeds a preset similarity threshold... At that time, the judgment clause Risk model exists The corresponding risks. Preferably, a preset similarity threshold is used. Setting it to 0.75 provides a good balance between recall and precision.
[0092] In this embodiment, the multi-dimensional risk feature library contains approximately 150 risk pattern templates M, covering various types of risks commonly found in business contracts.
[0093] In parallel with semantic similarity matching, this embodiment performs structural defect detection on each clause text segment. Structural defects refer to deficiencies in the structural integrity of the contract, mainly including two categories: first, the absence of essential clauses in the contract; and second, incomplete description of key elements.
[0094] To detect missing essential contract terms, this embodiment establishes a list of essential contract terms, including clauses on the subject matter, price, and performance period. The system compares the legal attribute category identification results with the list of essential terms to detect whether any essential terms are missing. If an essential term is not identified in the contract, it is marked as a defect due to missing essential terms.
[0095] To detect incomplete descriptions of key elements, this embodiment employs named entity recognition technology to extract key elements from each clause's text segment. Key elements include time elements, monetary elements, subject elements, and location elements. Time elements include date, deadline, and point in time; monetary elements include price, fees, and penalties; subject elements include the names and representatives of the parties; and location elements include the place of performance and jurisdiction. When a clause's essential key elements are not extracted or are vaguely described, it is marked as an incomplete description of key elements.
[0096] Another core innovation of this invention lies in the analysis of the equivalence of rights and obligations. In existing technologies, contract risk identification primarily focuses on whether the clauses themselves contain obvious risk statements, while neglecting the analysis of the balance of rights and obligations between the contracting parties. This invention, by constructing a quantitative assessment system for the equivalence of rights and obligations, can deeply identify the risks of imbalances in rights and obligations hidden within contract clauses.
[0097] Specifically, this embodiment first extracts the set of rights elements from each clause text segment. and the set of obligations Rights elements refer to the powers granted to one party in the clause, such as the right to receive payment, the right to terminate the contract, and the right to obtain compensation; obligations elements refer to the responsibilities required of one party in the clause, such as the obligation to deliver goods, the obligation to guarantee quality, and the obligation to bear liability for breach of contract. The extraction of rights and obligations elements employs a sequence labeling model trained on a legal corpus.
[0098] After extracting the sets of rights and obligations, the numerical values of the strength of rights are calculated separately. and the intensity of obligations The calculation of the strength of rights and obligations comprehensively considers the quantity, importance, and degree of the factors, and adopts a weighted summation method:
[0099] ;
[0100] ;
[0101] in, Indicates the text of the terms and conditions The numerical value of the strength of rights, ranging from [0, +∞). Indicates the text of the terms and conditions The numerical value of the obligation intensity, ranging from [0, +∞). Representing the elements of rights The importance weight, with a value range of (0,1], is preset by legal experts; elements of an obligation The importance weight, with a value range of (0,1]; Representing the elements of rights The degree value, ranging from [1,5], reflects the strength of the right; elements of an obligation The degree value, ranging from [1,5], reflects the severity of the obligation.
[0102] Calculate the value of the rights and obligations equivalence index based on the values of rights strength and obligations. :
[0103] ;
[0104] in, Indicates the text of the terms and conditions The value of the rights and obligations equivalence index is in the range of (0,1). The closer the value is to 0.5, the more balanced the rights and obligations are. The farther the value deviates from 0.5, the more serious the imbalance is. and Let be the weighting coefficient, satisfying Preferably, take When the value of the rights and obligations equivalence index Below the preset parity threshold or higher At that time, it was determined that the clause posed a risk of unequal rights and obligations.
[0105] Preferably, a pre-set parity threshold is used. Set to 0.35, that is, when or At that time, it was determined that there was a risk of unequal rights and obligations.
[0106] Step S3: Risk assessment step.
[0107] After completing risk identification, this embodiment proceeds to the risk assessment step. The core innovation of the risk assessment step lies in constructing a two-dimensional assessment matrix of risk severity and probability of occurrence. Compared with the single scoring method of existing technologies, this approach can comprehensively assess the risks of the terms from a multi-dimensional perspective.
[0108] First, this embodiment determines the risk severity level of each clause text segment based on risk pattern matching results and structural defect detection results. The risk severity level reflects the potential loss if the risk occurs, and is divided into five levels: Level 1 represents minor risk, with small and controllable potential losses; Level 2 represents moderate risk, which may cause some losses but with a limited impact; Level 3 represents medium risk, which may cause significant losses and affect normal business operations; Level 4 represents severe risk, which may cause major losses and affect the company's reputation; and Level 5 represents extremely severe risk, which may lead to huge compensation payments or legal proceedings against the company.
[0109] The determination of risk severity level comprehensively considers the type and number of risk patterns. This embodiment pre-sets baseline severity levels for various risk patterns: 3 for clauses with unequal rights and obligations; 4 for unilateral exemption trap clauses; 5 for unlimited joint and several liability clauses; 2 for clauses with unfavorable jurisdiction; and 4 for clauses with ambiguous intellectual property ownership. When a clause contains multiple risk patterns, the highest baseline severity level is taken as the risk severity level for that clause. If the clause also has structural defects, one level is added to the baseline severity level, but the maximum cannot exceed level 5.
[0110] Secondly, this embodiment determines the probability level of occurrence of each clause text segment based on the legal attribute category and the numerical value of the rights and obligations equivalence index. The probability level reflects the likelihood of a risk actually occurring, and is also divided into five levels: Level 1 indicates an extremely low probability, meaning the risk is almost impossible to occur; Level 2 indicates a low probability, meaning the risk is less likely to occur; Level 3 indicates a moderate probability, meaning the risk has a certain possibility of occurring; Level 4 indicates a high probability, meaning the risk is more likely to occur; and Level 5 indicates an extremely high probability, meaning the risk is almost certain to occur.
[0111] The probability level is determined using a baseline probability plus deviation correction. This embodiment pre-sets a baseline probability level for various legal attribute categories: the baseline probability level for breach of contract clauses is 4, because breach of contract clauses are frequently applied; the baseline probability level for dispute resolution clauses is 3; the baseline probability level for price clauses is 3; the baseline probability level for confidentiality clauses is 2; and the baseline probability level for other clause types is 2.
[0112] Based on the baseline probability level, this embodiment makes adjustments according to the degree of deviation of the rights and obligations equivalence index value. The formula for calculating the deviation is:
[0113] ;
[0114] in, This represents the degree of deviation from the equality of rights and obligations, with a value range of [0,1]. The higher the value, the more severe the deviation from the equilibrium state. When the deviation exceeds 0.3, the probability level increases by 1 level; when the deviation exceeds 0.5, the probability level increases by 2 levels, but the maximum cannot exceed level 5.
[0115] In determining the severity level of risk and probability level of occurrence Subsequently, this embodiment constructs a two-dimensional risk assessment matrix and calculates the risk level score of each clause. .
[0116] Preferably, the risk assessment two-dimensional matrix is a 5×5 matrix, where the row index represents the risk severity level (1 to 5), the column index represents the probability of occurrence level (1 to 5), and the matrix elements represent the corresponding comprehensive risk level score. The formula for calculating the clause risk level score is as follows:
[0117] ;
[0118] in, Indicates the text of the terms and conditions The comprehensive risk level score ranges from [2, 25]. This indicates the severity level of the risk, with values ranging from {1, 2, 3, 4, 5}. This indicates the probability level of occurrence, with values {1, 2, 3, 4, 5}. This represents the severity weight, with a value range of (0,1), and is preferably set to 0.3; This represents the probability weight, with a value range of (0,1), and is preferably set to 0.3; This represents the interaction coefficient, with a value range of (0,1), preferably set to 0.08, to reflect the synergistic effect of severity and probability. The design philosophy of this calculation formula is that overall risk depends not only on the linear superposition of severity and probability, but also on their interaction effect—a combination of high severity and high probability should yield a higher risk score.
[0119] Step S4: Modify the suggestion generation process.
[0120] After completing the risk assessment, this embodiment proceeds to the modification suggestion generation step. This step is one of the key innovations of this invention compared to existing technologies, achieving a leap from risk discovery to risk resolution.
[0121] First, in this embodiment, the risk level score of the screening criteria exceeds a preset risk threshold. High-risk clauses. Preferably, a preset risk threshold is used. A risk level score of 15 indicates that clauses with a risk rating exceeding 15 are considered high-risk and require close monitoring and modification. According to the two-dimensional risk assessment matrix, combinations with a risk rating exceeding 15 include: severity 5 × probability 3 or higher, severity 4 × probability 4 or higher, severity 3 × probability 5, etc.
[0122] For each high-risk clause, this embodiment searches a legal knowledge base to obtain matching legal provisions. The legal knowledge base is a professional legal knowledge base constructed by this invention, containing provisions from the Chinese Contract Law, the Contract Law section of the Civil Code, the Company Law, intellectual property-related laws, and judicial interpretations of the Supreme People's Court regarding contract disputes. The legal knowledge base uses a structured storage method, with each legal provision including fields such as provision number, provision content, applicable scenario, and keyword tags.
[0123] The legal provision retrieval employs a two-stage strategy. The first stage is a preliminary screening stage, where risk pattern matching results for high-risk clauses determine modification direction tags. Then, keyword matching is performed in the legal provision knowledge base based on these modification direction tags to recall a set of candidate legal provisions. The second stage is a fine-tuning stage, where the semantic relevance between high-risk clauses and each candidate legal provision is calculated, and the top K legal provisions with the highest semantic relevance are selected as the final matching results. Preferably, K is set to 3, meaning that a maximum of 3 legal provisions are provided for each high-risk clause.
[0124] After obtaining the legal basis information, this embodiment uses a text generation model to automatically generate suggested modification text based on the original text of the high-risk clause and the legal basis information. The text generation model is preferably a large-scale language model fine-tuned from legal document corpora. Its inputs are the original text of the high-risk clause, the identified risk pattern, and the matching legal provisions; the output is the suggested modification text. The generation of the suggested modification text follows these principles: first, clearly identifying the risk issues in the original clause; second, proposing specific modification schemes, including content to be added, deleted, or modified; and finally, indicating the legal provisions on which the modification is based.
[0125] This embodiment further links the proposed amendments with relevant legal provisions, ensuring that each amendment has clear legal support. This linked annotation not only enhances the professionalism and credibility of the amendments but also facilitates legal personnel in quickly verifying the accuracy of the legal basis.
[0126] Step S5: Output the steps.
[0127] After generating the modification suggestions, this embodiment enters the output step, generating a three-in-one output result: a contract risk assessment report, clause annotation data, and a list of key negotiation points.
[0128] The contract risk assessment report is the core document output by this embodiment, and includes the following: The report cover includes basic information such as the contract name, review date, and overall risk level; the report overview includes statistical information such as the total number of contract clauses, the distribution of the number of clauses at each risk level, and the proportion of high-risk clauses; the detailed analysis lists the clauses with risks one by one in descending order of risk level, including the original text of the clause, legal attribute category, identified risk pattern, risk severity level, probability of occurrence level, comprehensive risk level score, suggested modification text, and legal basis; the risk distribution chart uses visual charts to show the distribution of various risk patterns and the distribution of risk severity.
[0129] The clause annotation data is the annotation format file output by this embodiment, used to directly display risk markings and modification suggestions on the original contract document. The clause annotation data adopts a structured data format, with each annotation containing fields such as annotation location, annotation type, annotation content, and related information. The annotation location is precise to the start and end positions of the clause text segment; the annotation type includes risk warnings, modification suggestions, legal basis, etc.; the annotation content is the specific annotation text; and the related information is used to establish the relationship between different annotations. Through the clause annotation data, legal personnel can intuitively see the risk markings and modification suggestions for each clause while reading the original contract text.
[0130] The Negotiation Key Points Reminder Checklist is an output document specifically designed for contract negotiation scenarios in this embodiment, used to guide enterprises in securing more favorable terms during contract negotiations. The generation of the Negotiation Key Points Reminder Checklist includes the following steps: First, extract the core points of contention from each high-risk clause; these core points of contention refer to the most critical risk points or conflicts of interest in the clauses. Second, prioritize the core points of contention based on the clause risk level score, with higher-risk-level points ranked higher. Third, generate negotiation strategy suggestions corresponding to each core point of contention based on legal provisions and information, including negotiation objectives, bottom-line positions, and alternative solutions. Finally, integrate the core points of contention, priority ranking, and negotiation strategy suggestions into the Negotiation Key Points Reminder Checklist.
[0131] Through a three-in-one output system, the method of this invention provides comprehensive decision support for enterprise contract review and negotiation, significantly improving the efficiency and effectiveness of contract risk management.
[0132] Example 2
[0133] Provide a contract clause risk intelligent identification and assessment system, with the following structure: Figure 2 As shown, it includes: a multi-granularity clause parsing module, a risk identification module, a risk assessment module, a modification suggestion generation module, and an output module.
[0134] The multi-granularity clause parsing module is used to acquire the target contract document to be reviewed. It employs a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document, obtaining the clause boundary segmentation results and identifying the legal attribute category corresponding to each clause text segment. For a detailed description of step S1 in the aforementioned method embodiment, the multi-granularity clause parsing module internally includes a document preprocessing submodule, a sliding window semantic analysis submodule, a boundary confidence assessment submodule, and a legal attribute classification submodule.
[0135] The risk identification module is used to identify risks in each clause text segment of the clause boundary segmentation result based on a multi-dimensional risk feature library. It identifies risk pattern matching results from each clause text segment through semantic similarity matching, performs structural defect detection on each clause text segment to obtain structural defect detection results, and calculates the rights and obligations equivalence index value for each clause text segment. For specific implementation details, please refer to the detailed description of step S2 in the aforementioned method embodiment. The risk identification module internally includes a semantic similarity matching submodule, a structural defect detection submodule, and a rights and obligations equivalence analysis submodule.
[0136] The risk assessment module determines the risk severity level of each clause text segment based on risk pattern matching results and structural defect detection results, determines the occurrence probability level of each clause text segment based on legal attribute categories and rights and obligations equivalence index values, constructs a two-dimensional risk assessment matrix based on the risk severity level and occurrence probability level, and calculates the clause risk level score of each clause text segment. For a detailed description of step S3 in the aforementioned method embodiment, the risk assessment module internally includes a severity assessment submodule, a probability assessment submodule, and a two-dimensional matrix calculation submodule.
[0137] The modification suggestion generation module is used to filter high-risk clauses whose risk level scores exceed a preset risk threshold. For each high-risk clause, it searches the legal knowledge base to obtain matching legal provisions and automatically generates modification suggestion text based on the legal provisions. For a detailed description of step S4 in the aforementioned method embodiment, the modification suggestion generation module includes a high-risk clause filtering submodule, a legal provisions retrieval submodule, and a suggestion text generation submodule.
[0138] The output module generates a contract risk assessment report based on the risk level score of each clause text segment, generates clause annotation data based on risk pattern matching results and modification suggestions, and generates a list of key negotiation points based on high-risk clauses and legal provisions. For a detailed description of step S5 in the aforementioned method embodiment, the output module includes a report generation submodule, an annotation rendering submodule, and a negotiation point extraction submodule.
[0139] In this embodiment, the system modules form a deeply coupled data flow and processing flow: the output of the multi-granularity clause parsing module (clause boundary segmentation results and legal attribute categories) serves as the key input of the risk identification module; the output of the risk identification module (risk pattern matching results, structural defect detection results, and rights and obligations equivalence index values) serves as the key input of the risk assessment module; the output of the risk assessment module (clause risk level score) serves as the key input of the modification suggestion generation module; and the output of the modification suggestion generation module (modification suggestion text and legal basis information) together with the outputs of the preceding modules serve as the input of the output module. This deeply coupled architecture design ensures full information flow and collaborative processing between the modules, realizing end-to-end intelligent processing of contract clause risk identification and assessment.
[0140] In a preferred embodiment of the present invention, the system further includes a feedback learning module, used to receive feedback from legal personnel on risk identification results and modification suggestions, and to optimize and update the multi-dimensional risk feature library and model parameters of each module based on the feedback data. The design of the feedback learning module enables the system to continuously learn and improve, thereby continuously enhancing the accuracy of risk identification and assessment.
[0141] The system in this embodiment can be deployed on a cloud server or a local server, providing services to users through web applications or desktop applications. Preferably, the system adopts a microservice architecture design, with each module deployed and expanded independently, enabling flexible adjustment of system resource configuration according to actual business needs and meeting the contract review needs of enterprises of different sizes.
[0142] In another embodiment of the present invention, an electronic device is provided, including at least one processor and a memory communicatively connected to the processor. The memory stores instructions executable by the processor, which, when executed by the processor, cause the processor to perform the steps of the contract terms risk intelligent identification and assessment method of any embodiment of the present invention.
[0143] In another embodiment of the present invention, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps of the contractual terms risk intelligent identification and assessment method of any embodiment of the present invention.
[0144] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for intelligent identification and assessment of risks in contract terms, characterized in that, include: S1. Multi-granularity clause parsing: Obtain the target contract document to be reviewed, use a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document, obtain the clause boundary segmentation results, and identify the legal attribute category corresponding to each clause text segment. The legal attribute category includes at least one of the following: subject clause, subject matter clause, price clause, performance clause, breach of contract clause, dispute resolution clause, confidentiality clause, and force majeure clause. S2. Risk Identification: Based on a multi-dimensional risk feature library, risk identification processing is performed on each clause text segment in the clause boundary segmentation results. The risk pattern matching results are identified from each clause text segment through semantic similarity matching. The risk pattern matching results include at least one of the following: clauses with unequal rights and obligations, unilateral exemption trap clauses, unlimited joint and several liability clauses, clauses with unfavorable jurisdiction, and clauses with ambiguous intellectual property ownership. Structural defects are detected in each clause text segment to obtain the structural defect detection results, and the value of the rights and obligations equivalence index of each clause text segment is calculated. The calculation of the value of the rights and obligations equivalence index includes: Extract the sets of rights elements and the sets of obligations elements from each clause text segment; Calculate the strength of rights for the set of rights elements and the strength of obligations for the set of obligations elements, respectively. The value of the rights and obligations equivalence index is calculated based on the weighted ratio of the rights strength value and the obligations strength value. When the value of the rights and obligations equivalence index is lower than the preset equivalence threshold, it is determined that there is a risk of unequal rights and obligations in the clause text. S3. Risk Assessment: Based on the risk pattern matching results and structural defect detection results, determine the risk severity level of each clause text segment, determine the occurrence probability level of each clause text segment based on the benchmark probability corresponding to the legal attribute category and the value of the rights and obligations equivalence index, construct a two-dimensional risk assessment matrix based on the risk severity level and occurrence probability level, and calculate the clause risk level score of each clause text segment. S4. Modification suggestion generation: Filter high-risk clauses whose risk level scores exceed the preset risk threshold, search the legal knowledge base for each high-risk clause to obtain matching legal provisions, and automatically generate modification suggestion text based on the legal provisions. S5. Output Results: Generate a contract risk assessment report based on the risk level score of each clause text segment; generate clause annotation data based on risk pattern matching results and modification suggestions; and generate a list of key negotiation points based on high-risk clauses and legal provisions.
2. The intelligent identification and assessment method for contract clause risks according to claim 1, characterized in that, In step S1, the adaptive segmentation of the clause boundaries includes: The target contract document is preprocessed by text extraction to obtain a document text sequence; A sliding window mechanism is used to calculate the semantic coherence score between adjacent text segments in a document text sequence; Points with semantic coherence scores below a preset coherence threshold are identified as candidate clause boundaries. Based on a pre-trained language model in the contract domain, the confidence level of candidate points for clause boundaries is evaluated. Candidate points whose confidence level exceeds a preset confidence threshold are retained as the final clause boundaries, generating clause boundary segmentation results.
3. The intelligent identification and assessment method for contract terms risks according to claim 2, characterized in that, The semantic coherence score is calculated using the following methods: Input the preceding and following text segments within the sliding window into the pre-trained language model for the contract domain to obtain the preceding semantic vector and the following semantic vector, respectively. The cosine similarity between the preceding and following semantic vectors is calculated as the semantic coherence score, using the following formula: ; in, Indicates the location The semantic coherence score is calculated, with a value range of [-1, 1]. A higher value indicates a stronger semantic connection between the preceding and following text segments. Indicates position The semantic vector of the previous text segment, Indicates position The semantic vector of the subsequent text segment; This represents the L2 norm of a vector.
4. The intelligent identification and assessment method for contractual terms risks according to claim 1, characterized in that, In step S2, the semantic similarity matching includes: Text of each clause Input a pre-trained language model in the contract domain to obtain clause semantic vectors. ; Each risk pattern template in the multi-dimensional risk feature library Input a pre-trained language model in the contract domain to obtain risk pattern semantic vectors. ; The semantic similarity between the semantic vector of a clause and the semantic vectors of each risk pattern is calculated using the following formula: ; in, Indicates the text of the terms and conditions With risk model template The semantic similarity between them, with values ranging from [-1, 1]; When the semantic similarity value exceeds the preset similarity threshold, it is determined that the clause text segment has a corresponding risk pattern, and a risk pattern matching result is generated.
5. The intelligent identification and assessment method for contract clause risks according to claim 4, characterized in that, In step S3, the calculation of the risk level score for the clause includes: The risk severity level is determined based on the type and number of risk patterns in the risk pattern matching results and the structural defect detection results. ; The probability level is determined based on the deviation between the baseline probability corresponding to the legal attribute category and the value of the rights and obligations equivalence index. ; The severity level and probability level of occurrence are used as row and column indices in the two-dimensional risk assessment matrix; The risk level score of a clause is calculated based on a two-dimensional risk assessment matrix. The risk level score is equal to the weighted sum of the risk severity level and the probability of occurrence level, as shown in the formula: ; in, Indicates the text of the terms and conditions The overall risk level score, Indicates severity weight, Represents probability weights, This represents the coefficient of the interaction term.
6. The intelligent identification and assessment method for contract clause risks according to claim 1, characterized in that, In step S2, the structural defect detection includes: Check whether any clauses in the contract text are missing essential contract clauses, which include clauses on the subject matter, price, and performance period. Check whether the key elements in each clause are completely expressed. Key elements include time, amount, subject, and location. The absence of at least one of the essential clauses or incomplete description of key elements will be considered as a structural defect detection result.
7. The intelligent identification and assessment method for contractual terms risks according to claim 1, characterized in that, In step S4, the method for generating the modification suggestion includes: The modification direction label is determined based on the risk pattern matching results of high-risk clauses; Based on the modification direction label, retrieve matching legal provisions from the legal provisions knowledge base; A text generation model is used to generate suggested modification text based on the original text of high-risk clauses and legal provisions; The proposed amendments are linked and annotated with the relevant legal provisions.
8. The intelligent identification and assessment method for contract clause risks according to claim 1, characterized in that, In step S5, the method for generating the negotiation key points list includes: Extract the core points of contention from each high-risk clause; Prioritize the core points of contention based on the risk level rating of the terms; Based on legal provisions and information, we generate negotiation strategy suggestions for each core point of contention. The key points of contention, priorities, and negotiation strategy suggestions are integrated into a list of key negotiation points.
9. A contract clause risk intelligent identification and assessment system, used to implement the method described in any one of claims 1-8, characterized in that, include: The multi-granularity clause parsing module is used to obtain the target contract document to be reviewed. It uses a pre-trained language model in the contract domain to adaptively segment the clause boundaries of the target contract document, obtain the clause boundary segmentation results, and identify the legal attribute category corresponding to each clause text segment. The risk identification module is used to identify risks in each clause text segment in the clause boundary segmentation result based on a multi-dimensional risk feature library. It identifies risk pattern matching results from each clause text segment through semantic similarity matching, and performs structural defect detection on each clause text segment to obtain structural defect detection results. It also calculates the rights and obligations equivalence index value of each clause text segment. The risk assessment module is used to determine the risk severity level of each clause text segment based on the risk pattern matching results and structural defect detection results, determine the occurrence probability level of each clause text segment based on the legal attribute category and the value of the rights and obligations equivalence index, construct a two-dimensional risk assessment matrix based on the risk severity level and the occurrence probability level, and calculate the clause risk level score of each clause text segment. The modification suggestion generation module is used to filter high-risk clauses whose risk level scores exceed a preset risk threshold, search the legal knowledge base for each high-risk clause to obtain matching legal provisions, and automatically generate modification suggestion text based on the legal provisions. The output module is used to generate a contract risk assessment report based on the risk level score of each clause text segment, generate clause annotation data based on risk pattern matching results and modification suggestions, and generate a list of key negotiation points based on high-risk clauses and legal provisions.