Case intelligent generation method based on judicial knowledge field map
By using an intelligent generation method based on judicial knowledge graphs, multi-trial legal documents are analyzed and deep learning models are applied to generate efficient and accurate judgment documents. This solves the problems of time-consuming and error-prone judgment document generation, achieves the integrity and consistency of document content, and provides convenient reference for legal professionals.
Patent Information
- Application Number
- CN202411544272.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-31
- Publication Date
- 2025-12-09
- Estimated Expiration
- 2044-10-31
AI Technical Summary
The process of generating judgments is time-consuming and prone to human error. Manual processing is inefficient and makes it difficult to maintain consistency and legal accuracy, especially in the case of multi-trial cases where it is difficult to efficiently link historical cases and legal provisions.
Based on the judicial knowledge domain graph, the system constructs a judicial knowledge graph, analyzes multi-trial legal documents, applies a segmented rule extraction algorithm and a deep learning model to generate the judgment summary, combines a convolutional neural network to optimize the judgment summary, and automatically generates related indexes to form a complete judgment document.
It has improved the efficiency and accuracy of generating judgments, ensured the completeness and consistency of content, provided legal basis for judgments, realized intelligent association between judgments and historical cases, and improved the accuracy and efficiency of case handling.
Smart Images

Figure CN119443249B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of legal text generation, and particularly relates to a case intelligent generation method based on a judicial knowledge field graph. BACKGROUND
[0002] In modern judicial practice, the generation of adjudication documents is a complex and time-intensive process. In particular, in the handling of multi-hearing cases and the writing of adjudication reasons, the traditional document writing process relies on the in-depth analysis of case facts and the application of legal provisions by judges and legal workers. This not only consumes time but also easily introduces errors due to human factors. At the same time, with the increase in the number of cases, the efficiency of manual processing of documents has become increasingly prominent. In particular, when it is necessary to associate and compare the current case with a large number of historical cases and legal provisions, the task becomes particularly difficult. In addition, manually generated documents also face challenges in maintaining content consistency, completeness, and legal accuracy, and often need to be revised multiple times to meet court submission standards.
[0003] Therefore, it is necessary to develop a case intelligent generation method based on a judicial knowledge field graph to solve the above problems. SUMMARY
[0004] Based on the above purpose, the present application provides a case intelligent generation method based on a judicial knowledge field graph.
[0005] The case intelligent generation method based on a judicial knowledge field graph comprises the following steps:
[0006] S1: constructing a judicial knowledge field graph, wherein the judicial knowledge field graph comprises information of case types, trial procedures, adjudication basis, and judgment results;
[0007] S2: analyzing the input multi-hearing legal document, extracting the case facts and adjudication reasons part of the document, and marking the newly added facts in the multi-hearing case;
[0008] S3: based on the judicial knowledge field graph constructed in S1 and the document information extracted in S2, applying a segmented rule extraction algorithm to classify and split the case facts of the document, and generating a preliminary basic case summary;
[0009] S4: using a BERT+LSTM model for deep learning generative summary on the adjudication reasons part extracted in S2, obtaining the adjudication reasons and adjudication gist part;
[0010] S5: combining the judicial knowledge field graph of S1 and the adjudication reasons and adjudication gist generated in S4, performing content association and comparison, and checking the completeness and accuracy thereof;
[0011] S6: Using the results of the correlation comparison in S5, optimize the judgment gist through a convolutional neural network model, and enhance the legal logic and applicability of the judgment gist to case types;
[0012] S7: Based on the optimized judgment gist in S6, automatically generate an association index with other historical cases according to the relevance analysis in the judicial knowledge field graph;
[0013] S8: The results of S3, S4, S6 and S7 are summarized, spliced into a complete case document, and formatted to meet the standard output requirements of judicial documents.
[0014] Optionally, S1 specifically includes:
[0015] S11: Obtain historical judgment documents from existing judicial databases, including first instance judgment documents, second instance judgment documents and retrial judgment documents, wherein the data source is a public judicial database;
[0016] S12: Data preprocessing is performed on the obtained judgment documents, including data format standardization, redundant information cleaning and abnormal data elimination;
[0017] S13: Based on the preprocessed data, a graph structure algorithm is applied to construct a judicial knowledge field graph, taking case types as nodes, case trial procedures, judgment basis and judgment results as edges, forming a directed graph connecting different case types;
[0018] S14: Labeling processing is performed on the nodes and edges in the graph, including the case type corresponding to each node, the trial procedure corresponding to each edge, and the relevant information of the judgment basis and the judgment result.
[0019] Optionally, S2 specifically includes:
[0020] S21: Text segmentation is performed on the input multi-instance legal document, and the case fact part and the judgment reason part in the document are preliminarily divided according to the fixed legal document format based on natural language processing technology, wherein the division standard includes paragraph identification, legal terminology and common document structure;
[0021] S22: Using named entity recognition technology to extract predetermined elements from the document, including case facts such as involved persons, time, place, case type and dispute focus;
[0022] S23: Based on word frequency analysis and semantic analysis, the content of the judgment reason part is extracted, including judgment basis, legal analysis and judgment points;
[0023] S24: Comparing and analyzing the documents of multi-audit cases, marking the newly added case facts and adjudication reasons in the second instance or retrial documents based on timestamp information and semantic similarity calculation, and ensuring that no information is missed in the multi-audit documents.
[0024] Optionally, the S3 specifically comprises:
[0025] S31: Obtaining the document information extracted in S2, including case facts and adjudication reasons, and preliminarily classifying the documents according to case types, trial procedures, and adjudication bases, and the specific classification basis is provided by the nodes and edges in the judicial knowledge field graph constructed in S1;
[0026] S32: Applying a segmented rule extraction algorithm to classify case facts, and the segmented rule extraction algorithm classifies based on the fixed paragraph structure of the document and the legal terminology set;
[0027] S33: Classifying and storing the paragraphs that meet the rules in S32 according to categories, and the classified case fact information includes case occurrence time, party identity, and elements of litigation request
[0028] S34: Splitting the classified case fact information, and dividing each case fact into specific events, dispute focuses, and evidence points according to different case types and trial procedures;
[0029] S35: Based on the results of classification and splitting, generating a preliminary basic case summary, and the case summary includes the main facts of the case, the dispute focuses, and the related evidence description, and is formatted according to the standardized template.
[0030] Optionally, the S32 specifically comprises:
[0031] S321: Defining a set of rules, wherein each rule corresponds to a type of case fact;
[0032] S322: Converting the input document paragraphs into vector representations of words through word embedding technology, specifically converting each word in each paragraph into a corresponding numerical representation, and averaging the vectors of all words in the paragraph to obtain the vector representation of the entire paragraph;
[0033] S323: For each paragraph, compare its vector representation with the vector representation of the pre-defined rules, and calculate the similarity between the paragraph and each rule, the higher the similarity, the closer the paragraph is to the rule;
[0034] S324: According to the calculated similarity, classify the paragraph into the category corresponding to the rule with the highest similarity.
[0035] Optionally, the S4 specifically comprises:
[0036] S41: Preprocess the extracted judgment reason text in S2, and divide the text into sentences and paragraphs;
[0037] S42: Input each sentence into the BERT model, encode the words in each sentence, and generate word vector representation with context correlation;
[0038] S43: Input the vector of each sentence generated by BERT into the LSTM model to capture the context dependency between sentences;
[0039] S44: When the LSTM has processed all the sentences, use the attention mechanism to generate the summary, which explicitly contributes to the summary by weighting the hidden state of each sentence, and generate the summary content;
[0040] S45: Generate the summary of the judgment reason and the gist of the judgment by the decoder according to the hidden state of the LSTM.
[0041] Optionally, the S5 specifically includes:
[0042] S51: Preliminary match the judgment reason and the gist of the judgment generated in S4 with the historical cases in the judicial knowledge field graph constructed in S1, extract the relevant historical case information based on the nodes of case type, judgment basis and judgment result in the graph;
[0043] S52: Semantically match the judgment reason generated in S4 with the judgment reason of the same type of case in the graph, and ensure that the generated judgment reason is consistent with the existing legal provisions and historical judgment logic by calculating the similarity between them;
[0044] S53: Compare the gist of the judgment, based on the historical case data extracted from the graph, use the semantic similarity algorithm to compare the generated gist of the judgment with the historical judgment gist, and determine whether the gist of the judgment covers all legal points;
[0045] S54: Check the integrity and accuracy of the judgment reason and the gist of the judgment through the results of the association comparison, if there are omissions or inconsistencies in the comparison, it will be marked, and based on the legal provisions and historical case information in the graph, generate the corresponding correction suggestions;
[0046] S55: Finally generate a verification report, output the comparison results and correction suggestions, and adjust the generated judgment reason and the gist of the judgment according to the verification results.
[0047] Optionally, the S6 specifically includes:
[0048] S61: Take the revised suggestion after the comparison of the judgment gist generated in S5 as input, and convert the judgment gist text into a word vector sequence through word embedding technology, where each word is converted into a corresponding numerical representation, forming a series of word vectors;
[0049] S62: Input the word vector sequence into the convolution layer of the convolutional neural network, and the convolution layer extracts local features from the word vector sequence through a sliding convolution kernel to identify important word combinations and expression patterns in the judgment gist;
[0050] S63: The output of the convolution layer is processed by the pooling layer, and the pooling operation extracts the most important features from the convolution results;
[0051] S64: The features after the pooling processing are passed to the fully connected layer, in which all local features are integrated into global features, and all extracted features are integrated to generate the final feature representation of the judgment gist;
[0052] S65: Based on the final feature representation, it is determined whether the judgment gist conforms to the legal logic and language specifications, and if it does not conform to the standard, a modification suggestion is fed back; if it conforms to the standard, an optimized final judgment gist text is generated.
[0053] Optionally, S7 specifically includes:
[0054] S71: Match the optimized judgment gist in S6 with historical cases in the judicial knowledge field graph;
[0055] S72: Calculate the similarity between the optimized judgment gist and the gist of the historical cases in the graph, convert the words in the judgment gist into vector representation based on the word vector model, and then calculate the semantic similarity between the gist text and the historical case text;
[0056] S73: Filter the relevant historical cases matched, and evaluate the correlation strength between different historical cases according to the correlation weight in the graph;
[0057] S74: Generate a correlation index, specifically correlate the current judgment gist with the filtered historical cases, and display the case type, judgment result and correlation information in the graph of each historical case through the correlation index;
[0058] S75: According to the generated correlation index, output an index report, which includes the correlation details of the current case and the historical cases, the relevance score and the summary information of the historical cases.
[0059] Optionally, S8 specifically includes:
[0060] S81: Obtain the basic case summary from S3, extract the core facts of the case, including the case background, involved personnel, dispute focus and case progress, and standardize the processing to form the basic fact paragraph as the opening part of the document;
[0061] S82: The judgment reason and the judgment gist generated in S4 are integrated into the document according to the predetermined format, and the judgment gist is used as a summary paragraph of the judgment reason, which is used to briefly summarize the court's legal view and the basis of the judgment;
[0062] S83: Based on the optimized judgment gist in S6, confirm whether the content conforms to the legal logic and language standard, and insert the optimized judgment gist into the corresponding position of the document;
[0063] S84: The generated association index in S7 is attached to the end of the case document;
[0064] S85: The formatted document is processed to ensure that the layout of the document conforms to the standard format of the judicial document, including adding the header, paragraph number, title and footer information, and finally forming a complete case document.
[0065] Advantages of the present application:
[0066] The present application, by introducing the intelligent generation method based on the judicial knowledge field graph, can effectively improve the generation efficiency and accuracy of legal documents, by automatically extracting case facts, judgment reasons and judgment gist, and combining deep learning technology for optimization, the generated document not only ensures the integrity and consistency of the content, but also can provide more accurate legal judgment basis according to historical cases and legal provisions, which solves the problem of difficult extraction of complex information in multi-audience cases, and makes the document generation process more efficient and without omission.
[0067] The present application, by combining with the judicial knowledge field graph, realizes the intelligent association of judgment documents and historical cases, not only provides convenient historical case reference for legal workers, but also ensures the legal logic and language standard of the generated document, through deep optimization of the judgment gist and automatic generation of the association index, the user can quickly query the relevant legal information, significantly improves the accuracy and efficiency of case handling, and provides strong technical support for the judicial system. BRIEF DESCRIPTION OF DRAWINGS
[0068] In order to more clearly illustrate the technical solutions in the present application or prior art, the following will briefly introduce the drawings needed to be used in the embodiments or prior art description. Obviously, the drawings in the following description only illustrate the present application, and for those skilled in the art, other drawings can also be obtained without creative labor.
[0069] Fig. 1 A case intelligent generation method flowchart for an embodiment of the present application is shown in the figure;
[0070] Fig. 2 A step diagram for classifying case facts by a segmented rule extraction algorithm of an embodiment of the present application is shown in the figure. DETAILED DESCRIPTION
[0071] The present application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, in order to make the embodiments more detailed, the following embodiments are the best, preferred embodiments, and other alternative ways can also be implemented by those skilled in the art for some known technologies; and the accompanying drawings are only used to more specifically describe the embodiments, and are not intended to specifically limit the present application.
[0072] It should be noted that in the specification, "one embodiment", "embodiment", "exemplary embodiment", "some embodiments" and the like indicate that the described embodiments can include a specific feature, structure or property, but not necessarily every embodiment includes the specific feature, structure or property. In addition, when a specific feature, structure or property is described in combination with an embodiment, it should be within the knowledge of those skilled in the related art to implement such a feature, structure or property in combination with other embodiments, whether or not it is explicitly described.
[0073] Generally, the terms can be understood at least in part from the context of their usage. For example, depending at least in part upon the context, the term "one or more" as used herein can be used to describe any feature, structure, or characteristic in the singular or can be used to describe combinations of features, structures, or characteristics, in the plural, depending at least in part upon the context. Still further, the term "based on" can be understood as not necessarily of exclusive
[0074] As shown in the figure, the case intelligent generation method based on the judicial knowledge field graph includes the following steps: Figs. 1-2
[0075] S1: Construct a judicial knowledge field graph, which includes information of case type, trial procedure, basis for adjudication, and judgment result, to provide basic data support for case generation;
[0076] S2: Analyze the input multi-audience legal documents, extract the case facts and adjudication reasons of the documents, and mark the new facts in the multi-audience case to ensure the integrity and continuity of the information;
[0077] S3: Based on the judicial knowledge field graph constructed in S1 and the document information extracted in S2, apply a segmented rule extraction algorithm to classify and split the case facts of the documents, and generate a preliminary basic case summary;
[0078] S4: Deep learning generated summary of the extracted judgment reason part in S2 using BERT+LSTM model to obtain the judgment reason and the gist of the judgment;
[0079] S5: Combined with the judicial knowledge field map in S1 and the judgment reason and gist generated in S4, the content is associated and compared to check its integrity and accuracy, and to ensure the comprehensive presentation of multiple trial facts;
[0080] S6: Using the results of the association comparison in S5, the judgment gist is optimized through a convolutional neural network (DGCNN) model to enhance the legal logic and applicability of the case type of the judgment gist;
[0081] S7: Based on the optimized judgment gist in S6, the relevance analysis in the judicial knowledge field map is used to automatically generate an association index with other historical cases, providing reference and support for legal judgment;
[0082] S8: The results of S3, S4, S6 and S7 are summarized and spliced into a complete case document, and formatted to meet the standard output requirements of judicial documents.
[0083] S1 includes constructing a judicial knowledge field map, which specifically includes:
[0084] S11: Obtain historical judgment documents from existing judicial databases, including first instance judgment documents, second instance judgment documents and retrial judgment documents, where the data source is a public judicial database;
[0085] S12: Data preprocessing is performed on the obtained judgment documents, including data format standardization, redundant information cleaning and abnormal data elimination to ensure the integrity and consistency of the input data;
[0086] S13: Based on the preprocessed data, a graph structure algorithm is applied to construct a judicial knowledge field map, taking case types as nodes, case trial procedures, judgment basis and judgment results as edges, forming a directed graph connecting different case types;
[0087] S14: Labeling processing is performed on the nodes and edges in the graph, including the case type corresponding to each node, the trial procedure corresponding to each edge, and the relevant information of the judgment basis and judgment result, so that each element in the graph can accurately represent the actual judicial information. Through the above steps, the construction process of the judicial knowledge field map is ensured to be complete and clear in structure, providing accurate reference for the subsequent intelligent generation of cases.
[0088] S2 specifically includes:
[0089] S21: Text segmentation on the input multi-audience legal document, based on natural language processing (NLP) technology, the case fact part and the adjudication reason part in the document are preliminarily divided according to the fixed legal document format, the division standard includes paragraph identification, legal terminology and common document structure;
[0090] The common document structure is as follows:
[0091] Cover and header, the cover usually contains the basic information of the case, such as the case number, the name of the parties, the court of trial, etc.; the header may contain repeated information such as case number and document category;
[0092] Litigation participant information, including the names and roles of the plaintiff, the defendant, the attorney, the judge, etc.;
[0093] Case basic situation, briefly describes the background of the case, the legal relationship involved, the dispute focus, etc.;
[0094] Case facts, describe the fact, involving evidence, witness statement, court investigation, etc., this part usually describes the specific situation of the case in detail, which is the key part of information extraction;
[0095] Court opinion, the court's legal application, evidence evaluation and determination of dispute points, including the paragraph of "the court believes" and other leading words, focusing on the court's legal view;
[0096] Judgment result, usually introduced by "judgment as follows" or "decision as follows", clearly lists the court's decision, including the judgment result, the effective date of the judgment, the payment of fees, etc.;
[0097] End part, including appeal guide, legal effect description, etc., guiding the parties how to exercise their own rights according to law;
[0098] Annex, some documents may include annexes, such as relevant legal documents, evidence materials, etc.
[0099] S22: Using named entity recognition (NER) technology to extract predetermined elements from the document, including the case facts of the involved person, time, place, case type and dispute focus, the extraction process is based on the fixed expression mode and legal terminology in the document, the input document D contains multiple paragraphs P i and sentences S j , and define a fixed expression mode set M, which includes common legal terms such as "plaintiff", "defendant", "claim", etc.; use pattern matching algorithm f match (S j , M), match the fixed expression mode in each sentence S j , the formula is: f match (Sj , M) = {t k ∈ S j |t k ∈ M}, wherein t k is a term in the sentence, and the matching success extracts the element in the corresponding paragraph as the predetermined element;
[0100] S23: Based on the word frequency analysis and semantic analysis, the content of the judgment reason part is extracted, including the judgment basis, the legal analysis and the judgment points, and the context-related semantic model is used for extraction, assuming that the judgment reason part of the document is C, the judgment basis part is B, and the semantic model f semantic (C) is used to represent the context-related semantic vector representation, and the formula is: wherein v(S j ) is the semantic vector representation of the jth sentence, w j is the context-related weight, and the judgment reason part is extracted by calculating the similarity sim(v(C), v(B)) with the judgment basis to extract the core content of the judgment basis;
[0101] S24: The documents of multi-audience cases are compared and analyzed, the newly added case facts and judgment reasons in the second instance or re-examination documents are marked based on the timestamp information and semantic similarity calculation, and it is ensured that the information in the multi-audience documents is not missed; through the detailed description of the above sub-steps, the case facts and judgment reasons in the multi-audience legal documents can be effectively analyzed and extracted, and the newly added facts are marked to ensure the completeness and accuracy of the multi-audience case information, which is helpful to the accuracy of subsequent case generation.
[0102] The classification and splitting in S3 specifically include:
[0103] S31: The document information extracted in S2 is obtained, including the case facts and the judgment reason part, and the documents are preliminarily classified according to the case type, the trial procedure and the judgment basis, and the specific classification basis is provided by the nodes and edges in the judicial knowledge field graph constructed in S1;
[0104] S32: The segmented rule extraction algorithm is applied to classify the case facts, and the segmented rule extraction algorithm is based on the fixed paragraph structure of the document and the legal term set for classification;
[0105] S33: The paragraphs in S32 that meet the rules are classified and stored according to the categories, and the classified case fact information includes the case occurrence time, the identity of the parties, and the elements of the litigation request, so as to generate the subsequent basic case summary;
[0106] S34: The classified case fact information is broken down into specific events, points of contention, and key evidence points according to the case type and trial procedure. The breakdown is based on the related nodes and edges in the judicial knowledge domain graph in S1 to ensure that the case fact information of different types of cases is correctly classified.
[0107] S35: Based on the classification and splitting results, a preliminary basic case summary is generated. The case summary includes the main facts of the case, the points of contention, and a description of relevant evidence. The summary text is generated based on the classified and split case fact information and is formatted according to a standardized template. The above steps, through the segmented rule extraction algorithm and the graph-based classification and splitting mechanism, can effectively extract and classify the case facts in legal documents, generate a basic case summary with a clear structure and well-defined key points, and ensure accurate analysis and information organization of complex legal documents.
[0108] The segmented rule extraction algorithm used in S32 for classifying case facts specifically includes:
[0109] S321: Define a set of rules, where each rule corresponds to a category of case facts, such as “case background,” “points of contention,” or “description of evidence.” These rules consist of case type, legal terminology, and fixed paragraph structure of documents for subsequent classification.
[0110] S322: Convert the input document paragraph into a vector representation of words using word embedding technology. Specifically, convert each word in the paragraph into a corresponding numerical representation, and average the vectors of all words in the paragraph to obtain the vector representation of the paragraph as a whole.
[0111] S323: For each paragraph, compare its vector representation with the vector representation of a predefined rule. Calculate the similarity between the paragraph and each rule. The higher the similarity, the closer the paragraph is to the rule.
[0112] S324: Based on the calculated similarity, the paragraphs are classified into the category corresponding to the rule with the highest similarity. Through the above steps, the factual information of the case can be accurately classified, so that the content of the document matches the case type and rule. This process improves the accuracy of case fact classification and processing efficiency.
[0113] The calculation steps of the segmented rule extraction algorithm are as follows:
[0114] First, define a segmented rule set R, where each rule r k For each specific category of case facts (such as "case background", "points of contention", "description of evidence"), let r be... k This represents the k-th rule in the rule set, where k represents the rule number;
[0115] Then, for the input text passage P i , the passage P i is converted into a word vector representation v(P i ) by a word embedding technique, and the specific formula is as follows: Wherein, P i represents the i-th input passage; v(P i ) represents the word vector of the passage P i ; w j represents the j-th word in the passage P i ; v(w j ) represents the word vector of the word wj, N is the number of words in the passage P i , and j represents the index of the word;
[0116] Next, the similarity of the passage P i and the rule r k is calculated, and the cosine similarity is used to calculate the similarity score, and the formula is as follows: Wherein, sim(P i , r k ) represents the similarity of the passage P i and the rule r k ; v(r k ) represents the word vector of the rule r k ; ||v(P i )|| represents the length of the word vector of the passage P i ; ||v(r k )|| represents the length of the word vector of the rule r k ; · represents the dot product of vectors;
[0117] Finally, according to the similarity score, the rule r i with the highest similarity to the passage P k is selected, and the passage P i is classified into the corresponding category; the classification formula is: Category(P i )=argmax k sim(P i , r k ), wherein Category(P i ) represents the category to which the passage P i is classified, and the rule r k with the maximum similarity determines the classification of the passage.
[0118] S4 specifically comprises:
[0119] S41: Preprocessing the judgment reason text extracted in S2, and dividing the text into sentences and passages;
[0120] S42: input each sentence into the BERT model, encode the words in each sentence, and generate word vector representation with context correlation; the core of the BERT model is that it can learn the relationship between each word and its context through multiple layers of Transformer mechanism, and output the vector representation of the whole sentence, which can well express the semantic information of the sentence;
[0121] S43: input the vector of each sentence generated by BERT into the LSTM model to capture the context dependency between sentences, the LSTM model can remember the content of the previous sentence and consider this context information when processing the subsequent sentence, so as to analyze the entire judgment reason part coherently;
[0122] S44: when the LSTM has processed all the sentences, use the attention mechanism to generate the summary, the attention mechanism weights the hidden state of each sentence to clearly contribute to the summary, so as to generate more accurate and focused summary content;
[0123] S45: generate the summary of the judgment reason and the gist of the judgment through the decoder according to the hidden state of the LSTM.
[0124] The steps of using BERT+LSTM model are as follows:
[0125] First, first divide the text according to sentences and paragraphs to get a sentence set, let each sentence be S i , where i represents the index of the i-th sentence;
[0126] Then, input each sentence S i into the BERT model, and use the BERT model to encode the sentence and convert each word of the sentence into a word vector; for each word w i in the sentence S j , the BERT model will generate a context-related word vector v(w j ); BERT captures context information through multiple layers of Transformer mechanism, and outputs the vector representation v(S i ) of each sentence, the formula is: v(S i ) = BERT(S i ), where v(S i ) represents the context vector of the sentence v i , the input of the BERT model is the sentence S i , and the output is its corresponding vector;
[0127] Next, input the sentence vector v(S i) into the LSTM model, the LSTM is used to capture the context dependency between sentences, and the hidden state of the LSTM is denoted as h t , the current time is t , and the state update formula of the LSTM is h t = LSTM(v(v t ), h t-1 ), wherein h t is the LSTM hidden state at time t, v(S t ) is the input sentence vector at time t, h t-1 is the hidden state at the previous time, and the LSTM captures the dependency in the sentence sequence by continuously updating the hidden state;
[0128] After the LSTM processes all the sentences, the last hidden state h T is used to generate the summary, and the summary generation process is completed through an attention mechanism, which focuses on the relevance between each hidden state h t and the word s j in the generated summary, and the calculation formula of the attention score is: wherein h t represents the hidden state of the LSTM, s j is the jth word vector in the generated summary, and Attention(h t , s j ) represents the attention score of the hidden state h t to the generated word s j , and the attention mechanism associates each hidden state with the summary word to improve the accuracy of the generated summary.
[0129] Finally, through the attention mechanism and the decoder, the final hidden state of the LSTM is used to generate the judgment reason and the judgment gist summary, the decoder weights the hidden state output by the LSTM according to the attention score, and gradually generates a concise summary containing the core legal points of the case.
[0130] S5 specifically includes:
[0131] S51: The generated judgment reason and judgment gist in S4 are preliminarily matched with the historical cases in the judicial knowledge field graph constructed in S1, and based on the nodes of case type, judgment basis and judgment result in the graph, the relevant historical case information is extracted.
[0132] S52: Perform semantic matching on the generated judgment reasons of S4 and the judgment reasons of the same type of cases in the graph, calculate the similarity between the two to ensure that the generated judgment reasons are consistent with existing legal provisions and historical judgment logic; Specifically, let R1 be the currently generated judgment reason, and R2 be the historical judgment reason in the graph, calculate the similarity, the similarity calculation is based on the word vector model, the formula is as follows: Where v(R1) and v(R2) are the word vector representations of the judgment reasons R1 and R2 respectively, and · represents the dot product of vectors, ensuring that the generated judgment reasons are consistent with the historical cases in the graph in terms of semantics;
[0133] S53: Compare the judgment gist part, based on the historical case data extracted from the graph, use the semantic similarity algorithm to compare the generated judgment gist with the historical judgment gist, and determine whether the judgment gist covers all legal points; Let Y1 be the generated judgment gist, and Y2 be the historical judgment gist extracted from the graph, calculate the semantic similarity of the two based on the similarity algorithm, the formula is as follows: Where v(Y1) and v(Y2) are the word vector representations of the judgment gist Y1 and the historical judgment gist Y2 respectively, and through the calculation, it is determined whether the generated judgment gist covers all legal points;
[0134] S54: Check the integrity and accuracy of the judgment reasons and the judgment gist through the results of the association comparison, if there are omissions or inconsistencies in the comparison, it will be marked, and based on the legal provisions and historical case information in the graph, generate corresponding correction suggestions;
[0135] S55: Finally generate a verification report, output the comparison results and correction suggestions, and adjust the generated judgment reasons and judgment gist according to the verification results to ensure the compliance and integrity of the case content within the legal framework; Through the above association comparison and verification steps, it can be ensured that the generated judgment reasons and judgment gist are consistent with the historical cases in the judicial knowledge field graph, and potential omissions or inconsistencies can be found and corrected in time, improving the accuracy and legality of the generated content.
[0136] S6 specifically includes:
[0137] S61: Take the generated judgment gist in S5 and the modified suggestions after association comparison as input, and convert the judgment gist text into a word vector sequence through word embedding technology, where each word is converted into a corresponding numerical representation, forming a series of word vectors, which are used for subsequent convolution operations;
[0138] S62: Input the word vector sequence into the convolution layer of the convolutional neural network, and the convolution layer extracts local features from the word vector sequence through a sliding convolution kernel to identify important word combinations and expression patterns in the judgment gist. The convolution layer can effectively capture short-range dependencies between words;
[0139] S63: The output of the convolution layer is processed by the pooling layer. The pooling operation extracts the most important features from the convolution results, reduces the data dimension, and retains the most critical information. The pooling layer helps to enhance the model's ability to capture important information;
[0140] S64: The features after pooling are passed to the fully connected layer, where all local features are integrated into global features. The final feature representation of the judgment gist is generated by combining all extracted features;
[0141] S65: Based on the final feature representation, determine whether the judgment gist conforms to the legal logic and language standards. If it does not meet the standards, feedback modification suggestions; if it meets the standards, generate the final optimized judgment gist text. Through multi-level feature extraction and integration of the convolutional neural network model, the language expression and legal logic of the judgment gist can be deeply optimized to ensure that the generated judgment gist is not only complete but also logical.
[0142] The operation steps of optimizing the judgment gist through the convolutional neural network model are as follows:
[0143] Assume the judgment gist text is Y i , where each word w j is embedded as a word vector v(w j ), and the text is represented as a vector sequence [v(w1), v(w2),..., v(W n )];
[0144] Apply the convolution layer to the embedded word vector sequence, set the convolution kernel size to k, and perform local feature extraction on every k word vector to generate a feature map f(Y i ). Convolution operation is used to capture the features of local word combinations in the judgment gist. The convolution calculation formula is: f(Y i ) = ReLU(W·v(Y i )+b), where W is the convolution kernel weight, b is the bias, v(Y i ) is the word vector sequence, and the convolution result is nonlinearly mapped through the activation function ReLU;
[0145] The pooling layer uses the max-pooling operation to reduce the feature dimension by selecting the maximum value in each convolution window and retaining the most important feature information. The pooled feature representation is p(Y i );
[0146] The pooled feature vector is input to a fully connected layer, combined with the weights W c and the bias b c of the fully connected layer, to further integrate the features of the judicial gist and output an optimized feature vector representation v'(Y i ) for the final optimization of the judicial gist.
[0147] S7 specifically includes:
[0148] S71: Match the optimized judicial gist of S6 with the historical cases in the judicial knowledge domain graph. First, decompose the optimized judicial gist into multiple key elements, including case type, legal basis, and dispute focus, and then map these elements to the corresponding nodes in the graph for subsequent relevance analysis.
[0149] S72: Calculate the similarity between the optimized judicial gist and the gist of the historical cases in the graph. Based on the word vector model, convert the words in the judicial gist into vector representation, and then calculate the semantic similarity between the gist text and the historical case text. Similarity calculation is used to determine the degree of association between the current case and the historical cases, ensuring that the most relevant cases are matched.
[0150] S73: Filter the relevant historical cases matched. According to the correlation weight in the graph, evaluate the correlation strength between different historical cases. The correlation weight in the graph is established based on multiple factors such as case type, legal provisions, and historical cases. Each historical case has a different weight to measure its relevance to the current case.
[0151] S74: Generate a correlation index. Specifically, correlate the current judicial gist with the filtered historical cases, and display the case type, judicial result, and correlation information in the graph for each historical case through the correlation index. The generation of the correlation index ensures that similar historical cases can be quickly retrieved in subsequent queries.
[0152] S75: According to the generated correlation index, output an index report, which includes the correlation details, relevance score, and summary information of the historical cases between the current case and the historical cases, helping legal workers quickly understand the historical relevance of the current case. Through semantic matching and correlation weight analysis, the step can effectively identify the correlation between the current case and the historical cases and generate a structured correlation index to provide reference for legal workers, making the handling of complex cases more structured and logical.
[0153] S8 specifically includes:
[0154] S81: Obtain the basic case summary from S3, extract the core facts of the case, including the case background, involved personnel, dispute focus and case progress, and standardize the processing to form the basic fact paragraph as the opening part of the document;
[0155] S82: The judgment reason and the judgment gist generated in S4 are integrated into the document according to the predetermined format, ensuring that the judgment reason part is immediately after the basic case, and the judgment reason needs to include the court's legal analysis of the case, the applicable legal provisions, and the evaluation of the evidence, and the judgment gist is a summary paragraph of the judgment reason, which is used to briefly summarize the court's legal view and the basis of the judgment;
[0156] S83: Based on the optimized judgment gist in S6, confirm whether its content conforms to the legal logic and language specifications, and insert the optimized judgment gist into the corresponding position of the document, ensuring that the case points are expressed concisely and concisely;
[0157] S84: The generated correlation index in S7 is attached to the end of the case document, and the correlation index contains the historical cases and legal provisions related to the current case, helping readers quickly refer to historical judgments and legal basis, and the content of the correlation index should be consistent with the main content of the document and presented in a structured form;
[0158] S85: The formatted document is processed to ensure that the document layout conforms to the standard format of judicial documents, including adding header, paragraph number, title and footer information, and finally forming a complete case document, the above steps can generate a complete and clear case document by summarizing and splicing the contents of each part, the document content covers the case facts, judgment reason, judgment gist and related historical cases, ensuring that the document format conforms to the standard requirements of judicial documents, and facilitating subsequent use and reference.
[0159] The present application covers any substitution, modification, equivalent method and scheme made on the essence and scope of the present application. In order to make the public have a thorough understanding of the present application, specific details are described in the following preferred embodiments of the present application, and the present application can also be completely understood without the description of these details for those skilled in the art. In addition, in order to avoid unnecessary confusion to the essence of the present application, well-known methods, processes, procedures, elements and circuits are not described in detail.
[0160] The above is only the preferred embodiment of the present application, and it should be pointed out that for ordinary skilled in the art, without departing from the principle of the present application, a number of improvements and refinements can be made, and these improvements and refinements should be considered as the protection scope of the present application.
Claims
1.A method for intelligent case generation based on a judicial knowledge field map, characterized in that, The method comprises the following steps: S1: constructing a judicial knowledge field graph, wherein the judicial knowledge field graph comprises information of case types, trial procedures, judgment bases and judgment results; S2: analyzing input multi-trial legal documents, extracting case facts and judgment reasons of the documents, and marking new facts in multi-trial cases; S3: based on the judicial knowledge field graph constructed in S1 and the document information extracted in S2, applying a segmented rule extraction algorithm to classify and split the case facts of the documents, and generating a preliminary basic case summary; S4: using a BERT+LSTM model to generate a deep learning summary for the judgment reason part extracted in S2, obtaining the judgment reason and gist part; S4 specifically comprises: S41: preprocessing the judgment reason text extracted in S2, and dividing the text into sentences and paragraphs; S42: inputting each sentence into a BERT model to encode the words in each sentence and generate word vector representations with context correlation; S43: inputting the vector of each sentence generated by BERT into an LSTM model to capture the context dependency between sentences; S44: after the LSTM processes all the sentences, an attention mechanism is used to generate a summary, which explicitly identifies the sentences that contribute to the summary by weighting the hidden states of each sentence, thereby generating the summary content; S45: generating a summary of the judgment reason and gist through a decoder based on the hidden state of the LSTM; S5: combining the judicial knowledge field graph of S1 and the judgment reason and gist generated in S4 to associate and compare the contents, and check their completeness and accuracy; S5 specifically comprises: S51: preliminarily matching the judgment reason and gist generated in S4 with the historical cases in the judicial knowledge field graph constructed in S1, extracting relevant historical case information based on the nodes of case types, judgment bases and judgment results in the graph; S52: performing semantic matching on the judgment reason generated in S4 and the judgment reason of the same type of case in the graph, and ensuring that the generated judgment reason is consistent with existing legal provisions and historical judgment logic by calculating the similarity between them; S53: comparing the judgment gist part, using a semantic similarity algorithm to compare the generated judgment gist with the historical judgment gist based on the historical case data extracted from the graph, and determining whether the judgment gist covers all legal points; S54: checking the completeness and accuracy of the judgment reason and gist through the results of the association and comparison, and if there are missing or inconsistent contents in the comparison, marking them and generating corresponding correction suggestions based on the legal provisions and historical case information in the graph; S55: finally generating a verification report, outputting the comparison results and correction suggestions, and adjusting the generated judgment reason and gist according to the verification results; S6: using the results of the association and comparison in S5, optimizing the judgment gist through a convolutional neural network model to enhance the legal logic of the judgment gist and its applicability to case types; S7: Based on the optimization of the judgment gist in S6, the relevance analysis in the judicial knowledge field graph is used to automatically generate an association index with other historical cases; S8: The results of S3, S4, S6, and S7 are summarized and spliced into a complete case document, and formatted to meet the standard output requirements of judicial documents. 2.The method of claim 1, wherein, The S1 specifically includes: S11: Obtain historical judgment documents from existing judicial databases, including first instance judgment documents, second instance judgment documents, and retrial judgment documents, with data sources being public judicial databases; S12: Preprocess the obtained judgment documents, including standardizing data formats, cleaning up redundant information, and removing abnormal data; S13: Based on the preprocessed data, apply graph structure algorithms to construct a judicial knowledge field graph, with case types as nodes, case trial procedures, judgment basis, and judgment results as edges, forming a directed graph connecting different case types; S14: Label the nodes and edges in the graph, including the case type corresponding to each node, the trial procedure corresponding to each edge, and the relevant information of the judgment basis and judgment result. 3.The method of claim 1, wherein, The S2 specifically includes: S21: Perform text segmentation on the input multi-instance legal documents, and preliminarily divide the case fact part and the judgment reason part in the documents according to the fixed legal document format based on natural language processing technology, with the division criteria including paragraph identification, legal terminology, and common document structure; S22: Use named entity recognition technology to extract predetermined elements from the documents, including case facts such as involved persons, time, location, case type, and dispute focus; S23: Based on word frequency analysis and semantic analysis, extract the content of the judgment reason part, including judgment basis, legal analysis, and judgment points; S24: Compare and analyze the documents of multi-instance cases, and mark the newly added case facts and judgment reasons in the second instance or retrial documents based on timestamp information and semantic similarity calculation, ensuring that no information is missed in the multi-instance documents. 4.The method of claim 1, wherein, The S3 specifically includes: S31: Obtain the document information extracted in S2, including the case facts and judgment reasons, and preliminarily classify the documents according to case type, trial procedure, and judgment basis, with the specific classification basis provided by the nodes and edges in the judicial knowledge field graph constructed in S1; S32: Apply a segmented rule extraction algorithm to classify the case facts, which is based on the fixed paragraph structure and legal terminology set of the documents; S33: Classify and store the paragraphs that meet the rules in S32 according to categories, with the classified case fact information including case occurrence time, party identity, and elements of litigation request; S34: Split the classified case fact information, and divide each case fact into specific events, dispute focus, and evidence points according to the differences in case type and trial procedure; S35: Based on the results of classification and splitting, generate a preliminary basic case summary, which includes the main facts of the case, dispute focus, and related evidence description, and is formatted according to the standardized template for output. 5.The method of claim 4, wherein, The S32 specifically comprises: S321: defining a set of rules, wherein each rule corresponds to a type of case facts; S322: converting the input document paragraphs into vector representations of words through word embedding technology, specifically converting each word in each paragraph into a corresponding numerical representation, and averaging the vectors of all words in the paragraph to obtain the vector representation of the entire paragraph; S323: for each paragraph, compare its vector representation with the vector representation of the pre-defined rules, and calculate the similarity between the paragraph and each rule, the higher the similarity, the closer the paragraph is to the rule; S324: according to the calculated similarity, classify the paragraph into the category corresponding to the rule with the highest similarity. 6.The method of claim 1, wherein, The S6 specifically comprises: S61: taking the judgment gist generated in S5 and the modified suggestions after association comparison as input, and converting the judgment gist text into a sequence of word vectors through word embedding technology, wherein each word is converted into a corresponding numerical representation to form a series of word vectors; S62: input the sequence of word vectors into the convolution layer of the convolutional neural network, and the convolution layer extracts local features from the sequence of word vectors through sliding convolution kernels to identify important word combinations and expression patterns in the judgment gist; S63: the output of the convolution layer is processed by the pooling layer, and the pooling operation extracts the most important features from the convolution results; S64: the features after pooling processing are transmitted to the fully connected layer, in which all local features are integrated into global features, and the final feature representation of the judgment gist is generated by integrating all extracted features; S65: based on the final feature representation, it is judged whether the judgment gist conforms to the legal logic and language specifications, if not, feedback modification suggestions; if it conforms to the standard, generate the final optimized judgment gist text. 7.The method of claim 1, wherein the method further comprises: The S7 specifically comprises: S71: matching the optimized judgment gist in S6 with the historical cases in the judicial knowledge domain graph; S72: calculating the similarity between the optimized judgment gist and the gist of the historical cases in the graph, converting the words in the judgment gist into vector representations based on the word vector model, and then calculating the semantic similarity between the gist text and the historical case text; S73: screening the relevant historical cases matched, and evaluating the correlation strength between different historical cases according to the correlation weight in the graph; S74: generating a correlation index, specifically correlating the current judgment gist with the screened historical cases, and displaying the case type, judgment result and correlation information in the graph of each historical case through the correlation index; S75: according to the generated correlation index, output an index report, which includes the correlation details of the current case and the historical cases, the relevance score and the summary information of the historical cases. 8.The method of claim 1, wherein the method further comprises: The S8 specifically comprises: S81: obtain the basic case summary from S3, extract the core facts of the case, including the case background, the involved personnel, the dispute focus and the case process, and perform standardization processing to form a basic fact paragraph as the opening part of the document; S82: The judgment reason generated in S4 and the judgment gist are integrated into the document in a predetermined format, and the judgment gist is used as a summary paragraph of the judgment reason to briefly summarize the court's legal view and the basis of the judgment; S83: Based on the optimized judgment gist in S6, confirm whether its content conforms to the legal logic and language specifications, and insert the optimized judgment gist into the corresponding position of the document; S84: Attach the correlation index generated in S7 to the end of the case document; S85: Format the summarized document to ensure that the layout of the document conforms to the standard format of judicial documents, including adding header, paragraph number, title and footer information, and finally forming a complete case document.
Citation Information
Patent Citations
File retrieval method and device
CN112148701A
Knowledge graph completion method for automatically extracting relationship based on decision-making text
CN113204648A