A large model-based contract evaluation method, system, device and medium
By adopting a contract evaluation method based on a large model, the automated interpretation of coastal bulk cargo transportation contracts has been achieved, solving the problems of low efficiency of manual interpretation and limited functionality of existing software. This enables efficient and accurate contract risk assessment and benefit calculation, adapting to the contract evaluation needs of different scenarios.
Patent Information
- Application Number
- CN202411224591.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-03
- Publication Date
- 2026-11-27
- Estimated Expiration
- 2044-09-03
AI Technical Summary
The interpretation of coastal bulk cargo transportation contracts relies on manual interpretation, which is time-consuming and labor-intensive, inefficient, and prone to misinterpretation. Existing contract management software cannot deeply analyze the meaning and potential risks of contract terms, resulting in high labor costs and low business turnover.
A large-scale model-based contract evaluation method is adopted. The target contracts are preprocessed, and a large contract language model is used for contract classification, risk assessment, and benefit calculation. This includes the application of optical character recognition, semantic linking, and vector knowledge base to achieve automated contract summary extraction, risk assessment, and benefit calculation.
It significantly saves manpower and time costs, improves the efficiency and accuracy of contract interpretation, reduces misinterpretations and omissions, enhances enterprise operational efficiency, adapts to contract evaluation needs in different scenarios, and promptly identifies compliance risk points.
Smart Images

Figure CN119149742B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of contract evaluation technology, and in particular to a contract evaluation method, system, device and medium based on a large model. Background Technology
[0002] Currently, the interpretation of coastal bulk cargo transportation contracts mainly relies on manual labor. Manual interpretation is time-consuming and labor-intensive, inefficient, and prone to misinterpretation. Furthermore, for complex contract clauses, limitations may arise due to individual experience and professional knowledge. Existing contract management software has relatively limited functionality, only capable of simple storage and retrieval of contracts, and cannot deeply analyze the meaning of contract clauses and potential risks. Therefore, providing a contract evaluation method that can save labor costs and improve business turnover rate has practical application value and significance. Summary of the Invention
[0003] To enable the review and evaluation of coastal bulk cargo transportation contracts using large-scale models, thereby saving labor costs and improving business turnover, this application provides a contract evaluation method, system, equipment, and medium based on large-scale models.
[0004] Firstly, the objective of this invention is achieved through the following technical solution: A contract evaluation method based on a large model includes: The target contract is acquired and preprocessed to obtain preprocessed contract data. The preprocessed contract data is then input into a preset contract language model. The preset contract language model stores a vector knowledge base that includes knowledge of coastal bulk cargo transportation, legal clauses, and industry regulations. In the preset contract language model, the first model agent is used to classify contracts and extract contract summaries from the current preprocessed contract data to obtain contract summary information; the second model agent and the contract summary information are used to conduct contract risk assessment on the current preprocessed contract data to obtain risk assessment information and / or risk avoidance suggestion information; the third model agent is used to calculate the benefits of the current preprocessed contracts to obtain benefit calculation information.
[0005] By adopting the above technical solution, the target contract is the contract data of coastal bulk cargo transportation contracts, which includes original contracts in paper and electronic form. The preset contract language model is a pre-trained large language model. The first model agent is a contract classification model agent, the second model agent is a risk assessment model agent, and the third model agent is a benefit calculation model agent. The contract language model provided in this application enables the review and evaluation of coastal bulk cargo transportation contracts using a large model, achieving the goal of saving labor costs and improving business turnover. Compared with traditional manual interpretation methods, the automated data processing and contract data interpretation process of this invention helps save significant labor and time costs, greatly improving the efficiency and accuracy of contract interpretation and reducing misreading and omissions caused by human factors. Through the pre-trained contract language model, not only can data preprocessing operations on contract data be realized, but also contract summary information extraction, contract risk assessment, and contract benefit calculation can be achieved, which helps improve the operational efficiency of enterprises.
[0006] In a preferred example, the target contract includes both paper and electronic contracts, comprising: When the target contract is a paper contract, optical character recognition technology is used to identify the paper contract as multiple electronic text data. The multiple electronic text data are preprocessed sequentially, and a semantic linking agent is used to link the multiple preprocessed electronic text data identified as the same contract into a coherent target contract text. The process of acquiring the target contract and performing data preprocessing to obtain preprocessed contract data specifically includes: When the target contract is an electronic contract or a target contract text, several preset prompt words are obtained based on the target contract. The semantic linking agent is used to extract key digital information of the target contract by combining the several preset prompt words to obtain key contract data. Based on the aforementioned preset prompts and key contract data, the target contract text and electronic contract are preprocessed to obtain preprocessed contract data.
[0007] By adopting the above technical solution, the semantic linking agent is an agent based on a large model. This application uses optical character recognition (OCR) technology to recognize paper contracts, converting the text in the image into editable electronic text data to form a coherent target contract text. The target text data and electronic contract are preprocessed, including but not limited to word segmentation, part-of-speech tagging, and named entity recognition, to obtain structured preprocessed contract data. This application, through an intelligent contract recognition and processing process, helps to shorten the contract evaluation cycle and improve business turnover rate.
[0008] In a preferred embodiment of this application: the first model agent is a contract classification agent; the step of using the first model agent to classify contracts and extract contract summaries from the current preprocessed contract data in the preset contract language model to obtain contract summary information specifically includes: In the preset contract language model, the contract classification agent and text classification prompts are used to classify the current preprocessed contract data to obtain the current contract type; the preset contract language model is optimized based on the current contract type, and the optimized contract language model is used to extract key contract elements from the current preprocessed contract data to obtain contract summary information.
[0009] By adopting the above technical solutions, the introduction of the contract classification agent can more accurately identify the type of contract. Based on the dynamic optimization of contract type, the contract language model can process different types of contracts more accurately, improve the model's adaptability and generalization ability, and help to make more scientific and reasonable risk avoidance suggestions.
[0010] In a preferred embodiment of this application: the second model agent includes a contract risk assessment agent; the step of using the second model agent and contract summary information to perform contract risk assessment on the current preprocessed contract data to obtain risk assessment information and / or risk avoidance suggestion information specifically includes: In the preset contract language model, based on the current contract type, relevant legal and regulatory information and corresponding requirements and standards are retrieved from the vector knowledge base to obtain risk assessment and avoidance information and corresponding assessment standards. The contract risk assessment agent performs contract risk assessment on the current preprocessed contract data based on the contract summary information, risk assessment and avoidance information and the corresponding assessment criteria, and obtains risk assessment information. And / or, The contract risk assessment intelligence agent assesses the risk points of the current pre-processed contract data based on the contract summary information, risk assessment and avoidance information, and corresponding assessment standards. Based on the assessed risk points, it correlates them with legal provisions and industry regulations to determine the corresponding risk avoidance suggestions.
[0011] By adopting the above technical solutions, risk assessment information and risk avoidance suggestions can be more comprehensively considered based on the current pre-processed contract type and content, taking into account the requirements of laws, regulations and industry provisions. This improves the accuracy and reliability of contract risk assessment. Furthermore, the automated and intelligent contract risk assessment process greatly reduces manual intervention and repetitive work, improves assessment efficiency, and provides strong support for decision-makers with detailed risk assessment information and risk avoidance suggestions.
[0012] In a preferred embodiment of this application: the third model agent includes a benefit calculation agent; the step of using the third model agent to perform benefit calculation on the current preprocessed contract to obtain benefit calculation information specifically includes: In the preset contract language model, the benefit calculation agent extracts the contract content corresponding to the benefit from the current preprocessed contract data, and uses the preset benefit calculation calculator to calculate and evaluate the benefit according to the benefit calculation rules corresponding to the current contract type, thereby obtaining benefit calculation information.
[0013] By adopting the above technical solutions, the benefit calculation agent can more accurately assess the expected benefits of a contract by obtaining benefit calculation information through preset benefit calculation rules, reducing the impact of human error and subjective judgment; the automated and intelligent benefit calculation process greatly shortens the decision-making cycle and improves decision-making efficiency.
[0014] In a preferred embodiment of this application: the vector knowledge base further includes industry practices and historical cases for different contract types; before acquiring the target contract and performing data preprocessing to obtain preprocessed contract data, and inputting the preprocessed contract data into a preset contract language model, the method further includes: Collect contract texts and related background information of different contract types, and use the initial contract language model to perform deep analysis on the contract texts. The deep analysis includes performing entity naming recognition on the contract texts, extracting key contract elements and extracting semantic relationships; constructing a logical relationship diagram between contract elements to form basic contract measurement data. In the initial contract language model, the contract content of the target contract is checked for compliance and classified for compliance risk level based on the vector knowledge base to obtain compliance assessment information; The contract basic measurement data, compliance assessment report, and credit rating of the contract signatory are used as inputs to the initial contract big language model. Combined with the industry characteristics and regional differences corresponding to the target contract, feature vector set for contract risk assessment is constructed through feature engineering. Based on the feature vector set, a deep learning algorithm is used to train and adjust the initial contract language model to obtain the final contract language model.
[0015] By adopting the above technical solution, this application, through implementation steps such as contract data collection and preprocessing, construction of basic contract measurement data, compliance assessment, feature vector set construction, and model training optimization, can more accurately assess the compliance and risk level of contracts. By combining the industry characteristics and regional differences of the target contract for feature engineering, the contract language model can adapt to the contract assessment needs in different scenarios, improve the model's generalization ability, and promptly identify and correct potential compliance risk points in contracts through compliance checks and risk level classification, thereby reducing the enterprise's compliance risk.
[0016] In a preferred embodiment, the deep analysis of the contract text further includes: The contract text is segmented into words, stop words are removed, and word vectors are used to represent it. Specific prompts are preset in the initial contract language model to guide it in understanding the contract context; when performing the named entity recognition task, the initial contract language model identifies key entities and their attributes in the contract. When extracting semantic relationships, the contextual understanding capabilities of the initial contract language model are utilized to construct the logical relationships between contract elements, forming a structured representation of contract information.
[0017] By adopting the above technical solutions, deep parsing techniques such as word segmentation, stop word removal, and word vector representation can more accurately understand and represent key information in contract texts. By pre-setting specific prompts and fine-tuning the initial contract language model, the contract language model becomes more adaptable to the specific needs of contract evaluation, improving the model's adaptability and accuracy. The automated contract parsing and structured representation process greatly shortens the evaluation cycle and improves evaluation efficiency. At the same time, the structured representation of contract information facilitates subsequent automated processing and analysis, and helps reduce errors and biases caused by human factors.
[0018] Secondly, the objective of this invention is achieved through the following technical solution: A contract evaluation system based on a large model, the system comprising: The data preprocessing module is used to acquire the target contract and perform data preprocessing to obtain preprocessed contract data, and input the preprocessed contract data into a preset contract language model; the preset contract language model stores a vector knowledge base including coastal bulk cargo transportation knowledge, legal clauses and industry regulations; The contract classification module is used to classify contracts and extract contract summaries from the current preprocessed contract data using the first model agent in the preset contract language model, so as to obtain contract summary information. The risk assessment and benefit calculation module is used to perform contract risk assessment on the current pre-processed contract data using the second model agent and contract summary information, and obtain risk assessment information and / or risk avoidance suggestion information; and to perform benefit calculation on the current pre-processed contract using the third model agent, and obtain benefit calculation information.
[0019] By adopting the above technical solution, the target contract is the contract data of coastal bulk cargo transportation contracts, which includes original contracts in paper and electronic form. The preset contract language model is a pre-trained large language model. The first model agent is a contract classification model agent, the second model agent is a risk assessment model agent, and the third model agent is a benefit calculation model agent. The contract language model provided in this application enables the review and evaluation of coastal bulk cargo transportation contracts using a large model, achieving the goal of saving labor costs and improving business turnover. Compared with traditional manual interpretation methods, the automated data processing and contract data interpretation process of this invention helps save significant labor and time costs, greatly improving the efficiency and accuracy of contract interpretation and reducing misreading and omissions caused by human factors. Through the pre-trained contract language model, not only can data preprocessing operations on contract data be realized, but also contract summary information extraction, contract risk assessment, and contract benefit calculation can be achieved, which helps improve the operational efficiency of enterprises.
[0020] Thirdly, the objective of this invention is achieved through the following technical solution: A computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the aforementioned contract evaluation method based on a large model.
[0021] Fourthly, the objective of this invention is achieved through the following technical solution: A computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the aforementioned contract evaluation method based on a large model.
[0022] In summary, this application includes at least one of the following beneficial technical effects: 1. The target contracts are coastal bulk cargo transportation contracts, including original contracts in both paper and electronic formats. The pre-set contract language model is a pre-trained large language model. The first model agent is a contract classification model agent, the second model agent is a risk assessment model agent, and the third model agent is a benefit calculation model agent. The contract language model provided in this application enables the review and evaluation of coastal bulk cargo transportation contracts using a large model, thereby saving labor costs and improving business turnover. Compared with traditional manual interpretation methods, the automated data processing and contract data interpretation process of this invention helps save significant labor and time costs, greatly improving the efficiency and accuracy of contract interpretation and reducing misreading and omissions caused by human factors. Through the pre-trained contract language model, not only can data preprocessing of contract data be achieved, but also contract summary information extraction, contract risk assessment, and contract benefit calculation can be realized, which helps improve the operational efficiency of enterprises. 2. Through contract data collection and preprocessing, the construction of basic contract measurement data, compliance assessment, feature vector set construction, and model training optimization, the compliance and risk level of contracts can be assessed more accurately. Feature engineering is carried out in combination with the industry characteristics and regional differences of the target contracts, so that the contract language model can adapt to the contract assessment needs in different scenarios, improve the generalization ability of the model, and timely identify and correct potential compliance risk points in contracts through compliance checks and risk level classification, thereby reducing the compliance risk of enterprises. 3. By adopting the above technical solutions, deep parsing techniques such as word segmentation, stop word removal, and word vector representation can more accurately understand and represent key information in contract texts. By pre-setting specific prompts and fine-tuning the initial contract language model, the contract language model becomes more adaptable to the specific needs of contract evaluation, improving the model's adaptability and accuracy. The automated contract parsing and structured representation process greatly shortens the evaluation cycle and improves evaluation efficiency. At the same time, the structured representation of contract information facilitates subsequent automated processing and analysis, and helps reduce errors and biases caused by human factors. Attached Figure Description
[0023] Figure 1 This is a flowchart of a contract evaluation method based on a large model in one embodiment of this application; Figure 2 This is a flowchart before step S1 in a contract evaluation method based on a large model according to an embodiment of this application; Figure 3 This is a schematic diagram of a device according to one embodiment of this application. Detailed Implementation
[0024] The present application will be further described in detail below with reference to the accompanying drawings.
[0025] In one embodiment, such as Figure 1 As shown, this application discloses a contract evaluation method based on a large model, which specifically includes the following steps: S1: Obtain the target contract and perform data preprocessing to obtain preprocessed contract data. Input the preprocessed contract data into the preset contract language model. The preset contract language model stores a vector knowledge base including coastal bulk cargo transportation knowledge, legal clauses, and industry regulations.
[0026] In this embodiment, data preprocessing includes, but is not limited to, document format conversion, text cleaning, word segmentation and vectorization, part-of-speech tagging, and named entity recognition. Document format conversion converts the contract document into a text format, such as a paper contract, which requires the use of optical character recognition technology for conversion. Text cleaning includes removing irrelevant information from the text, such as headers, footers, page numbers, and annotations, while correcting typos and formatting errors. Word segmentation and vectorization involve segmenting the cleaned text and using a pre-trained word embedding model (such as BERT, GPT, etc.) to convert the segmentation results into vector representations for subsequent model processing.
[0027] S2: In the preset contract language model, the first model agent is used to classify contracts and extract contract summaries from the current preprocessed contract data to obtain contract summary information; the second model agent and the contract summary information are used to conduct contract risk assessment on the current preprocessed contract data to obtain risk assessment information and / or risk avoidance suggestion information; the third model agent is used to calculate the benefits of the current preprocessed contracts to obtain benefit calculation information.
[0028] In this embodiment, the contract language model incorporates a built-in classification algorithm. The contracts in this embodiment include various different types; for example, coastal bulk cargo transportation contracts include long-term freight shipper contracts, long-term freight carrier contracts, single-shipment freight shipper contracts, and single-shipment freight carrier contracts. The contract language model in this application is the llama3 model, trained on a self-made LoRa dataset. When defining the LoRa module, it is essential to closely consider the textual characteristics of coastal bulk cargo transportation contracts and the specific requirements of the summarization task. Careful consideration should be given to which layers of the model to add trainable parameters to most effectively improve the model's ability to capture key information from such contract texts and the quality of its summary generation. For example, the Lora module can be introduced into layers closely related to semantic understanding and information extraction to achieve accurate grasp of the core content of the contract. During model training, a relatively small value can be tried in the initial stage, such as 1e-4, and then flexibly adjusted according to the model's performance and convergence during the training process. The Adam optimizer is used. When optimizing the model during training, by calculating the loss value, the model can clearly understand the gap between itself and the expected output, and gradually adjust the parameters of the Lora module with the help of the optimizer, thereby continuously improving the ability and quality of summary generation.
[0029] In one embodiment, a contract evaluation method based on a large model includes: S10: When the target contract is a paper contract, optical character recognition technology is used to identify the paper contract as multiple electronic text data. The multiple electronic text data are preprocessed sequentially, and the semantic linking agent is used to link the multiple preprocessed electronic text data identified as the same contract into a coherent target contract text.
[0030] In this embodiment, high-precision optical character recognition (OCR) technology is used to scan paper contracts and convert the text in the image into editable electronic text data. Then, the converted electronic text data is cleaned, including removing noise, correcting OCR recognition errors, and unifying the format, in order to improve the accuracy of subsequent processing.
[0031] In step S1, the target contract is acquired and data preprocessing is performed to obtain preprocessed contract data, specifically including: S11: When the target contract is an electronic contract or a target contract text, obtain several preset prompt words based on the target contract, and use a semantic linking agent to extract key digital information of the target contract in combination with several preset prompt words to obtain key contract data.
[0032] In this embodiment, a semantic linking agent (a large model-based agent) is used to analyze the semantic relationships between multiple electronic text data, identify and merge multiple text fragments belonging to the same contract, and form a coherent target contract text.
[0033] S12: Based on several preset prompts and key contract data, perform data preprocessing on the target contract text and electronic contract to obtain preprocessed contract data.
[0034] In this embodiment, the preset prompt words include prompt words covering the key elements of the contract, including contract type, signing date, amount, and information of both parties; by using a semantic linking agent in combination with the preset prompt words, key numerical information (such as amount, date, etc.) in the contract is extracted through natural language processing (NLP) technology to form key contract data.
[0035] Specifically, data preprocessing includes, but is not limited to, word segmentation, part-of-speech tagging, and named entity recognition, in order to obtain structured preprocessed contract data.
[0036] In one embodiment, in step S2, the first model agent is a contract classification agent; in a preset contract language model, the first model agent is used to classify contracts and extract contract summaries from the current preprocessed contract data to obtain contract summary information, specifically including: S201: In the preset contract language model, the contract classification agent and text classification prompts are used to classify the current preprocessed contract data to obtain the current contract type; the preset contract language model is optimized based on the current contract type, and the optimized contract language model is used to extract the key elements of the current preprocessed contract data to obtain contract summary information.
[0037] In this embodiment, the contract classification agent is responsible for the task of classifying contracts. By preparing or training a set of text classification prompts for the contract classification agent, these text classification prompts are used to guide the model to understand and identify different contract types. Then, based on the current contract type obtained from the classification, the parameters or weights of the preset contract language model are dynamically adjusted so that it focuses more on processing contract text of that type.
[0038] Specifically, the Contract Language Model automatically extracts key elements from the contract by understanding its semantics and structure, such as information about the contracting parties, description of the subject matter, amount, term, and liability for breach of contract, forming a contract summary, which is then output in a structured form.
[0039] Furthermore, the optimization process of the contract classification agent and the large language model can be dynamic, meaning that the model can continuously learn and improve as new contracts are added and evaluated. A domain knowledge base for the model can also be established, that is, a specialized knowledge base for the contract domain can be established to assist the model in understanding and processing professional terms and complex clauses in contract texts.
[0040] In one embodiment, in step S2, the second model agent includes a contract risk assessment agent; using the second model agent and contract summary information, a contract risk assessment is performed on the current preprocessed contract data to obtain risk assessment information and / or risk avoidance suggestion information, specifically including: S211: In the pre-defined contract language model, based on the current contract type, relevant legal and regulatory information and corresponding requirements and standards are retrieved from the vector knowledge base to obtain risk assessment and avoidance information and corresponding assessment standards.
[0041] In this embodiment, the vector knowledge base should include rich information such as legal and regulatory texts, judicial interpretations, industry standards, and historical cases, and this information has been processed through vectorization technology to facilitate rapid matching and querying in the future.
[0042] Specifically, the search results in the vector knowledge base are used to filter out legal and regulatory information and corresponding requirements and standards that are directly related to the current contract type, forming a set of risk assessment and avoidance information and assessment standards.
[0043] S212: The contract risk assessment agent performs contract risk assessment on the current pre-processed contract data based on contract summary information, risk assessment and avoidance information and corresponding assessment standards, and obtains risk assessment information.
[0044] In this embodiment, contract risk assessment includes: inputting contract summary information (including key contract elements, clauses, etc.) into the contract risk assessment intelligent agent; combining risk assessment avoidance information and corresponding assessment standards, the contract risk assessment intelligent agent conducts in-depth analysis of the contract summary information; and then, based on the analysis results of the in-depth analysis, the contract risk assessment intelligent agent generates risk assessment information, including but not limited to risk type, risk level, potential impact, etc.
[0045] And / or, S213: The contract risk assessment agent assesses the risk points of the current pre-processed contract data based on contract summary information, risk assessment and avoidance information, and corresponding assessment standards. Based on the assessed risk points, it correlates them with legal provisions and industry regulations to determine the corresponding risk avoidance suggestions.
[0046] In this embodiment, based on the risk assessment, the specific risk points in the contract are further assessed, namely, a detailed interpretation of the contract terms and a comparison with laws, regulations, and industry rules. For several identified risk points, the contract risk assessment agent searches for relevant legal provisions and industry rules in the vector knowledge base, performs correlation analysis, and then generates risk avoidance suggestions based on the results of the correlation analysis, including suggestions for modifying contract terms, compliance suggestions, and risk response strategies.
[0047] In one embodiment, the third model agent includes a benefit calculation agent; the third model agent is used to calculate the benefit of the current preprocessed contract to obtain benefit calculation information, specifically including: S221: In the preset contract language model, the benefit calculation agent extracts the contract content corresponding to the benefit from the current preprocessed contract data, and uses the preset benefit calculation calculator to calculate and evaluate the benefit according to the benefit calculation rules corresponding to the current contract type, so as to obtain benefit calculation information.
[0048] In this embodiment, the benefit calculation agent is trained to identify and understand key benefit-related content in the contract text, such as contract amount, payment method, service period, and expected revenue.
[0049] Specifically, the benefit calculation agent performs in-depth analysis of the current pre-processed contract data, using Natural Language Processing (NLP) technology to extract contract content directly corresponding to the benefits. Then, based on the current contract type, it searches for the corresponding benefit calculation rules in a pre-set benefit calculation calculator. These rules may vary depending on factors such as contract type, industry characteristics, and regional differences, and must ensure a complete match between the benefit calculation rules and the current contract type for accurate benefit calculation. The extracted contract content corresponding to the benefits is then input into the pre-set benefit calculation calculator. The calculator performs numerical calculations and financial analysis on the contract content according to the matched benefit calculation rules to assess the expected benefits of the contract and generate benefit calculation information, including but not limited to key indicators such as expected revenue, cost recovery period, and return on investment.
[0050] Furthermore, the benefit calculation agent needs to be trained with a large amount of contract text data to improve its ability to identify contract content related to benefits; the preset benefit calculation rule base needs to be updated and maintained regularly to reflect the impact of market changes, policy adjustments and other factors on benefit calculation, and a flexible rule configuration mechanism should be established to allow for customized adjustments based on different contract types and customer needs.
[0051] In one embodiment, such as Figure 2 As shown, the vector knowledge base also includes industry practices and historical cases for different contract types. Before step S1, a contract evaluation method based on a large model also includes: S11: Collect contract texts and related background information of different contract types, and use the initial contract language model to perform in-depth analysis of the contract texts. In-depth analysis includes performing entity naming and recognition on the contract texts, extracting key contract elements and extracting semantic relationships; constructing a logical relationship diagram between contract elements to form basic contract measurement data.
[0052] In this embodiment, contract texts of different contract types include, but are not limited to, sales contracts, purchase contracts, lease contracts, and service contracts.
[0053] Specifically, the initial contract language model is used to perform in-depth analysis of the cleaned contract text, including entity naming and identification (identifying the parties in the contract), extracting key contract elements (such as contract amount, performance period, liability for breach of contract, etc.) and extracting semantic relationships (understanding the logical relationships between the elements); a logical association diagram is used to show the dependencies and constraints between the elements, and the logical association diagram is transformed into quantifiable basic contract metrics, such as the frequency of occurrence of key elements and the complexity of semantic relationships, providing a basis for subsequent evaluation.
[0054] S12: In the initial contract language model, the content of the target contract is checked for compliance and classified for compliance risk level based on the vector knowledge base to obtain compliance assessment information.
[0055] Specifically, in the initial contract language model, industry practices and historical case information from the vector knowledge base are integrated. Then, the contract content of the target contract is checked for compliance, compared with the compliance standards in the vector knowledge base, and potential compliance risk points are identified. Then, based on the severity and probability of occurrence of the compliance risk points, the target contract is classified into compliance risk levels, and a compliance assessment report is generated.
[0056] S13: Using basic contract measurement data, compliance assessment reports, and credit ratings of contract signatories as inputs to the initial contract big language model, and combining the industry characteristics and regional differences corresponding to the target contract, feature vector sets for contract risk assessment are constructed through feature engineering.
[0057] Specifically, feature engineering includes steps such as data normalization, feature selection, and feature dimensionality reduction. It uses basic contract measurement data, compliance assessment reports, and credit ratings of contract signatories as input data, and combines the industry characteristics and regional differences corresponding to the target contract to construct a feature vector set for contract risk assessment through feature engineering.
[0058] S14: Based on the feature vector set, use deep learning algorithms to train and adjust the initial contract language model to obtain the final contract language model.
[0059] Specifically, deep learning algorithms include LSTM and BERT. During training, model parameters are continuously adjusted and optimized through techniques such as cross-validation and hyperparameter tuning to improve the model's accuracy and generalization ability. At the same time, the trained model is evaluated using a test set to verify its performance in practical applications. Based on the evaluation results, the model is further adjusted and optimized until satisfactory performance is achieved.
[0060] In an embodiment, the deep parsing of the contract text in step S11 further includes: S111: Perform word segmentation on the contract text, remove stop words, and represent the words as word vectors.
[0061] In this embodiment, the word segmentation process obtains contract vocabulary units. Stop words such as "的", "了", "在" existing in the contract vocabulary units after word segmentation are removed to reduce data redundancy and improve processing efficiency.
[0062] Specifically, the words after word segmentation and stop word removal are converted into vector representations in a high-dimensional space, which can be implemented through pre-trained word embedding models (such as Word2Vec, GloVe, or the embedding layer of BERT) to capture semantic relationships between words.
[0063] S112: Preset specific prompts in the initial contract large language model to guide the initial contract large language model to understand the contract context; when performing the named entity recognition task, the initial contract large language model identifies key entities and their attributes in the contract.
[0064] In this embodiment, the configuration of the initial contract large language model includes presetting specific prompts and model fine-tuning. The preset specific prompts refer to presetting a series of specific prompts or guiding languages related to contract evaluation in the initial contract large language model to help the model better understand the contract context, such as "Please analyze the key clauses in the following contract text" and "Please pay attention to identifying the parties and entities in the contract and their relationships". The model fine-tuning includes fine-tuning the initial contract large language model according to the preset prompts and the specific requirements of contract evaluation for different contract types. The model fine-tuning includes retraining partial parameters based on a large number of contract text datasets, so that the accuracy of the model in contract evaluation tasks meets the requirements.
[0065] S113: When performing semantic relationship extraction, use the context understanding capability of the initial contract large language model to construct logical relationships between contract elements and form a structured representation of contract information.
[0066] In this embodiment, the logical relationships include dependency relationships, causal relationships, and parallel relationships between contract elements. The relationship extraction includes extracting the semantic relationships between contract elements based on the results of context understanding and representing them in a structured form. The structured representation forms include graph structures or tables of entities, attributes, and relationships, which can intuitively display contract information.
[0067] It should be understood that the size of the sequence number of each step in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and does not constitute any limitation on the implementation process of the embodiments of the present application.
[0068] In one embodiment, a large-model-based contract evaluation system is provided, which corresponds to a large-model-based contract evaluation method in the above embodiments.
[0069] A contract evaluation system based on a large model includes a data preprocessing module, a contract classification module, and a risk assessment and benefit calculation module. Detailed descriptions of each functional module are as follows: The data preprocessing module is used to acquire the target contract and perform data preprocessing to obtain preprocessed contract data. The preprocessed contract data is then input into a preset contract language model. The preset contract language model stores a vector knowledge base that includes knowledge of coastal bulk cargo transportation, legal clauses, and industry regulations. The contract classification module is used to classify contracts and extract contract summaries from the current preprocessed contract data using the first model agent in the preset contract language model, so as to obtain contract summary information. The risk assessment and benefit calculation module is used to perform contract risk assessment on the current pre-processed contract data using the second model agent and contract summary information, and obtain risk assessment information and / or risk avoidance suggestion information; and to perform benefit calculation on the current pre-processed contract using the third model agent, and obtain benefit calculation information.
[0070] For specific limitations regarding a contract evaluation system based on a large model, please refer to the limitations of a contract evaluation method based on a large model mentioned above, which will not be repeated here. Each module in the aforementioned contract evaluation system based on a large model can be implemented entirely or partially through software, hardware, or a combination thereof. Each module can be embedded in or independent of the processor in a computer device in hardware form, or it can be stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.
[0071] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows: Figure 3As shown, the computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and database. The internal memory provides the environment for the operation of the operating system and computer programs in the non-volatile storage media. The database stores a large contract language model, contract summary information, risk assessment information, and benefit calculation information. The network interface communicates with external terminals via a network connection. When executed by the processor, the computer program implements a contract evaluation method based on a large model.
[0072] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement steps of a contract evaluation method based on a large model.
[0073] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the steps of a contract evaluation method based on a large model.
[0074] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0075] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0076] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A contract evaluation method based on a large model, characterized in that, include: The target contract is acquired and preprocessed to obtain preprocessed contract data. The preprocessed contract data is then input into a preset contract language model. The preset contract language model stores a vector knowledge base that includes knowledge of coastal bulk cargo transportation, legal clauses, and industry regulations. In the preset contract language model, the first model agent is used to classify contracts and extract contract summaries from the current preprocessed contract data to obtain contract summary information. Using the second model agent and contract summary information, a contract risk assessment is performed on the current pre-processed contract data to obtain risk assessment information and / or risk avoidance suggestions; using the third model agent, a benefit calculation is performed on the current pre-processed contract to obtain benefit calculation information. The vector knowledge base also includes industry practices and historical cases for different contract types. Before acquiring the target contract and performing data preprocessing to obtain preprocessed contract data, and before inputting the preprocessed contract data into the preset contract language model, the process further includes: Collect contract texts and related background information of different contract types, and use the initial contract language model to perform deep analysis on the contract texts. The deep analysis includes performing entity naming recognition on the contract texts, extracting key contract elements and extracting semantic relationships; constructing a logical relationship diagram between contract elements to form basic contract measurement data. In the initial contract language model, the contract content of the target contract is checked for compliance and classified for compliance risk level based on the vector knowledge base to obtain compliance assessment information; The contract basic measurement data, compliance assessment report, and credit rating of the contract signatory are used as inputs to the initial contract big language model. Combined with the industry characteristics and regional differences corresponding to the target contract, feature vector set for contract risk assessment is constructed through feature engineering. Based on the feature vector set, a deep learning algorithm is used to train and adjust the initial contract language model to obtain the final contract language model.
2. The contract evaluation method based on a large model according to claim 1, characterized in that, The target contracts include both paper and electronic contracts, including: When the target contract is a paper contract, optical character recognition technology is used to identify the paper contract as multiple electronic text data. The multiple electronic text data are preprocessed sequentially, and a semantic linking agent is used to link the multiple preprocessed electronic text data identified as the same contract into a coherent target contract text. The process of acquiring the target contract and performing data preprocessing to obtain preprocessed contract data specifically includes: When the target contract is an electronic contract or a target contract text, several preset prompt words are obtained based on the target contract. The semantic linking agent is used to extract key digital information of the target contract by combining the several preset prompt words to obtain key contract data. Based on the aforementioned preset prompts and key contract data, the target contract text and electronic contract are preprocessed to obtain preprocessed contract data.
3. The contract evaluation method based on a large model according to claim 1, characterized in that, The first model agent is a contract classification agent; the step of using the first model agent to classify contracts and extract contract summaries from the current preprocessed contract data in the preset contract language model to obtain contract summary information specifically includes: In the preset contract language model, the contract classification agent and text classification prompts are used to classify the current preprocessed contract data to obtain the current contract type; the preset contract language model is optimized based on the current contract type, and the optimized contract language model is used to extract key contract elements from the current preprocessed contract data to obtain contract summary information.
4. The contract evaluation method based on a large model according to claim 3, characterized in that, The second model agent includes a contract risk assessment agent; the step of using the second model agent and contract summary information to perform contract risk assessment on the current preprocessed contract data, and obtaining risk assessment information and / or risk avoidance suggestion information, specifically includes: In the preset contract language model, based on the current contract type, relevant legal and regulatory information and corresponding requirements and standards are retrieved from the vector knowledge base to obtain risk assessment and avoidance information and corresponding assessment standards. The contract risk assessment agent performs contract risk assessment on the current preprocessed contract data based on the contract summary information, risk assessment and avoidance information and the corresponding assessment criteria, and obtains risk assessment information. And / or, The contract risk assessment intelligence agent assesses the risk points of the current pre-processed contract data based on the contract summary information, risk assessment and avoidance information, and corresponding assessment standards. Based on the assessed risk points, it correlates them with legal provisions and industry regulations to determine the corresponding risk avoidance suggestions.
5. The contract evaluation method based on a large model according to claim 3, characterized in that, The third model agent includes a benefit calculation agent; The process of using a third-model intelligent agent to calculate the benefits of the current preprocessed contract and obtaining benefit calculation information specifically includes: In the preset contract language model, the benefit calculation agent extracts the contract content corresponding to the benefit from the current preprocessed contract data, and uses the preset benefit calculation calculator to calculate and evaluate the benefit according to the benefit calculation rules corresponding to the current contract type, thereby obtaining benefit calculation information.
6. The contract evaluation method based on a large model according to claim 1, characterized in that, The in-depth analysis of the contract text also includes: The contract text is segmented into words, stop words are removed, and word vectors are used to represent it. Specific prompts are preset in the initial contract language model to guide it in understanding the contract context; when performing the named entity recognition task, the initial contract language model identifies key entities and their attributes in the contract. When extracting semantic relationships, the contextual understanding capabilities of the initial contract language model are utilized to construct the logical relationships between contract elements, forming a structured representation of contract information.
7. A contract evaluation system based on a large model, characterized in that, The system includes: The data preprocessing module is used to acquire the target contract and perform data preprocessing to obtain preprocessed contract data, and input the preprocessed contract data into a preset contract language model; the preset contract language model stores a vector knowledge base including coastal bulk cargo transportation knowledge, legal clauses and industry regulations; The contract classification module is used to classify contracts and extract contract summaries from the current preprocessed contract data using the first model agent in the preset contract language model, so as to obtain contract summary information. The risk assessment and benefit calculation module is used to perform contract risk assessment on the current pre-processed contract data using the second model agent and contract summary information, and obtain risk assessment information and / or risk avoidance suggestion information; and to perform benefit calculation on the current pre-processed contract using the third model agent, and obtain benefit calculation information. The vector knowledge base also includes industry practices and historical cases for different contract types. Before acquiring the target contract and performing data preprocessing to obtain preprocessed contract data, and before inputting the preprocessed contract data into the preset contract language model, the following steps are also included: Collect contract texts and related background information of different contract types, and use the initial contract language model to perform deep analysis on the contract texts. The deep analysis includes performing entity naming recognition on the contract texts, extracting key contract elements and extracting semantic relationships; constructing a logical relationship diagram between contract elements to form basic contract measurement data. In the initial contract language model, the contract content of the target contract is checked for compliance and classified for compliance risk level based on the vector knowledge base to obtain compliance assessment information; The contract basic measurement data, compliance assessment report, and credit rating of the contract signatory are used as inputs to the initial contract big language model. Combined with the industry characteristics and regional differences corresponding to the target contract, feature vector set for contract risk assessment is constructed through feature engineering. Based on the feature vector set, a deep learning algorithm is used to train and adjust the initial contract language model to obtain the final contract language model.
8. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the contract evaluation method based on a large model as described in any one of claims 1 to 6.
9. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of a contract evaluation method based on a large model as described in any one of claims 1 to 6.
Citation Information
Patent Citations
Automatic classification and evaluation system for contract types in supply chain financial scene
CN115375496A
Contract review method and device, electronic equipment and storage medium
CN117909499A
Contract risk detection method and device based on large language model
CN118484529A
