Legal case similarity calculation method and system based on multi-head attention

A similarity calculation and attention technology, applied in the field of text recognition, can solve the problem of low matching accuracy, and achieve the effect of improving accuracy, improving accuracy, and accurate and reliable calculation results.

Active Publication Date: 2020-10-30
XIANGTAN UNIV
View PDF4 Cites 6 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

Therefore, extracting events according to the predefined event pattern can only represent cases in a coarse-grained manner, without including key information that affects the calculation of case similarity, and the matching accuracy is not high

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Legal case similarity calculation method and system based on multi-head attention
  • Legal case similarity calculation method and system based on multi-head attention
  • Legal case similarity calculation method and system based on multi-head attention

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0085] A method for calculating the similarity of legal cases based on multi-head attention, the method includes:

[0086] 1) Input the case descriptions of the two cases whose similarity is to be calculated into the case legal relationship recognition model, and extract the triples formed by the legal relationships in the two cases respectively, and the triples include the head entity, relationship and tail entity , and build a case knowledge map based on the triples;

[0087] 2) Convert the case knowledge map into a vectorized representation through a multi-head attention mechanism;

[0088] 3) Input the vectorized representation of the case into the deep case perception model to obtain the similarity between the two cases.

Embodiment 2

[0090]Repeat embodiment 1, but the case legal relationship recognition model described in step 1) includes: an entity recognition module for identifying entities in the description of the case; a relationship extraction for identifying the relationship between entities in the description of the case module. When identifying the case description of the structured text and the quasi-structured text, the entity identification module identifies the entity using a rule-based entity identification method.

[0091] Step 1) described in the construction method of case legal relationship identification model comprises the following steps:

[0092] 1a) Determine the entities and relationships that have an impact or have a greater impact on the calculation of case similarity, and construct a case legal relationship recognition model training data set;

[0093] In this embodiment, 600 judgment documents are randomly selected for labeling, and the entities and relationships included in th...

Embodiment 3

[0113] Repeat embodiment 2, just described step 2) specifically comprise the following steps:

[0114] 2a) initializing vectorized representations of the head entity, relation and tail entity of the triple;

[0115] In this embodiment, the triplet can be expressed as t ijk =(e i ,r k ,e j ), use random initialization to initialize the entities and relationships into d-dimensional vectors, and the vectorized triples can be expressed as where e i and e j denote head entity and tail entity respectively, r k Indicates the relationship, h i 、h j and l k are their corresponding vectorized representations, respectively.

[0116] 2b) concatenating the vectorized representations of the entities and relations of the triples, and calculating the eigenvectors of the triples using a projection matrix;

[0117] In this embodiment, the calculation formula of the eigenvector of the triplet is:

[0118]

[0119] Among them, W 1 is a linear transformation matrix,

[0120] 2c) ...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention discloses a legal case similarity calculation method based on multi-head attention. The method comprises the steps: (1) inputting the case descriptions of two cases with similarity to becalculated into a case legal relation recognition model, and extracting triples formed by legal relations in the two cases respectively, wherein the triples comprise a head entity, a relation and a tail entity, and constructing a case knowledge graph according to the triples; (2) converting the case knowledge graph into vectorized representation through a multi-head attention mechanism; (3) inputting the vectorized representation of the case into a deep case perception model to obtain the similarity of the two cases. According to the technical scheme of the invention, the method can improve the accuracy of class case retrieval, class case recommendation and other application scenes in law by calculating the similarity.

Description

technical field [0001] The present invention relates to a method for calculating the similarity of legal cases based on multi-head attention, in particular to a method for calculating the similarity of legal cases based on multi-head attention, which belongs to the technical field of text recognition; the invention also relates to a method based on multi-head attention Legal case similarity calculation system. Background technique [0002] As a statute law country, court judgments are based on legal provisions rather than precedents, but the simple rule of law sentiment of the people requires "similar cases to be judged at the same time". Therefore, it is of great significance to study the calculation of case similarity to accurately match similar cases to achieve judicial justice. In practical applications, judicial workers usually use full-text search, keyword matching, and keyword-restricted search to screen cases, and then still rely on manual judgment to determine whet...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Applications(China)
IPC IPC(8): G06F16/35G06F16/36G06F40/295G06Q50/18
CPCG06F16/35G06F16/367G06F40/295G06Q50/18Y02D10/00
Inventor 程戈张冬良肖冬梅
Owner XIANGTAN UNIV
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products