A legal judgment prediction method integrated with a guiding case and a related device
By combining the case prediction module, case matching module, and feature fusion module, the problem of existing legal judgment prediction systems failing to effectively integrate judgment prediction and similar case matching is solved, achieving higher accuracy and efficiency.
Patent Information
- Application Number
- CN202211439340.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-11-17
- Publication Date
- 2026-02-06
- Estimated Expiration
- 2042-11-17
AI Technical Summary
Existing legal judgment prediction systems fail to effectively integrate legal judgment prediction with similar case matching tasks, resulting in a need to improve accuracy and efficiency.
The system employs a case prediction module, a case matching module, a feature fusion module, and an output module. Through encoding, similarity calculation, and feature fusion, combined with a feedforward neural network decoder, it achieves the fusion of the similarity between the case to be predicted and the guidance case, as well as the prediction results.
It has improved the accuracy and efficiency of legal judgment prediction, reduced the situation of "different judgments for the same case", and enhanced the accuracy of legal provision prediction and crime prediction.
Smart Images

Figure CN115795317B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of artificial intelligence technology, and in particular to a method, system, terminal, and computer-readable storage medium for predicting legal judgments by incorporating guiding cases. Background Technology
[0002] In the real world, legal judgments are a highly complex process, often requiring significant time and effort from judicial staff. Legal judgment prediction systems are important tools in the field of legal artificial intelligence. Their goal is to predict the outcome of a judgment based on the factual description of a case, such as legal provisions, charges, and sentences. On the one hand, they can effectively provide reliable references for judicial staff. On the other hand, the public can access legal advice services at a lower cost.
[0003] like Figure 1 As shown, in the actual legal judgment process, guiding cases mainly provide reference and guidance for the judgment of the current case. Judges search for guiding cases based on the case to be judged and make a judgment based on the factual description. Existing research focuses on legal judgment prediction or similar case matching tasks without considering the relationship between the two. That is, existing legal judgment prediction does not incorporate or consider guiding cases, so the accuracy and efficiency of legal judgment prediction need to be improved.
[0004] Therefore, existing technologies still need to be improved and developed. Summary of the Invention
[0005] The main objective of this invention is to provide a legal judgment prediction method, system, terminal, and computer-readable storage medium that incorporates guiding cases. This aims to address the problem in the prior art that the connection between legal judgment prediction and similar case matching tasks is not considered when making judgment predictions, resulting in a need to improve the accuracy and efficiency of legal judgment prediction.
[0006] To achieve the above objectives, the present invention provides a method for predicting legal judgments by incorporating guiding cases, the method comprising the following steps:
[0007] The case prediction module obtains factual information of the case to be predicted. The factual information is used to characterize the case factual description in the case to be predicted. The factual information is input into the legal judgment prediction model to obtain the encoding result of the factual description. The encoding result is input into the case matching module. The similarity sequence is obtained by calculating the similarity with the factual description of the guiding case. The similarity sequence is input into the feature fusion module.
[0008] The case matching module performs semantic analysis on the encoding results to obtain an initial prediction result sequence, and inputs the initial prediction result sequence into the feature fusion module;
[0009] The feature fusion module normalizes the similarity sequence and the initial prediction result sequence, concatenates them according to preset weights, and inputs the concatenated sequence into the output module.
[0010] The output module learns the features of the similarity sequence and the initial prediction result sequence according to the task after splicing the sequence, and decodes the corresponding decision prediction result.
[0011] Optionally, in the aforementioned method for predicting legal judgments incorporating guiding cases, the case prediction module is specifically used for:
[0012] For the factual information of the case to be predicted, the factual information is formalized into a character sequence or word sequence S = {s1, ..., s2}. i , ..., s n}, where s i It is each character or word in the character sequence or word sequence, where n is the maximum length set to 256;
[0013] Output the confidence sequence C = {c1, ..., c2} of the cases to be predicted belonging to different categories. i c m}, where c i This represents the probability that the case to be predicted belongs to category i, where m is the total number of categories.
[0014] Optionally, in the aforementioned method for predicting legal judgments incorporating guiding cases, the case matching module is specifically used for:
[0015] Input factual descriptions of the cases to be predicted and the guiding cases, which are then transformed by an encoder into two sequences S = {s1, ..., s2}. i , ..., s n This yields deep semantic representations of the cases to be predicted and the guiding cases;
[0016] The correlation between the deep semantic representations of the cases to be predicted and the guiding cases is calculated based on cosine similarity. The correlation between cases with the same crime is defined as 1, and the correlation between cases with different crimes is defined as 0.
[0017] The output length is the total number of guiding cases, G = {g1, ..., g}. i , ..., g k}, where g i This indicates the degree of correlation between the case to be predicted and the i-th guiding case, where k is the total number of guiding cases.
[0018] Optionally, in the aforementioned method for predicting legal judgments by incorporating guiding cases, the feature fusion module is specifically used for:
[0019] The output length of the result G = {g1,..., g i ,..., g k} is compressed to obtain:
[0020]
[0021]
[0022] wherein, represents the correlation sequence of G after compression processing, represents the correlation degree of the compressed predicted case and the i th guiding case, represents the correlation sequence of the predicted case and a batch of guiding cases of a certain charge;
[0023] Late fusion is selected as the feature fusion mode of the legal judgment prediction model:
[0024]
[0025] wherein, C is the confidence sequence of the case prediction module output, the case belongs to different categories, is the correlation sequence of the compressed guiding case output by the case matching module, W1 and W2 are the set weights, and Concatenate represents splicing.
[0026] Optionally, the legal judgment prediction method incorporating guiding cases, wherein the output module is specifically used for:
[0027] Spliced features The final judgment prediction result is obtained through the feedforward neural network decoder:
[0028]
[0029] wherein, N is the total number of result categories of the current task i, Y i represents the final judgment prediction result, and Argmax represents the index for obtaining the maximum value in the sequence.
[0030] Optionally, the legal judgment prediction method incorporating guiding cases, wherein the feedforward neural network decoder comprises a statute decoder and a charge decoder.
[0031] Optionally, the legal judgment prediction method incorporating guiding cases, wherein the judgment prediction result comprises a predicted statute and a predicted charge.
[0032] In addition, to achieve the above object, the application further provides a legal judgment prediction system integrated with a guiding case, wherein the legal judgment prediction system integrated with the guiding case comprises:
[0033] The case prediction module and the case matching module are connected with the feature fusion module respectively, and the feature fusion module is connected with the output module.
[0034] The case prediction module is used for obtaining fact information of a case to be predicted, the fact information is used for representing a case fact description in the case to be predicted, the fact information is input into a legal judgment prediction model to obtain an encoding result of the fact description, the encoding result is input into the case matching module, a similarity sequence is obtained by calculating a similarity with a guiding case fact description, and the similarity sequence is input into the feature fusion module.
[0035] The case matching module is used for performing semantic analysis on the encoding result to obtain an initial prediction result sequence, and the initial prediction result sequence is input into the feature fusion module.
[0036] The feature fusion module is used for performing normalization processing on the similarity sequence and the initial prediction result sequence, splicing according to a preset weight, inputting the spliced sequence into the output module.
[0037] The output module is used for learning features of the similarity sequence and the initial prediction result sequence according to a task, and decoding a corresponding judgment prediction result.
[0038] In addition, to achieve the above object, the application further provides a terminal, wherein the terminal comprises a memory, a processor, and a legal judgment prediction program integrated with a guiding case stored on the memory and capable of running on the processor, and the legal judgment prediction program integrated with the guiding case realizes steps of the legal judgment prediction method integrated with the guiding case when the legal judgment prediction program integrated with the guiding case is executed by the processor.
[0039] In addition, to achieve the above object, the application further provides a computer readable storage medium, wherein the computer readable storage medium stores a legal judgment prediction program integrated with a guiding case, and the legal judgment prediction program integrated with the guiding case realizes steps of the legal judgment prediction method integrated with the guiding case when the legal judgment prediction program integrated with the guiding case is executed by a processor.
[0040] In the present application, the case prediction module obtains the fact information of the case to be predicted, the fact information is used to represent the case fact description in the case to be predicted, the fact information is input into the legal judgment prediction model, the encoding result of the fact description is obtained, the encoding result is input into the case matching module, the similarity sequence is obtained by calculating the similarity with the guiding case fact description, the similarity sequence is input into the feature fusion module; the case matching module performs semantic analysis on the encoding result to obtain an initial prediction result sequence, and the initial prediction result sequence is input into the feature fusion module; the feature fusion module performs normalization processing on the similarity sequence and the initial prediction result sequence, splices according to a preset weight, and inputs the spliced sequence into the output module; the output module learns the features of the similarity sequence and the initial prediction result sequence according to the task, and decodes the corresponding judgment prediction result. The present application realizes that only the fact description of the case needs to be input to obtain the judgment result, and improves the accuracy of the case judgment result prediction. BRIEF DESCRIPTION OF DRAWINGS
[0041] Figure 1 is a schematic diagram of obtaining a judicial judgment result in the prior art;
[0042] Figure 2 is a flowchart of a preferred embodiment of the legal judgment prediction method of the present application incorporating guiding cases;
[0043] Figure 3 is a schematic diagram of a preferred embodiment of the legal judgment prediction system of the present application incorporating guiding cases;
[0044] Figure 4 is a schematic diagram of the running environment of a preferred embodiment of the terminal of the present application. DETAILED DESCRIPTION
[0045] To make the objectives, technical solutions and advantages of the present application clearer and more explicit, the present application is further described in detail below with reference to the drawings and examples. It should be understood that the specific embodiments described herein are only used to explain the present application and do not limit the present application.
[0046] The legal judgment prediction method incorporating guiding cases described in the preferred embodiment of the present application, as shown in Figure 2 and Figure 3 , comprises the following steps:
[0047] Step S10, the case prediction module obtains the fact information of the case to be predicted, the fact information is used to represent the case fact description in the case to be predicted (i.e. Figure 3The fact information is input into a legal judgment prediction model (MAGIC, MAtching Guiding Cases), the fact description in the case to be predicted is preprocessed to obtain an encoding result of the fact description, the encoding result is input into a case matching module, a similarity sequence is obtained by calculating the similarity with the fact description of the guiding case, and the similarity sequence is input into a feature fusion module.
[0048] Specifically, the hyperparameters and neural network model of the case prediction module are preset, such as weights, encoders, and decoders. Figure 3 As shown in the figure, the case prediction module is composed of an encoder (used for converting a literal description into a digital sequence), a neural network, a pooling, and a decoder. For example, when the case prediction module is preset, the rules for converting a literal into a number (for example, “university” corresponds to the number “37”) need to be preset for the encoder, a specific neural network (such as CNN, DPCNN, LSTM, etc.) is preset, and different decoders (Decoder) are preset according to different prediction tasks (the law article decoder is used for predicting law articles, and the crime name decoder is used for predicting crime names).
[0049] The case prediction module can be divided into an encoding layer and a decoding layer. The application is aimed at exploring the influence of the introduction of guiding cases on the performance of the legal judgment prediction model. Therefore, the case prediction module adopts the most basic encoding and decoding mode, as shown in the case prediction module in the figure. Figure 3
[0050] For the fact information of the case to be predicted (that is, for each data), the fact information is formalized into a character sequence or a word sequence S={s1,…,s i ,…,s n}, where s i is each character or word in the character sequence or word sequence, and n is the maximum length 256 set. The encoder (Encoder) will pad or truncate the input that does not meet this length. S is input into a predictor (composed of a neural network, a pooling, and a decoder), and the predictor outputs a confidence sequence C={c1,…,c i ,…,c m} of different categories of the case to be predicted, where c i represents the probability that the case to be predicted belongs to the i-th category, and m is the total number of categories. The design of the case prediction module in the application is consistent with the existing work, that is, it is assumed that each case has only one applicable law article and crime name, and the cases containing multiple law articles and crime names are filtered out, so that the task is simplified into a multi-classification problem.
[0051] Step S20, the case matching module performs semantic analysis on the encoding result to obtain an initial prediction result sequence, and inputs the initial prediction result sequence into the feature fusion module.
[0052] Specifically, the present application formalizes the case matching task as a semantic similarity calculation task, and the goal is to calculate the correlation degree of the case to be predicted and the guiding case. In order to reduce the consumption of computing resources, as shown in the formula (1), the present application designs the case matching module based on the twin network structure, and uses two albert-tiny pre-training models as the encoders (i.e. the two Encoders in the formula (1)) of the guiding case and the case to be predicted. Figure 3 Figure 3 The input is the fact description of the case to be predicted and the guiding case, and the two sequences S={s1, …, s i , …, s n} are converted by the encoder, and the correlation degree between the case to be predicted and the guiding case is calculated by using the cosine similarity after the deep semantic representation of the case to be predicted and the guiding case is obtained by the two encoders, just like the case prediction module. Figure 3 In the formula (1), u and v represent two intermediate output values processed by the Encoder and Pooling.
[0053] In the present application, the correlation degree of the same crime name is defined as 1, and the correlation degree of the different crime name is defined as 0. More specifically, the output length of the result G={g1, …, g i , …, g k} is required, wherein g i represents the correlation degree of the case to be predicted and the i-th guiding case, and k is the total number of guiding cases.
[0054] Step S30, the feature fusion module performs normalization processing on the similarity sequence and the initial prediction result sequence, splices the sequences according to the preset weight, and inputs the spliced sequence into the output module.
[0055] Specifically, the output of the case matching module is a text similarity vector of the case to be predicted and the guiding case library (a guiding case library pre-collected with related guiding cases and typical cases to construct a model, the guiding case is some representative case published by the Supreme Court, and the similar case is similar between cases, for example, to find the similar case of a case, the similar existing case will be searched from the case library). Since the guiding case library of the present application is constructed by selecting 3 cases according to each crime name, the result G={g1, …, g i , …, g k} of the total number of guiding cases can be compressed to obtain:
[0056]
[0057]
[0058] wherein, represents the correlation degree sequence of G after compression processing, represents the correlation degree of the case to be predicted after compression processing and the i th guiding case, represents the correlation degree sequence of the case to be predicted and a batch of guiding cases of a certain charge; that is, the correlation degrees of the case to be predicted and three guiding cases of the same charge are added to obtain the correlation degree sequence of the case to be predicted and a batch of guiding cases of a certain charge
[0059] Meanwhile, in order to have consistency of the two features, the application also normalizes the prediction features output by the case prediction module. In order to maximize the preservation of the features of the case prediction module and the case matching module, the application selects late fusion (fusion after obtaining the output sequences of the two modules is late fusion, corresponding to early fusion, early fusion is to fuse the data first and then input into the model) as the feature fusion mode of the legal judgment prediction model:
[0060]
[0061] wherein, C is the confidence sequence of the case output by the case prediction module belonging to different categories, is the correlation degree sequence of the guiding case output by the compressed case matching module, W1 and W2 are set weights, and Concatenate represents splicing (splicing: splicing two numerical sequences together).
[0062] Step S40, the output module learns the features of the spliced sequence according to the similarity sequence and the initial prediction result sequence, and decodes the corresponding judgment prediction result.
[0063] Specifically, the spliced features The final judgment prediction result is obtained through the feedforward neural network decoder:
[0064]
[0065] wherein, N is the total number of result categories of the current task i, Y i represents the final judgment prediction result, and Argmax represents the index for obtaining the maximum value in the sequence.
[0066] As Figure 3As shown, the feedforward neural network decoder includes a legal provision decoder and a crime decoder. The legal provision decoder can decode to obtain a predicted legal provision, and the crime decoder can decode to obtain a predicted crime. That is, the legal provision decoder and the crime decoder respectively decode the concatenated sequence to obtain the predicted legal provision and the predicted crime.
[0067] Furthermore, the present invention pre-trains the case prediction module and the case matching module:
[0068] For the case prediction module: This invention trains two case predictors for the legal provision prediction task and the crime prediction task respectively. Each case predictor focuses on predicting a single task. The case predictors are trained using the cross-entropy loss function, as shown below:
[0069]
[0070] Among them, y i This represents the true label; when the label is true, y i =1, y is false when the label is false i =0, p i The model outputs the probability of the label, where N is the total number of categories.
[0071] For the case matching module: the matcher is trained based on the cosine similarity calculation function, as shown below:
[0072]
[0073] Here, A and B represent the deep semantic representation sequences after the factual descriptions of the two cases are encoded, ||A||2 and ||B||2 represent the paradigms of the two sequences A and B, and the calculation result of cosine similarity is in the range of [-1, 1]. During training, the cosine similarity of two cases with different charges is marked as 0, and the cosine similarity of two cases with the same charges is marked as 1.
[0074] Furthermore, to verify the effectiveness of the MAGIC model in this invention, accuracy (Acc.), macro precision (MP), macro recall (MR), and macro F1 score (F1) are used to measure the performance of all models. This invention mainly focuses on the results of legal provision prediction and crime prediction. Since both datasets (CAIL-small and CAIL-big represent two datasets) exhibit data imbalance, the macro F1 score is used as the primary evaluation metric. Here, LawArticles represents the results of the legal provision prediction task, and Charges represents the results of the crime prediction task. The experimental results of all models on the CAIL-small and CAIL-big datasets are shown in Table 1.
[0075]
[0076] Table 1: Experimental results of different models on CAIL dataset
[0077] It can be seen that the MAGIC model proposed in the present application has a significant and consistent improvement compared with all baseline models. Compared with the optimal results of all baselines, the macro F1 value of the MAGIC model on the statute prediction and charge prediction tasks of CAIL-small is improved by 2.97% and 2.12% respectively, and on CAIL-big is improved by 1.06% and 1.00% respectively. The experimental results prove the effectiveness of the MAGIC model.
[0078] At the same time, it can be seen from the significant improvement of macro recall rate (MR) that the MAGIC model of the present application reduces the prediction model bias caused by data imbalance to predict high-frequency results, which indicates that the model reduces the "same case different judgment" situation of the conventional model caused by data imbalance.
[0079] The present application focuses on solving the statute prediction and charge prediction tasks in legal judgment prediction, and refers to the guiding case system, integrates the idea of guiding case matching to improve the performance of the legal judgment prediction model and reduce the "same case different judgment" problem that may be caused by the existing legal judgment prediction method. The MAGIC model proposed in the present application significantly improves the performance of the legal judgment model by introducing a small amount of guiding cases through the prediction method of feature fusion after integrating the guiding case matching module.
[0080] The MAGIC model can be applied to the field of legal intelligence, and intuitively can be applied to the statute prediction and charge prediction tasks in legal judgment prediction, which can help judicial system practitioners to improve efficiency and provide convenient intelligent judicial services for the public.
[0081] Further, as shown in Figure 3 Based on the above legal judgment prediction method integrating guiding cases, the present application also correspondingly provides a legal judgment prediction system integrating guiding cases, wherein the legal judgment prediction system integrating guiding cases comprises:
[0082] a case prediction module, a case matching module, a feature fusion module and an output module; the case prediction module and the case matching module are connected with the feature fusion module respectively, and the feature fusion module is connected with the output module.
[0083] The case prediction module is used to obtain factual information of the case to be predicted. The factual information is used to characterize the case factual description in the case to be predicted. The factual information is input into the legal judgment prediction model to obtain the encoding result of the factual description. The encoding result is input into the case matching module to obtain a similarity sequence by calculating the similarity with the factual description of the guiding case. The similarity sequence is input into the feature fusion module.
[0084] The case matching module is used to perform semantic analysis on the encoding result to obtain an initial prediction result sequence, and input the initial prediction result sequence into the feature fusion module.
[0085] The feature fusion module is used to normalize the similarity sequence and the initial prediction result sequence, concatenate them according to preset weights, and input the concatenated sequence into the output module.
[0086] The output module is used to learn the features of the similarity sequence and the initial prediction result sequence according to the task after splicing the sequence, and decode the corresponding decision prediction result.
[0087] Furthermore, such as Figure 4 As shown, based on the above-mentioned legal judgment prediction method and system incorporating guiding cases, the present invention also provides a terminal, which includes a processor 10, a memory 20 and a display 30. Figure 4 Only some of the terminal components are shown; however, it should be understood that it is not required to implement all of the components shown, and more or fewer components may be implemented instead.
[0088] In some embodiments, the memory 20 may be an internal storage unit of the terminal, such as a hard disk or memory. In other embodiments, the memory 20 may be an external storage device of the terminal, such as a plug-in hard disk, SmartMediaCard (SMC), SecureDigital (SD) card, or FlashCard. Furthermore, the memory 20 may include both internal and external storage devices. The memory 20 is used to store application software and various types of data installed on the terminal, such as program code installed on the terminal. The memory 20 may also be used to temporarily store data that has been output or will be output. In one embodiment, the memory 20 stores a legal judgment prediction program 40 incorporating guiding cases, which can be executed by the processor 10 to implement the legal judgment prediction method incorporating guiding cases in this application.
[0089] The processor 10 can be a central processing unit (CPU), a microprocessor or other data processing chip in some embodiments, for running program codes stored in the memory 20 or processing data, such as executing the legal judgment prediction method integrated with guiding cases and the like.
[0090] The display 30 can be an LED display, a liquid crystal display, a touch liquid crystal display, an OLED (Organic Light-Emitting Diode) touch and the like in some embodiments. The display 30 is used to display information of the terminal and to display a visualized user interface. The components 10-30 of the terminal communicate with each other through a system bus.
[0091] In an embodiment, the steps of the above-mentioned legal judgment prediction method integrated with guiding cases are implemented when the processor 10 executes the legal judgment prediction program integrated with guiding cases 40 in the memory 20.
[0092] The present application also provides a computer readable storage medium, wherein the computer readable storage medium stores a legal judgment prediction program integrated with guiding cases, and the steps of the legal judgment prediction method integrated with guiding cases as mentioned above are implemented when the legal judgment prediction program integrated with guiding cases is executed by a processor.
[0093] In summary, the present application provides a legal judgment prediction method integrated with guiding cases and related equipment, the method comprising: a case prediction module acquires fact information of a case to be predicted, the fact information being used to represent a case fact description in the case to be predicted, the fact information being input to a legal judgment prediction model to obtain an encoding result of the fact description, the encoding result being input to a case matching module, a similarity sequence being obtained by calculating a similarity with a guiding case fact description, the similarity sequence being input to a feature fusion module; the case matching module performs semantic analysis on the encoding result to obtain an initial prediction result sequence, the initial prediction result sequence being input to the feature fusion module; the feature fusion module performs normalization processing on the similarity sequence and the initial prediction result sequence, splicing according to a preset weight, the spliced sequence being input to an output module; the output module learns features of the similarity sequence and the initial prediction result sequence according to a task, and decodes a corresponding judgment prediction result. The present application realizes that only the fact description of a case needs to be input to obtain a judgment result, and improves the accuracy of case judgment result prediction.
[0094] It should be noted that, in the present document, the terms "comprises", "comprising", or any other variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but can also include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element preceded by "comprises a" does not, without more constraints, foreclose the existence of additional identical elements in the process, method, article, or apparatus that comprises the element.
[0095] Of course, those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing relevant hardware (such as a processor, a controller, etc.) through a computer program, and the program can be stored in a computer readable computer readable storage medium, and the program can include the processes of the above-mentioned method embodiments when executed. The computer readable storage medium can be a memory, a magnetic disc, an optical disc, etc.
[0096] It should be understood that the application is not limited to the above examples, and those skilled in the art can make improvements or changes according to the above description, and all these improvements and changes shall fall within the protection scope of the appended claims of the present application.
Claims
1. A legal decision prediction method incorporating guiding cases, characterized by, The legal judgment prediction method integrated with the guiding case comprises the following steps: The case prediction module obtains fact information of a case to be predicted, the fact information being used to represent a case fact description in the case to be predicted, inputs the fact information into a legal judgment prediction model, obtains an encoding result of the fact description, inputs the encoding result into a case matching module, obtains a similarity sequence by calculating a similarity with a fact description of a guiding case, and inputs the similarity sequence into a feature fusion module; The case matching module performs semantic analysis on the encoding result to obtain an initial prediction result sequence, and inputs the initial prediction result sequence into the feature fusion module; The feature fusion module performs normalization processing on the similarity sequence and the initial prediction result sequence, splices the similarity sequence and the initial prediction result sequence according to a preset weight, and inputs the spliced sequence into an output module; The output module learns features of the similarity sequence and the initial prediction result sequence according to a task, and decodes a corresponding judgment prediction result; The case matching module is specifically configured to: Input the fact description of the case to be predicted and the guiding case, and convert it into two sequences through the encoder , is each character or word in the character sequence or word sequence, The maximum length is set to 256, and the deep semantic representation of the case to be predicted and the guiding case is obtained. calculate a correlation degree between a deep semantic representation of the case to be predicted and a deep semantic representation of the guiding case based on a cosine similarity, define the correlation degree of cases with the same charge as 1, and define the correlation degree of cases with different charges as 0; Output length is the total number of guide cases wherein, represents the degree of relevance of the case to be predicted to the guide case, is the total number of guide cases; The feature fusion module is specifically configured to: The output length is the total number of cases The compression process results in: ; ; in, express The correlation sequence after compression This indicates the compressed version of the case to be predicted and the first... The relevance of each guiding case This represents the correlation sequence between the case to be predicted and a set of guiding cases for a certain crime; select late fusion as a feature fusion mode of the legal judgment prediction model; ; wherein, a sequence of confidences that a case output by the case prediction module belongs to different categories, and is a weight set, denotes concatenation. 2.The method of claim 1, wherein, The case prediction module is specifically configured to: For the fact information of the case to be predicted, the fact information is formalized into a character sequence or a word sequence ; a sequence of confidence levels that the case to be predicted belongs to different classes wherein, denotes the probability that the case to be predicted belongs to a class denotes the probability that the case to be predicted belongs to a class is the total number of classes. 3.The legal judgment prediction method of integrating a guiding case according to claim 1, characterized in that, The output module is specifically configured to: concatenated features a final decision prediction is derived by a feedforward neural network decoder: ; wherein, is the total number of result categories of the current task represents the final decision prediction result, represents the index for obtaining the maximum value in the sequence. 4.The method of claim 3, wherein, The feedforward neural network decoder comprises a statute decoder and a charge decoder. 5.The method of claim 1 or 3, wherein, The judgment prediction result comprises a predicted statute and a predicted charge.
6. A legal decision prediction system incorporating instructive case law, characterized by, The legal judgment prediction system integrated with the guiding case is used to implement the legal judgment prediction method integrated with the guiding case according to any one of claims 1-5, and comprises: The case prediction module, the case matching module, the feature fusion module, and the output module; the case prediction module and the case matching module are connected with the feature fusion module, and the feature fusion module is connected with the output module; The case prediction module is configured to obtain fact information of a case to be predicted, the fact information being used to represent a case fact description in the case to be predicted, input the fact information into a legal judgment prediction model, obtain an encoding result of the fact description, input the encoding result into the case matching module, obtain a similarity sequence by calculating a similarity with a fact description of a guiding case, and input the similarity sequence into the feature fusion module; The case matching module is configured to perform semantic analysis on the encoding result to obtain an initial prediction result sequence, and input the initial prediction result sequence into the feature fusion module; The feature fusion module is configured to perform normalization processing on the similarity sequence and the initial prediction result sequence, splice the similarity sequence and the initial prediction result sequence according to a preset weight, and input the spliced sequence into the output module; The output module is configured to learn features of the similarity sequence and the initial prediction result sequence according to a task, and decode a corresponding judgment prediction result.
7. A terminal, characterized by comprising: The terminal comprises a memory, a processor, and a legal judgment prediction program integrated with guiding cases stored on the memory and executable on the processor, and the legal judgment prediction program integrated with guiding cases, when executed by the processor, implements the steps of the legal judgment prediction method integrated with guiding cases according to any one of claims 1-5.
8. A computer-readable storage medium, characterized in that, The computer readable storage medium stores a legal judgment prediction program integrated with guiding cases, and the legal judgment prediction program integrated with guiding cases, when executed by the processor, implements the steps of the legal judgment prediction method integrated with guiding cases according to any one of claims 1-5.
Citation Information
Patent Citations
Similar case retrieval method, similar case retrieval device and electronic equipment
CN110928994A
Law decision prediction system based on multi-view encoder and method thereof
CN113505937A