Method and system for multi-charge legal judgment prediction based on knowledge-enhanced dialectical reasoning
Patent Information
- Application Number
- CN202610518740.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-04-20
- Publication Date
- 2026-09-22
- Estimated Expiration
- 2046-04-20
AI Technical Summary
[0006]本申请的目的在于提供一种基于知识增强辩证推理的多罪名法律判决预测方法及系统,以解决或缓解上述现有技术中存在的问题
本申请的技术方案提出一种通过知识增强辩证推理进行多罪名法律判决预测的技术框架(Knowledge-Augmented Dialectical Reasoning,简称KADR模型),KADR是专为单被告多罪名预测设计的知识增强框架,该框架通过辩证指控-抗辩-裁决长思维链推理模拟司法辩论,从对抗性角度将非结构化事实转化为罪名主张(控方)和争议问题(辩方)。随后,法律知识增强生成模块根据推理线索动态检索和对齐外部知识,在事实、要件和法律条文之间建立可追溯的映射。最后,模拟主审法官进行裁决,并由法律一致性校正模块对输出进行一致性校验和优化。在基于公开数据集CAIL2018的基准测试中进行的实验,结果表明,KADR优于基线模型,实现86.37的罪名微观F1值,证明该方案能够提高单被告多罪名判决预测的逻辑一致性和证据可追溯性,从整体上提升了推理性能。
Smart Images

Figure CN122390074B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the fields of legal artificial intelligence and natural language processing technology, and in particular to a method and system for predicting legal judgments for multiple crimes based on knowledge-enhanced dialectical reasoning. Background Technology
[0002] Legal Judicial Prediction (LJP) is a key technology in intelligent judicial systems. Its main goal is to automatically predict judgments based on the factual descriptions of cases using natural language processing (NLP). Existing research on legal judgment prediction mostly focuses on simple cases involving a single defendant and a single charge, employing discriminative or generative methods. Discriminative methods typically treat prediction as a multi-label classification task. While they show some effectiveness in standard benchmark tests, as black-box models, they lack the interpretability required for judicial transparency. To improve interpretability, generative methods have emerged that leverage the cognitive chain capabilities of large language models, treating the judgment framework as a conditional text generation process. Some methods also incorporate retrieval-enhanced generation techniques to integrate external legal knowledge.
[0003] However, in actual judicial practice, cases are often more complex, with cases involving a single defendant on multiple charges being a common and important scenario. For example... Figure 1 As shown, in such cases, the defendant typically commits crimes consecutively, thus violating multiple charges simultaneously, and there are complex temporal relationships and logical evolutions between different segments of the act (e.g., theft escalates into robbery due to the use of violence). When applying the aforementioned discriminative or generative methods to cases involving a single defendant and multiple charges, the following technical bottlenecks still exist: First, there is insufficient structural complexity and traceability of reasoning. Cases involving multiple charges involve complex temporal and semantic dependencies. Existing models lack a unified framework to represent the fine-grained connections between facts and legal provisions, making it difficult to maintain a traceable reasoning path and leading to frequent failures in distinguishing between primary and secondary charges.
[0004] Secondly, aligning fine-grained knowledge is difficult. The elements of a legal crime are usually abstract and scattered. Existing technologies struggle to achieve precise alignment between facts, elements, and legal provisions in complex contexts. This lack of alignment can easily lead to legal illusions, specifically manifested in predicting crimes without clear legal basis, or in logical inconsistencies between the cited legal provisions and the crimes, thus affecting the accuracy and reliability of judgment predictions.
[0005] Therefore, how to improve the traceability, accuracy, and reliability of judgment prediction in cases involving multiple charges against a single defendant is an urgent problem that needs to be solved by academia and industry. Summary of the Invention
[0006] The purpose of this application is to provide a method and system for predicting legal judgments for multiple crimes based on knowledge-enhanced dialectical reasoning, so as to solve or alleviate the problems existing in the prior art.
[0007] To achieve the above objectives, this application provides the following technical solution: This application provides a method for predicting legal judgments for multiple crimes based on knowledge-enhanced dialectical reasoning, including: Obtain the factual description of the case to be predicted; A multi-role reasoning chain is constructed to model the three stages of accusation, defense and adjudication. In the accusation and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual descriptions, respectively. Based on the set of candidate charges in the prosecution's argument The set of disputed issues in the defense's arguments The system constructs a multi-perspective query through a legal knowledge enhancement generation module, and retrieves a set of target legal provisions evidence that align with the candidate crime set and constituent elements from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. During the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions. The initial judgment tuple includes the charge, the applicable legal provisions, the sentence, and the reasons for the judgment. A consistency confidence score is calculated for the initial judgment tuple. If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the judgment is iteratively optimized using the supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold, or the maximum number of iterations is reached, the current judgment tuple is output as the final legal judgment result.
[0008] Preferably, during the indictment phase, the prosecution presents arguments and generates a set of candidate charges and their supporting evidence based on the factual description of the case, as follows: , In the formula, According to the prosecution, each From a candidate charge and its support points composition, For use in the prosecution role, a pre-trained large language model This represents the set of candidate crimes identified by the model. A factual description of the case. Indicates the number of candidate charges.
[0009] Preferably, during the defense phase, the defense presents rebuttal arguments, conducts adversarial analysis based on the facts of the case and the prosecution's claims, identifies potential loopholes in evidence and missing elements of the case, and the defense's output is expressed as follows: , In the formula, This indicates the defense's objection. Representative controversial issues, Indicates the size of the set of disputed issues. This indicates a rebuttal to a particular candidate charge. express The corresponding detailed reasons, A pre-trained large language model for use as the defense role.
[0010] Preferably, the set of candidate charges based on the prosecution's claim... The set of disputed issues in the defense's arguments By enhancing legal knowledge, multi-perspective queries are constructed, retrieving a set of target legal provisions from a structured legal knowledge base that align with the candidate crime set and its constituent elements, including: For each candidate crime in the candidate crime set, a multi-perspective query is constructed, which includes the crime, the constituent elements, and factual fragments semantically aligned with the constituent elements. Based on the multi-perspective query, a hybrid retrieval is performed in the structured legal knowledge base. The hybrid retrieval includes parallel sparse retrieval and dense retrieval to obtain a set of candidate legal provisions. The structured legal knowledge base stores triple data formed by mapping crime, elements of a crime, and legal provisions. The relevance score between the multi-view query and each candidate legal provision in the candidate legal provision set is calculated using a pre-trained reordering model, and the candidate legal provision set is reordered based on the relevance score. The top K legal provisions after reordering are selected as evidence of the target legal provisions.
[0011] Preferably, the correlation score is calculated using the following formula: , In the formula, For the multi-perspective query corresponding to candidate crime c. As candidate legal provisions, for and The correlation score between them This indicates the context embedding of the [CLS] token from the concatenated input. , For cross encoders, It is a learnable weight vector. for transpose, This represents the Sigmoid activation function.
[0012] Preferably, the pre-trained reordering model is a cross-encoder, and the training process of the cross-encoder includes: A training set is constructed based on the structured legal knowledge base, and a hard negative sampling strategy is used to construct positive and negative sample pairs. Among them, the legal provisions corresponding to the crime are regarded as positive samples, and negative samples are sampled from the legal provisions of other crimes. The negative samples are similar to but do not match the positive samples in terms of the constituent elements. The cross encoder is optimized by minimizing the binary cross-entropy loss function.
[0013] Preferably, during the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions; including: The factual description, the prosecution's claims, the defense's arguments, and the evidence related to the target legal provisions are input as joint inputs into a pre-trained language model simulating the role of a presiding judge; the pre-trained language model then processes the set of disputed issues. For each disputed element, a legal provision definition query is performed; if the evidence of the target legal provision supports the disputed element, a judgment reasoning that cites the relevant provisions and adopts the defense's argument is generated; if the factual description supports the prosecution's claim and does not violate legal constraints, a judgment reasoning that rejects the defense's argument is generated. Based on the stated reasons for the judgment, an initial judgment tuple is generated, containing the crime, applicable legal provisions, sentence, and the stated reasons for the judgment.
[0014] Preferably, the consistency confidence score is obtained by weighted summation of the legal provision integrity score, the element alignment score, and the structural integrity score; The formula for calculating the integrity score of the legal provisions is as follows: , The formula for calculating the element alignment score is as follows: , The formula for calculating the structural integrity score is as follows: , In the formula, For the iteration step, Score for completeness of legal provisions. Scoring for element alignment Score for structural integrity This is an indicator function; it returns 1 if the condition is true, and 0 otherwise. For the first The corresponding set of candidate charges for One of the candidate charges, For the first Step-by-step application of legal provisions For the structured legal knowledge base and candidate charges The corresponding set of normative legal provisions, as a candidate charge Corresponding multi-view queries, As candidate legal provisions, for and The correlation score between them For the legal provisions evidence at step 0 of the reasoning process, For a predefined set of key fields, This is a key field in K. Indicates the first The decision generated step by step in the iteration express Corresponding fields The content.
[0015] Preferably, if the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the decision is iteratively optimized using the supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached, including: Based on the evaluation results of the initial decision tuples and consistency confidence scores, the diagnostic query is synthesized using a pre-trained language model; The diagnostic query is used to perform a retrieval in the structured legal knowledge base to obtain the supplementary evidence; The fact description, the decision tuple generated in the previous iteration, the diagnostic query, and the supplementary evidence are input into the pre-trained language model to generate the updated decision tuple for the current iteration. Recalculate the consistency confidence score of the updated decision tuple, and use the updated decision tuple and its consistency confidence score as the input for the next iteration, until the consistency confidence score reaches the preset threshold or the preset maximum number of iterations is reached; The update decision tuple for generating the current iteration is represented as follows: , In the formula, , Indicates the first , The decision generated step by step in the iteration A factual description of the case. For diagnostic queries, To supplement evidence.
[0016] This embodiment provides a multi-crime legal judgment prediction system based on knowledge-enhanced dialectical reasoning. This system is used to execute the steps of the multi-crime legal judgment prediction method based on knowledge-enhanced dialectical reasoning provided in any of the above embodiments, including: The acquisition unit is configured to acquire factual descriptions of the case to be predicted. The prosecution and defense extraction unit is configured to construct a multi-role reasoning chain to model the three stages of prosecution, defense and adjudication. In the prosecution and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual description, respectively. Alignment unit, configured based on the set of candidate charges in the prosecution's claim. The set of disputed issues in the defense's arguments By enhancing legal knowledge, a multi-perspective query is constructed, and target legal provisions that align with the candidate crime set and constituent elements are retrieved from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. The adjudication unit is configured to, during the adjudication phase, generate an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions, using the multi-role reasoning chain. The initial judgment tuple includes the charge, the applicable legal provision, the sentence, and the reasoning for the judgment. A consistency confidence score is calculated for the initial judgment tuple. If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the judgment is iteratively optimized using this supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold, or the maximum number of iterations is reached, the current judgment tuple is output as the final legal judgment result.
[0017] The technical solution of this application embodiment has the following beneficial effects: This application proposes a technical framework for predicting legal judgments involving multiple charges through knowledge-augmented dialectical reasoning (KADR model). KADR is a knowledge-augmented framework specifically designed for predicting multiple charges against a single defendant. This framework simulates judicial debate through a long thought chain of dialectical indictment-defendant-judgment reasoning, transforming unstructured facts into charges (prosecution) and disputed issues (defendant) from an adversarial perspective. Subsequently, a legal knowledge enhancement generation module dynamically retrieves and aligns external knowledge based on reasoning clues, establishing a traceable mapping between facts, elements, and legal provisions. Finally, a presiding judge is simulated to make a judgment, and a legal consistency correction module performs consistency verification and optimization on the output. Experiments conducted on the public dataset CAIL2018 benchmark show that KADR outperforms the baseline model, achieving a micro F1 score of 86.37 for each charge, demonstrating that this scheme can improve the logical consistency and evidence traceability of predicting multiple charges against a single defendant, thus improving overall reasoning performance. Attached Figure Description
[0018] Figure 1 This is a logical diagram for a case involving a single defendant and multiple charges.
[0019] Figure 2 This is a schematic diagram of the overall architecture of the KADR model.
[0020] Figure 3 A diagram visualizing KADR's internal reasoning process in multi-charge cases. Detailed Implementation
[0021] The embodiments of this application will now be described with reference to the accompanying drawings.
[0022] Example 1 This embodiment provides a method for predicting legal judgments for multiple offenses based on knowledge-enhanced dialectical reasoning. The method includes: Obtain the factual description of the case to be predicted; A multi-role reasoning chain is constructed to model the three stages of accusation, defense and adjudication. In the accusation and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual descriptions, respectively. Based on the set of candidate charges in the prosecution's argument The set of disputed issues in the defense's arguments The system constructs a multi-perspective query through a legal knowledge enhancement generation module, and retrieves a set of target legal provisions evidence that align with the candidate crime set and constituent elements from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. During the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions. The initial judgment tuple includes the charge, the applicable legal provisions, the sentence, and the reasons for the judgment. A consistency confidence score is calculated for the initial judgment tuple. If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the judgment is iteratively optimized using the supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold, or the maximum number of iterations is reached, the current judgment tuple is output as the final legal judgment result.
[0023] In this embodiment, a multi-role reasoning chain is constructed to transform unstructured facts into charges and disputed issues from an adversarial perspective. Then, a legal knowledge enhancement generation module dynamically retrieves and aligns external knowledge (provided by a structured legal knowledge base) based on the reasoning clues, establishing a traceable mapping between facts, elements, and legal provisions. Finally, a simulated presiding judge makes a ruling, and a legal consistency correction module verifies and refines the output. This achieves accurate prediction of potential charges and their corresponding applicable legal provisions based on complex case facts, while ensuring strict logical consistency and traceability of evidence between fact-finding, elements of a crime, and application of legal provisions.
[0024] This embodiment extracts structured prosecution claims and defense arguments at the indictment and defense stages, respectively, enabling the model to explicitly model complex temporal relationships and logical evolutions in multi-crime cases (such as the transformation from theft to robbery), providing traceable facts and disputed evidence for subsequent reasoning. Based on this, a legal knowledge-enhanced generation module constructs multi-perspective queries and relies on a pre-stored structured legal knowledge base mapping crimes, elements of a crime, and legal provisions. This achieves fine-grained and precise alignment between case facts and abstract legal elements, mitigating the legal illusion caused by misalignment, such as crime prediction lacking legal basis or inconsistencies between crimes and provisions. At the adjudication stage, a judgment tuple containing the crime, applicable legal provisions, sentence, and reasoning is generated, and its consistency confidence score is calculated. When the score falls below a threshold, a diagnostic query is automatically generated to retrieve supplementary evidence and iteratively optimize until consistency requirements are met or the maximum number of iterations is reached. This improves the traceability, accuracy, and reliability of the judgment, especially effectively distinguishing between primary and secondary crimes, ultimately outputting a judgment with sufficient legal basis, logical consistency, and traceability.
[0025] The technical implementation process of this embodiment will be described in detail below.
[0026] In this embodiment, the factual description of the case to be predicted is text data recorded in natural language form, reflecting the complete case process of a single defendant with multiple charges. For example, the factual description can be collected from the indictment, the public security organ's indictment opinion, the court transcript, or the portion of the judgment that has been investigated and verified in judicial practice. Methods for obtaining the factual description of the case to be predicted may include: providing a text input box through a graphical user interface for users to directly paste or type in the case factual text; receiving a file containing the factual description (such as TXT, DOCX, or PDF format) through a file upload interface; obtaining structured or semi-structured case fact fields in JSON or XML format from an external case management system or database through an application programming interface (API) and concatenating them into a complete natural language description; or obtaining them in batches from publicly available legal document websites through a data import tool.
[0027] For ease of description, this application defines the judgment prediction task for single-defendant, multi-charge cases (multiple charges against a single defendant) in the following formal form: Definition 1 (Decision Prediction Task): Given a factual description of the case to be predicted ,in, These are key factual fragments.
[0028] The objective of this application is to predict decision tuples. .here, and These respectively represent the set of candidate charges and the set of applicable legal provisions; Represents the length of the sentence; This represents the explanatory reasons for the judgment.
[0029] In the reasoning steps At that time, the model state is defined as: (1) In the formula, , representing the reasoning steps The overall consistency confidence score (referred to as confidence score).
[0030] like Figure 2 As shown, in this embodiment, a multi-role reasoning chain is constructed to model the three stages of accusation, defense, and adjudication. This multi-role reasoning chain is also known as the dialectical accusation-defense-adjudication long thought chain reasoning, abbreviated as D-CoT.
[0031] In real-world criminal cases, the prosecution and defense engage in adversarial exchanges regarding the facts of the case, gradually clarifying the elements constituting a crime, and the collegial panel ultimately renders a legally consistent judgment. In this embodiment, KADR abstracts this judicial reasoning process into a multi-role reasoning chain, called dialectical collaborative reasoning. Using input sequence prompts in a pre-trained big oracle model, the multi-role reasoning chain plays multiple roles—prosecution, defense, and presiding judge—to model the three stages of accusation, defense, and judgment. It extracts structured prosecution claims and defense arguments from the factual descriptions, generating structured intermediate representations for the legal knowledge enhancement generation module and the legal consistency correction module.
[0032] Specifically, the multi-role reasoning chain begins in the accusation phase. In the accusation phase, the prosecution, as the party providing arguments, bases its arguments on the facts. The candidate charges and their supporting arguments are generated as follows: (2) In the formula, This indicates the prosecution's output (the prosecution's claim). This represents the set of candidate crimes identified by the model. Indicates the first One candidate charge, express The corresponding support point, each From a candidate charge and its support points The binary structure consists of key factual fragments extracted from the factual description and elements related to the candidate charges. The relevant elements are used to support the charge of the crime both at the factual and legal levels.
[0033] For example, supporting evidence for a charge of "robbery" may include key factual elements such as "the defendant used violent means" and "the defendant robbed the property on the spot," as well as elements of the crime such as "with the intent of illegal possession" and "the defendant used violence and coercion on the spot."
[0034] This pre-trained large language model, designed for the prosecution role, allows the prosecution to automatically generate structured prosecution arguments based on case facts, providing clear evidence for charges in subsequent defense and adjudication stages.
[0035] Those skilled in the art will understand that the large language model can be any general-purpose large model with text generation and reasoning capabilities (e.g., DeepSeek-V3), and its output can be made to conform to the above-mentioned tuple format through prompting engineering.
[0036] In this embodiment, during the defense phase, a multi-role reasoning chain simulates the defense role to raise counterarguments and receive facts. and the prosecution's claims This involves adversarial analysis to identify circular evidence (e.g., relying on the same factual fragment to repeatedly argue different charges) and potential deficiencies in the elements of a charge, such as a lack of corresponding support in the factual description for the legal elements upon which a candidate charge depends. The defense's output is formalized as follows: (3) In the formula, This indicates the defense's output (the defense's objection). Representative controversial issues, Indicates that it applies to a specific crime (such as Counterarguments (such as negating or mitigating the claim), It indicates detailed reasons for the rebuttal, such as insufficient evidence or failure to meet the requirements.
[0037] in, For the defense role, a pre-trained large language model, such as DeepSeek-V3, can be the same as the model used by the prosecution. They can be the same, or they can use separate instances.
[0038] Through the aforementioned adversarial mining, the defense role can generate structured rebuttals, providing points of contention for the adjudication stage, thereby enhancing the dialectical nature and traceability of the judgment reasoning.
[0039] At the end of the defense phase, this technical solution has clearly constructed a set of candidate charges. and Controversial Issues Conflict between them.
[0040] Because relying solely on the parameter memory of large language models cannot guarantee consistency between legal citations and the elements constituting a crime, this issue needs to be addressed by obtaining a set of candidate crimes. and Controversial Issues Subsequently, this application designed a legal knowledge enhancement generation module (hereinafter referred to as Legal-KAG), which generates legal knowledge based on a set of candidate crimes. and Controversial Issues Construct multi-perspective queries and map them onto a structured legal knowledge base (such as Kanons). Then, build an evidence set through retrieval, reordering, and alignment mapping processes. This is known as the target legal provision evidence set, which provides a traceable basis for the presiding judge's decision.
[0041] The above process is referred to as the structured knowledge and dynamic retrieval process, which specifically includes the following sub-steps: Targeting the set of candidate charges Each candidate crime Construct multi-perspective queries; Based on multi-perspective queries, a hybrid retrieval is performed in the structured legal knowledge base. The hybrid retrieval includes parallel sparse retrieval and dense retrieval to obtain a set of candidate legal provisions. The structured legal knowledge base stores triple data formed by mapping crime, elements of a crime, and legal provisions. A pre-trained reordering model is used to calculate the relevance score between the multi-view query and each candidate legal provision in the candidate legal provision set, and the candidate legal provision set is reordered according to the relevance score. Select the top K legal provisions after reordering as evidence of the target legal provisions.
[0042] The following section provides a more detailed explanation of structured knowledge and the dynamic retrieval process.
[0043] First, to support fine-grained legal reasoning, this embodiment constructs a structured legal knowledge base, called the Kanons Knowledge Base. Its construction includes four stages: First, regulatory standardization is implemented by parsing existing legal norms (such as the Criminal Law of the People's Republic of China) into a structured database. Based on this, a Large Language Model (LLM) is used for pattern injection and element extraction, mapping legal texts (hereinafter referred to as legal provisions) into a triple: ⟨crime, elements of a crime, legal provision>. The elements of a crime further encompass legal factors such as behavioral patterns, monetary standards, and the legal capacity of the perpetrator. Finally, the LLM is manually corrected for illusions and ambiguities in the one-to-many crime-to-legal-text mapping.
[0044] Then, based on the adversarial arguments presented by the prosecution and defense, the legal knowledge enhancement module generates a list of potential charges for each candidate crime. Build a query Because it considers both the prosecution's and defense's perspectives, it is called a multi-perspective query. This query includes the normative crime, key elements of the crime phrases, and factual fragments semantically aligned with these elements. Specifically, the legal knowledge enhancement module will incorporate the prosecution's arguments... Opinions of the defense The queries are merged to generate a unified query organized in JSON format. This is for subsequent retrieval and rearrangement. Based on the foregoing explanation, the prosecution argues... This includes the candidate charges and supporting arguments, which include factual details and elements of the crime. Similarly, the defense's arguments... It also includes rebuttal arguments and detailed reasons for the rebuttals, thus combining the two to obtain a multi-perspective query. It includes the standard crime name, key elements phrases, and factual fragments semantically aligned with the key elements phrases.
[0045] In this embodiment, during the construction Subsequently, the retrieval process employs a hybrid retrieval strategy, performing sparse and dense searches in parallel to obtain a set of candidate legal provisions. Specifically, the sparse search utilizes the BM25 algorithm to process the query... Initial lexical matching is performed against legal provisions in the Kanons knowledge base to obtain sparse search results, which are collections of legal provisions. Dense search employs a dual-tower vector search engine, Qwen-Embedding-0.6B, finely tuned in the legal domain, to retrieve the query. The legal provision triples in the Kanons knowledge base are mapped to the same high-dimensional vector space. Cosine similarity is calculated to recall semantically related legal provisions, resulting in a dense search result, which is also a set of several legal provisions. Subsequently, all legal provisions obtained from sparse and dense searches are merged and deduplicated to form a preliminary candidate set, denoted as . To bridge the gap between lexical matching and latent semantic relevance, a re-ranking model is used to re-rank the entries in the initial candidate entry set, resulting in a re-ranked list. The re-ranking model is used to compute the query. With candidate legal provisions Correlation score between And then reorder them, as shown below: (4) In the formula, This is the relevance score, also known as the rearrangement score. This indicates the context embedding of the [CLS] token from the concatenated input. , It is a learnable weight vector. for transpose, This represents the Sigmoid activation function. This is a cross-encoder, whose base model is also called a reordering model. bge-reranker-v2-m3 can be used as the base model, fine-tuned, and then applied to the concatenated sequence. Full-text modeling is performed to capture fine-grained semantic interactions between factual fragments and legal provisions.
[0046] To ensure the cross-encoder's ability to distinguish confusing legal provisions, this application employs a knowledge-based hard negative sampling training strategy to fine-tune the cross-encoder. Specifically, the training process includes: constructing a training set based on a structured legal knowledge base and constructing positive and negative sample pairs using a hard negative sampling strategy; wherein, legal provisions corresponding to the crime are considered positive samples (positive examples), and negative samples are sampled from legal provisions of other crimes, and the negative samples are similar to but do not match the positive examples in terms of their constituent elements; the cross-entropy loss function is used to optimize the cross-entropy encoder by minimizing the relevance score of the positive examples and minimizing the relevance score of the negative examples.
[0047] In this embodiment, the training set of the cross-encoder is constructed based on a structured legal knowledge base. Specifically, it is based on the Kanons knowledge base triples ⟨crime, elements of a crime, legal provisions>, with the core legal provisions corresponding to the crime being regarded as positive samples. The negative sample set is sampled from the core legal provisions of other crimes, which are similar but do not match in key elements, and are denoted as... The model is optimized by minimizing the following binary cross-entropy loss: (5) In the formula, It is the constructed training set.
[0048] It should be noted that positive samples With negative samples Similar but mismatched elements of a crime refer to negative example legal provisions selected from a legal knowledge base. While the corresponding crimes may differ from the candidate crimes targeted in the current query, they share a high degree of similarity or structural comparability in the core elements of the crime's constitution. Specifically, the crimes corresponding to the negative example provisions overlap or are similar to the candidate crimes in key legal factors such as behavioral patterns, subjective intent, objective consequences, or the qualifications of the perpetrator. For example, both "robbery" and "theft" involve the illegal acquisition of another's property and may both include characteristics such as violence or coercion. However, their legal elements differ fundamentally, such as whether the violence reaches the level of suppressing resistance. By introducing such similar but mismatched elements as negative examples, the re-ranking model can be forced to learn the subtle boundaries of the application of legal provisions between crimes, thereby enhancing its ability to distinguish easily confused legal provisions and avoiding erroneous legal citations or crime predictions due to superficial similarities in the elements of a crime.
[0049] Take the top K (TOP-K, e.g., K=5) from the reordering results as the initial legal strip evidence set. In other words, the evidence is the target legal provision. Because the finely tuned cross-encoder can sensitively capture subtle differences in the constituent elements, the final evidence set... Achieve precise alignment with the facts of the case.
[0050] As the comprehensive stage of the dialectical reasoning chain (the adjudication stage), the core task of the presiding judge is, under the constraints of legal provisions provided by enhanced legal knowledge, to address the adversarial arguments of both the prosecution and the defense (the prosecution's claims) based on evidence and factual descriptions. and the defense's arguments The process involves logical convergence and adjudication to generate an initial judgment tuple, including: inputting the factual description, prosecution's claims, defense's arguments, and evidence of the target legal provisions as joint input into a pre-trained language model simulating the role of the presiding judge; and then processing the set of disputed issues through the pre-trained language model. For each disputed element, a legal provision definition query is performed; if the evidence of the target legal provision supports the disputed element, a judgment reasoning that cites the relevant provision and adopts the defense's argument is generated; if the factual description supports the prosecution's claim and does not violate legal constraints, a judgment reasoning that rejects the defense's argument is generated; based on the judgment reasoning, a judgment tuple containing the charge, applicable legal provision, sentence, and judgment reasoning is generated. This means generating the initial panel judgment.
[0051] Unlike the one-way perspectives of the prosecution and defense, in the adjudication stage, the presiding judge (a role held by an LLM) reasons step by step. Begin by receiving a description of the facts of the case. Adversarial reasoning chain Evidence of legal provisions As a combined input, it generates the initial panel judgment. The initial judgment tuple, which includes the conviction, sentence, and complete reasoning (i.e., the explanatory grounds for the judgment), is expressed as follows: (6) In the formula, LLM represents the large language model that acts as the presiding judge.
[0052] In this step, the presiding judge (i.e., the LLM) generates the interpretable reasoning for this round of iterations through the following logic. Regarding each element in dispute raised in the defense's statement: (i.e., the defense's arguments), the presiding judge inquired. The definition of legal provisions in the law, if the retrieved legal evidence clearly supports the defense's boundary standards, The relevant clauses will be cited to adopt the defense's arguments; conversely, if the facts are described... If the prosecution's claims are strongly supported and do not violate strict legal constraints, the defense's objections shall be rejected.
[0053] KADR introduces a Legal Consistency Correction (LCC) module at the end of the judgment reasoning workflow, which aims to perform systematic consistency checks and necessary local refinements based on the generated panel judgment.
[0054] First, let's explain the confidence assessment and triggering mechanism.
[0055] After the deliberation of the collegial panel, the presiding judge (6) made a preliminary judgment. At the same time, generate a Overall confidence score at time Also known as the consistency confidence score, this confidence score consists of deterministic structure checks and retrieval of alignment signals, thereby ensuring interpretability.
[0056] The following explains the calculation process of the consistency confidence score. This embodiment will describe the reasoning steps. The confidence level is defined as the weighted sum of the three scores: (7) In the formula, Indicates the reasoning step Time balance legal integrity index Indicates the reasoning step Time element alignment index Indicates the reasoning step Time structure integrity index, , =1,2,3 are hyperparameters used to balance the integrity of legal provisions, element alignment, and structural integrity. For example, they can be set to... .
[0057] Among them, the completeness of legal provisions This is used to assess whether a candidate charge is supported by applicable legal provisions. Based on the canonical mapping provided by the Kanons knowledge base, let... For the knowledge base and candidate charges The corresponding set of normative legal provisions, The calculation formula is as follows: (8) In the formula, This is an indicator function; it is 1 if the condition is true, and 0 otherwise.
[0058] Element Alignment Evidence used to quantify whether the generated charges and their constituent elements (requirements) have been retrieved. The full support is shown in Formula (9), for each predicted candidate crime. Take the maximum rearranged score from the query. And normalize it: (9) Structural integrity This is used to ensure that the model output has a basic structure that is interpretable and traceable. Define a set of mandatory key fields. {Criminal Charge, Legal Provision, Sentencing, Reasoning}, this indicator is used as a binary hard constraint: (10) In the formula, Is it a mandatory key field? Any keyword in Indicates multiplication. Indicates the judgment Corresponding fields The content of this formula. This formula is used to check the inference step. Does the generated judgment contain mandatory key fields? The determination of the required information fields is made if and only if all mandatory key fields are not empty. It satisfies structural integrity.
[0059] Problem-driven closed-loop optimization: The LCC module operates as a gating mechanism, using confidence scores. This serves as a gate to trigger iterative optimization. Specifically, it is triggered whenever the confidence level falls below a predefined threshold. When the model triggers a problem-guided optimization phase, the following steps are executed: Based on the evaluation results of the initial decision tuples and consistency confidence scores, a diagnostic query is synthesized using a pre-trained language model; the diagnostic query indicates the direction of legal knowledge that needs to be supplemented; the diagnostic query is used to perform a search in the structured legal knowledge base to obtain supplementary evidence; the fact description, the decision tuples generated in the previous iteration, the diagnostic query, and the supplementary evidence are input into the pre-trained language model to generate the updated decision tuples for the current iteration; the consistency confidence score of the updated decision tuples is recalculated, and the updated decision tuples and their consistency confidence scores are used as input for the next iteration until the consistency confidence score reaches a preset threshold or the preset maximum number of iterations is reached.
[0060] Specifically, in the optimization phase, starting from a reasoning step of 0 ( The iteration begins, with the pre-trained large language model calculating outliers (i.e., those with confidence scores below a predefined threshold) based on the initial decision tuples, including the legal provision integrity score and feature alignment score. The system generates natural language instructions (prompts) with clear retrieval guidance based on the facts of the case; these are diagnostic queries. Semantically, these queries include guiding information such as missing legal elements or conflicting legal provisions. The diagnostic query is then input into the aforementioned finely tuned dual-tower vector retrieval system (Qwen-Embedding-0.6B) for targeted searching and mining in the Kanons knowledge base to obtain supplementary evidence. Finally, the factual description, the judgment tuple generated in the previous iteration, the diagnostic query, and the supplementary evidence are input into a pre-trained language model to generate the updated judgment tuple for the current iteration. Update the decision state using the minimum necessary corrections: (11) In the formula, Indicates the first The decision generated step by step in the iteration A factual description of the case. For diagnostic queries, To supplement evidence.
[0061] Recalculate the consistency confidence score of the updated decision tuple. If the new consistency confidence score is still below the threshold... New diagnostic queries and supplementary evidence are then generated again, and these new queries and supplementary evidence are used as input for the next round of iteration optimization. This process continues until the consistency confidence score reaches a preset threshold. Or reach the preset maximum number of iterations. This ensures that the output maintains high logical consistency while keeping the initial inference chain valid.
[0062] It should be noted that if the reasoning step At that time, the initial panel of judges ruled The consistency confidence score satisfies If the result is not found, the decision will be output directly without entering the iterative optimization stage.
[0063] Verification Example First, a high-quality benchmark case library was built based on the publicly available dataset CAIL2018. The construction process followed three criteria: (1) focusing on a single defendant to eliminate ambiguity caused by accomplices; (2) multi-charge constraints. (3) Factual integrity and alignable citations of legal provisions. After manual verification and strict deduplication, 1000 non-overlapping cases were selected for testing.
[0064] To train the dual-tower vector retrieval engine (Qwen-Embedding-0.6B), this application also prepares a separate corpus containing 14,000 training samples and 1,000 validation samples, specifically for validating the framework's generalization ability in complex scenarios. Statistical information is detailed in Table 1.
[0065] Table 1. Dataset Statistics
[0066] The experimental setup is as follows: The complete case context is processed by calling DeepSeek-V3 (LLM) via API (temperature=0.2, highest probability=0.95). For Legal-KAG, the top 20 candidates are retrieved via BM25 and then reordered by a fine-tuned cross-encoder (bge-reranker-v2-m3, batch size=16) fused with Qwen-Embedding-0.6B to select the final top 5 legal provisions. This reordering model demonstrates strong performance with a hit@1 of 0.963 and an average reciprocal rank of 1.000 on the validation set. Finally, in the Legal Consistency Correction (LCC) module, the threshold is set as follows: When confidence level Below At that time, the problem-guided optimization phase is triggered, in which the threshold is... The optimal balance between consistency guarantees and re-inspection overhead can be achieved empirically by determining this on the validation set.
[0067] Table 2. Role definitions and prompting logic in D-CoT.
[0068]
[0069] To verify the effectiveness of KADR in predicting multiple charges against a single defendant, the KADR model provided in this embodiment was comprehensively compared with three mainstream baselines: The first type of baseline, discriminative methods, models decision prediction as a multi-label classification task. TextCNN was chosen, which utilizes convolutional kernels of varying sizes to extract key local features. Legal-BERT was also incorporated, using RoBERTa as its encoding backbone to enhance Chinese semantic representation capabilities.
[0070] The second type of baseline, generative reasoning methods, utilizes the generative capabilities of language models. Zero-Shot CoT and Standard CoT were used as baselines compared to the model in this application. The former directly generates output based on instructions, while the latter guides the model through thought chain cues.
[0071] The third baseline category comprises retrieval enhancement generation methods: a comparison of Standard Retrieval Enhancement Generation (Standard RAG), Language Structured Retrieval Enhancement Generation (LSP-RAG), and the Legal Reasoning and Generative Model Based on Behavior-Driven Retrieval (CADLRA). It should be noted that CADLRA is a cutting-edge method specifically designed for multi-crime scenarios; it is a retrieval enhancement generation method based on criminal behavior, its core being the retrieval of legal provisions after summarizing unstructured facts using LLM. However, this existing technology exhibits a significant logical one-wayness and cannot handle the complex evolution of charges and factual disputes in cases involving multiple charges against a single defendant.
[0072] To ensure fairness, all generative baseline models (including Zero-Shot CoT, Standard CoT, Standard RAG, LSP-RAG, and CADLRA, a legal reasoning and generative model based on behavior-driven retrieval) are uniformly loaded with the same DeepSeek V3 as the underlying backbone model (i.e., LLM) as KADR.
[0073] The experimental results are shown in Table 3, which is as follows: Table 3. Performance of Crime and Legal Provision Prediction
[0074] In Table 3, P (Precision) represents precision, R (Recall) represents recall, and F1 (F1 Score) represents the F1 score. The relevant calculation formulas can be found in existing technologies and will not be elaborated here. Table 3 shows that different paradigms exhibit significant performance differences. First, discriminative models (TextCNN, Legal-BERT) show high precision but low recall. Although Legal-BERT outperforms TextCNN, both rely on semantic matching, making it difficult to explicitly model deep dependencies between facts and legal provisions. Their conservative output limits recall for complex constituent elements. Second, purely generative models (thought chains) face parameter memory limitations. Due to a lack of external knowledge, they often generate seemingly reasonable but unfounded data illusions, making it difficult to balance precision and recall. Third, retrieval-enhanced generative baselines are affected by retrieval noise. Although behavior-driven retrieval-based legal reasoning and generative models improve recall through behavior-driven retrieval, the expanded candidate set introduces noise, leading to a trade-off where recall increases at the expense of precision. In contrast, KADR achieves the best micro-F1 score. The above results indicate that by clarifying disputes through Dialectical Accusation-Defense-Adjudication Long Thinking Chain Reasoning (D-CoT) and by constraining the output to traceable evidence through Legal Knowledge Enhancement Generation (Legal-KAG) and Legal Consistency Correction (Legal Provision Comparison, i.e., LCC), KADR effectively balances precision and recall.
[0075] To verify the effectiveness of each core component within the KADR framework and its contribution to legal logic consistency, an ablation experiment was designed by individually removing the D-CoT, Legal-KAG, and LCC modules. An in-depth analysis was conducted from three dimensions: prediction performance, logical integrity, and inference overhead. The ablation experiment results are shown in Table 4. Table 4. Ablation Test Results
[0076] In the table, w / o indicates the removal of a specific module.
[0077] As shown in Table 4, removing any module leads to a significant drop in the F1 score. With / o LCC: Removing LCC, although the crime classification rate remained around 60%, the accuracy of legal provision predictions decreased significantly, indicating that LCC is crucial for correcting structural errors.
[0078] Simply relying on the F1 score cannot comprehensively assess judicial reliability. Therefore, in the ablation experiment, the proportion of two serious logical defects occurring based on the consistency of evidence was assessed: (1) unfounded charges, referred to as "not supported", and (2) mismatch of legal provisions, referred to as "mismatch". The occurrence of either of the above two defects was recorded as "any error". The results of the ablation experiment are shown in Table 5. Table 5 is as follows: Table 5. Evidence-based consistency analysis (lower percentage is better)
[0079] The results in Table 5 show that the "any error" rate significantly decreased from 10.91% (without D-CoT) to 3.60% (complete model). This demonstrates that the model effectively clarified complex relationships through the arguments of both the prosecution and the defense. Furthermore, the LCC module reduced the "no support" accusation to 0.40%, confirming that the confidence gating mechanism effectively intercepted illusions.
[0080] Furthermore, to demonstrate the role of KADR in determining the boundaries of multiple offenses, a case involving the distinction between completed and attempted crimes is selected for visual analysis, such as... Figure 3 As shown, the key point of contention in this case lies in whether the conduct corresponding to fact 3 constitutes an attempt, thus affecting the matching of elements of the charge and the basis for sentencing. KADR raised the issue of attempt through the chain of charges and defenses, and after verification, retrieved supplementary provisions regarding attempt. Ultimately, it aligned the elements with the legal basis, arriving at a consistent judgment.
[0081] In summary, this embodiment proposes the KADR model, an interpretable framework for predicting multiple charges against a single defendant. It integrates dialectical thinking, enhanced legal knowledge generation, and legal consistency correction to improve logical consistency and evidentiary traceability. Experiments on the CAIL dataset demonstrate that KADR significantly improves performance by effectively intercepting structural logic defects.
[0082] Based on the same inventive concept, this application also provides a multi-crime legal judgment prediction system based on knowledge-enhanced dialectical reasoning. This system is used to execute the steps of the multi-crime legal judgment prediction method based on knowledge-enhanced dialectical reasoning provided in any of the above embodiments, including: The acquisition unit is configured to acquire factual descriptions of the case to be predicted. The prosecution and defense extraction unit is configured to construct a multi-role reasoning chain to model the three stages of prosecution, defense and adjudication. In the prosecution and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual description, respectively. Alignment unit, configured based on the set of candidate charges in the prosecution's claim. The set of disputed issues in the defense's arguments By enhancing legal knowledge, a multi-perspective query is constructed, and target legal provisions that align with the candidate crime set and constituent elements are retrieved from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. The adjudication unit is configured to, during the adjudication phase, generate an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions, using the multi-role reasoning chain. The initial judgment tuple includes the charge, the applicable legal provision, the sentence, and the reasoning for the judgment. A consistency confidence score is calculated for the initial judgment tuple. If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the judgment is iteratively optimized using this supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold, or the maximum number of iterations is reached, the current judgment tuple is output as the final legal judgment result.
[0083] The multi-crime legal judgment prediction system based on knowledge-enhanced dialectical reasoning provided in this embodiment can implement the steps and processes of the multi-crime legal judgment prediction method based on knowledge-enhanced dialectical reasoning provided in any of the above embodiments, and achieve the same technical effect, which will not be elaborated here.
[0084] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. A method for predicting legal judgments involving multiple charges based on knowledge-enhanced dialectical reasoning, characterized in that, Includes the following steps: Obtain the factual description of the case to be predicted; A multi-role reasoning chain is constructed to model the three stages of accusation, defense and adjudication. In the accusation and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual descriptions, respectively. Based on the set of candidate charges in the prosecution's argument The set of disputed issues in the defense's arguments The system constructs a multi-perspective query through a legal knowledge enhancement generation module, and retrieves a set of target legal provisions evidence that align with the candidate crime set and constituent elements from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. During the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims and the defense's arguments, as well as the evidence of the target legal provisions; the initial judgment tuple includes the charge, the applicable legal provisions, the sentence, and the reasons for the judgment; Calculate the consistency confidence score of the initial judgment tuple. If the consistency confidence score is less than a preset threshold, generate a diagnostic query to retrieve supplementary evidence and use the supplementary evidence to iteratively optimize the judgment until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold or the maximum number of iterations is reached, output the current judgment tuple as the final legal judgment result. During the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions; including: The factual description, the prosecution's claims, the defense's arguments, and the evidence related to the target legal provisions are input as joint inputs into a pre-trained language model simulating the role of a presiding judge; the pre-trained language model then processes the set of disputed issues. For each disputed element, a legal provision definition query is performed; if the evidence of the target legal provision supports the disputed element, a judgment reasoning that cites the relevant provisions and adopts the defense's argument is generated; if the factual description supports the prosecution's claim and does not violate legal constraints, a judgment reasoning that rejects the defense's argument is generated. Based on the stated reasons for the judgment, an initial judgment tuple is generated, containing the crime, applicable legal provisions, sentence, and stated reasons for the judgment. The consistency confidence score is obtained by weighted summation of the legal provision integrity score, the element alignment score, and the structural integrity score. The formula for calculating the integrity score of the legal provisions is as follows: , The formula for calculating the element alignment score is as follows: , The formula for calculating the structural integrity score is as follows: , In the formula, For the iteration step, Score for completeness of legal provisions. Scoring for element alignment Score for structural integrity This is an indicator function; it returns 1 if the condition is true, and 0 otherwise. For the first The corresponding set of candidate charges for One of the candidate charges, For the first Step-by-step application of legal provisions For the structured legal knowledge base and candidate charges The corresponding set of normative legal provisions, as a candidate charge Corresponding multi-view queries, As candidate legal provisions, for and The correlation score between them For the first Legal evidence during each iteration For a predefined set of key fields, This is a key field in K. Indicates the first The decision generated step by step in the iteration express Corresponding fields The content.
2. The method according to claim 1, characterized in that, During the indictment phase, the prosecution presents its arguments and generates a set of candidate charges and supporting evidence based on the facts of the case, as shown below: , In the formula, According to the prosecution, each From a candidate charge and its support points composition, For use in the prosecution role, a pre-trained large language model This represents the set of candidate crimes identified by the model. A factual description of the case. Indicates the number of candidate charges.
3. The method according to claim 2, characterized in that, During the defense phase, the defense presents rebuttal arguments, conducts adversarial analysis based on the facts of the case and the prosecution's claims, identifies potential loopholes in evidence and missing elements of the case. The defense's output is expressed as follows: , In the formula, This indicates the defense's objection. Representative controversial issues, Indicates the size of the set of disputed issues. This indicates a rebuttal to a particular candidate charge. express The corresponding detailed reasons, A pre-trained large language model for use as the defense role.
4. The method according to claim 1, characterized in that, The set of candidate charges based on the prosecution's claim The set of disputed issues in the defense's arguments The system constructs a multi-perspective query through a legal knowledge enhancement generation module, retrieving a set of target legal provisions from a structured legal knowledge base that aligns with the candidate crime set and its constituent elements. This includes: For each candidate crime in the candidate crime set, construct a multi-perspective query; Based on the multi-perspective query, a hybrid retrieval is performed in the structured legal knowledge base. The hybrid retrieval includes parallel sparse retrieval and dense retrieval to obtain a set of candidate legal provisions. The structured legal knowledge base stores triple data formed by mapping crime, elements of a crime, and legal provisions. The relevance score between the multi-view query and each candidate legal provision in the candidate legal provision set is calculated using a pre-trained reordering model, and the candidate legal provision set is reordered based on the relevance score. The top K legal provisions after reordering are selected as evidence of the target legal provisions.
5. The method according to claim 4, characterized in that, The relevance score is calculated as follows: , In the formula, For the multi-perspective query corresponding to candidate crime c. As candidate legal provisions, for and The correlation score between them Indicates context embedding, , For cross encoders, It is a learnable weight vector. for transpose, This represents the Sigmoid activation function.
6. The method according to claim 4, characterized in that, The pre-trained reordering model is a cross-encoder, and the training process of the cross-encoder includes: A training set is constructed based on the structured legal knowledge base, and a hard negative sampling strategy is used to construct positive and negative sample pairs. Among them, the legal provisions corresponding to the crime are regarded as positive samples, and negative samples are sampled from the legal provisions of other crimes. The negative samples are similar to but do not match the positive samples in terms of the constituent elements. The cross encoder is optimized by minimizing the binary cross-entropy loss function.
7. The method according to claim 1, characterized in that, If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the decision is iteratively optimized using the supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached, including: Based on the evaluation results of the initial decision tuples and consistency confidence scores, the diagnostic query is synthesized using a pre-trained language model; The diagnostic query is used to perform a retrieval in the structured legal knowledge base to obtain the supplementary evidence; The fact description, the decision tuple generated in the previous iteration, the diagnostic query, and the supplementary evidence are input into the pre-trained language model to generate the updated decision tuple for the current iteration. Recalculate the consistency confidence score of the updated decision tuple, and use the updated decision tuple and its consistency confidence score as the input for the next iteration, until the consistency confidence score reaches the preset threshold or the preset maximum number of iterations is reached; The update decision tuple for generating the current iteration is represented as follows: , In the formula, , Indicates the first , The decision generated step by step in the iteration A factual description of the case. For diagnostic queries, To supplement evidence.
8. A multi-crime legal judgment prediction system based on knowledge-enhanced dialectical reasoning, characterized in that, The system is used to perform the method as described in any one of claims 1 to 7, including: The acquisition unit is configured to acquire factual descriptions of the case to be predicted. The prosecution and defense extraction unit is configured to construct a multi-role reasoning chain to model the three stages of prosecution, defense and adjudication. In the prosecution and defense stages, the multi-role reasoning chain extracts structured prosecution claims and defense arguments from the factual description, respectively. Alignment unit, configured based on the set of candidate charges in the prosecution's claim. The set of disputed issues in the defense's arguments By enhancing legal knowledge, a multi-perspective query is constructed, and target legal provisions that align with the candidate crime set and constituent elements are retrieved from a structured legal knowledge base; the structured legal knowledge base stores the mapping relationship between crimes, constituent elements and legal provisions. The adjudication unit is configured to, during the adjudication phase, generate an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions, using the multi-role reasoning chain. The initial judgment tuple includes the charge, the applicable legal provision, the sentence, and the reasons for the judgment. A consistency confidence score is calculated for the initial judgment tuple. If the consistency confidence score is less than a preset threshold, a diagnostic query is generated to retrieve supplementary evidence, and the judgment is iteratively optimized using this supplementary evidence until the consistency confidence score reaches the preset threshold or the maximum number of iterations is reached. If the consistency confidence score is greater than or equal to the preset threshold, or the maximum number of iterations is reached, the current judgment tuple is output as the final legal judgment result. During the adjudication phase, the multi-role reasoning chain generates an initial judgment tuple based on the factual description, the prosecution's claims, the defense's arguments, and the evidence of the target legal provisions; including: The factual description, the prosecution's claims, the defense's arguments, and the evidence related to the target legal provisions are input as joint inputs into a pre-trained language model simulating the role of a presiding judge; the pre-trained language model then processes the set of disputed issues. For each disputed element, a legal provision definition query is performed; if the evidence of the target legal provision supports the disputed element, a judgment reasoning that cites the relevant provisions and adopts the defense's argument is generated; if the factual description supports the prosecution's claim and does not violate legal constraints, a judgment reasoning that rejects the defense's argument is generated. Based on the stated reasons for the judgment, an initial judgment tuple is generated, containing the crime, applicable legal provisions, sentence, and stated reasons for the judgment. The consistency confidence score is obtained by weighted summation of the legal provision integrity score, the element alignment score, and the structural integrity score. The formula for calculating the integrity score of the legal provisions is as follows: , The formula for calculating the element alignment score is as follows: , The formula for calculating the structural integrity score is as follows: , In the formula, For the iteration step, Score for completeness of legal provisions. Scoring for element alignment Score for structural integrity This is an indicator function; it returns 1 if the condition is true, and 0 otherwise. For the first The corresponding set of candidate charges for One of the candidate charges, For the first Step-by-step application of legal provisions For the structured legal knowledge base and candidate charges The corresponding set of normative legal provisions, as a candidate charge Corresponding multi-view queries, As candidate legal provisions, for and The correlation score between them For the first Legal evidence during each iteration For a predefined set of key fields, This is a key field in K. Indicates the first The decision generated step by step in the iteration express Corresponding fields The content.
Citation Information
Patent Citations
Criminal name prediction method and system, readable storage medium and computer equipment
CN116308898A
Judgment prediction method and system for judicial case, and medium
CN119598314A