# US 2022/0284192 A1 · Extracting mentions of complex relation types from documents

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2022/0284192 A1
- Document ID: US20220284192A1
- Status: Published application
- Kind: A1
- Application number: 17/345,281
- Filed: 2021-06-11
- Published: 2022-09-08
- Earliest claimed: 2021-02-09
- Assignees: Tata Consultancy Services Limited
- Applicants: Tata Consultancy Services Limited
- Inventors: Sachin Sharad PAWAR; Nitin Ramrakhiyani; Girish Keshav Palshikar; Anindita Sinha Banerjee; Rajiv Srivastava; Devavrat Shailesh Thosar
- Web page: https://patentgrep.com/patent/US20220284192A1

## CPC

- G06F 40/295: Named entity recognition
- G06F 16/3344: {using natural language analysis}
- G06F 40/205: Parsing
- G06F 40/284: Lexical analysis, e.g. tokenisation or collocates
- G06N 3/044: Recurrent networks, e.g. Hopfield networks
- G06N 3/0442: characterised by memory or gating, e.g. long short-term memory [LSTM] or gated recurrent units [GRU]
- G06N 3/045: Combinations of networks
- G06N 3/0455: Auto-encoder networks; Encoder-decoder networks
- G06N 3/049: Temporal neural networks, e.g. delay elements, oscillating neurons or pulsed inputs
- G06N 3/08: Learning methods
- G06N 3/084: Backpropagation, e.g. using gradient descent
- G06N 3/09: Supervised learning
- G06N 3/091: Active learning
- G06N 7/01: Probabilistic graphical models, e.g. probabilistic networks
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS

## Abstract

Extracting data from documents is challenging due to the variation in structure, content, styles across geographies and functional areas. Further complex relation types are characterized by one or more of N-ary entity mention arguments, cross sentence span of entity mentions for a relation mention, missing entity mention arguments and entity mention arguments being multi-valued. The present disclosure addresses these gaps in the art to extract entity mentions and relation mentions using a joint neural network model including two sequence labelling layers which are trained jointly. The mentions are extracted from documents to facilitate downstream processing. A first RNN layer creates sentence embeddings for each sentence in the document being processed and predicts entity mentions. A second RNN layer predicts labels for each sentence span corresponding to a relation type. Using predefined rules, entity mentions for each entity type are selected for extracting relation mentions from the identified sentence spans.

## Claims

### Claim 1

A processor implemented method comprising the steps of:
receiving, via one or more hardware processors, a test document for extracting mentions including a plurality of entity mentions and a plurality of relation mentions using a trained joint neural network model, wherein the trained joint neural network model includes a jointly trained first Recurrent Neural Network (RNN) layer and a second RNN layer, wherein each relation mention in the plurality of relation mentions is a tuple of two or more entity mentions from the plurality of entity mentions;
creating, via the one or more hardware processors serving as the first RNN layer, a sentence embedding for each sentence in the test document and predicting the plurality of entity mentions with an associated prediction confidence for each word comprised therein;
predicting, via the one or more hardware processors serving as the second RNN layer, labels for each sentence in the test document, wherein the labels identify one or more sentence spans, each sentence span corresponding to a relation type between two or more entity types with associated entity mentions from the predicted plurality of entity mentions; and
extracting, via the one or more hardware processors, a relation mention for an associated relation type, from each of the identified one or more sentence spans by selecting at least one entity mention for each entity type corresponding to the relation type.

### Claim 2 (depends on 1)

The processor implemented method of claim 1, wherein the mentions are associated with complex relation types in the test document characterized by one or more of i) a relation having more than two entity mention arguments, ii) a relation having entity mention arguments spanning across two or more sentences, iii) a relation having one or more missing entity mention arguments for a relation mention, and iv) a relation wherein one or more entity mention arguments have more than one values.

### Claim 3 (depends on 1)

The processor implemented method of claim 1, wherein the step of extracting a relation mention comprises ignoring a sentence span, from the one or more identified sentence spans, that misses at least one predefined pivot entity mention, wherein each of the at least one predefined pivot entity mention is associated with a predefined pivot entity type and each relation type is associated with at least one predefined pivot entity type.

### Claim 4 (depends on 1)

The processor implemented method of claim 1, wherein selecting at least one entity mention for each entity type corresponding to the relation type is based on a predefined rule.

### Claim 5 (depends on 4)

The processor implemented method of claim 4, wherein the predefined rule is one of (i) selecting an entity mention having a highest prediction confidence if there are more than one associated entity mentions for an entity type and the entity type has a single value; (ii) selecting all the entity mentions if there are more than one associated entity mentions for an entity type and the entity type has multiple values; (iii) selecting an entity mention randomly from the entity mentions of an associated entity type; or (iv) selecting an entity mention having a longest argument from the entity mentions of an associated entity type; and wherein the prediction confidence of an entity mention having multiple words is based on a geometric mean of the prediction confidence of the individual words therein.

### Claim 6 (depends on 1)

The processor implemented method of claim 1, wherein the step of receiving a test document is preceded by training a joint neural network model including the first RNN layer and the second RNN layer to obtain the trained joint neural network model, the training comprising:
receiving, via the one or more hardware processors, a plurality of training documents of the same type as the test document, a list of entity mentions and a list of sentence spans comprised in each of the plurality of training documents, wherein each sentence span corresponds to a relation mention of a relation type between two or more entity types with associated entity mentions;
creating, via the one or more hardware processors serving as the first RNN layer, a sentence embedding for each sentence in each of the plurality of training documents, using a sequence of word embeddings of the words comprised therein; and
jointly training, via the one or more hardware processors, the first RNN layer and the second RNN layer of the joint neural network model, wherein the first RNN layer is trained using the received list of entity mentions to predict one or more entity mentions with an associated prediction confidence for each word in each sentence, and wherein the second layer is trained using the sentence embeddings created by the first RNN layer and the received list of sentence spans to predict a label for each sentence.

### Claim 7 (depends on 6)

The processor implemented method of claim 6, wherein one or more word embeddings in the sequence of word embeddings, is combined with one or more of (i) a Part-of-speech (POS) embedding, (ii) a contextual sentence embedding and (iii) a Named entity recognition (NER) embedding.

### Claim 8 (depends on 7)

The processor implemented method of claim 7, wherein the contextual sentence embedding is obtained by:
obtaining, via the one or more hardware processors serving as a third RNN layer, a sentence embedding for each sentence in each of the plurality of training documents, using a sequence of word embeddings of the words comprised therein; and
creating, via the one or more hardware processors serving as a fourth RNN layer, a contextual sentence embedding for each obtained sentence embedding from the third layer.

### Claim 9

A system comprising:
one or more data storage devices operatively coupled to one or more hardware processors and configured to store instructions configured for execution via the one or more hardware processors serving at least as a first RNN layer, a second RNN layer, a third RNN layer and a fourth RNN layer, to:
receive, a test document for extracting mentions including a plurality of entity mentions and a plurality of relation mentions using a trained joint neural network model, wherein the trained joint neural network model includes the first Recurrent Neural Network (RNN) layer and the second RNN layer trained jointly, wherein each relation mention in the plurality of relation mentions is a tuple of two or more entity mentions from the plurality of entity mentions;
create, by the first RNN layer, a sentence embedding for each sentence in the test document and predicting the plurality of entity mentions with an associated prediction confidence for each word comprised therein;
predict, by the second RNN layer, labels for each sentence in the test document, wherein the labels identify one or more sentence spans, each sentence span corresponding to a relation type between two or more entity types with associated entity mentions from the predicted plurality of entity mentions; and
extract, a relation mention for an associated relation type, from each of the identified one or more sentence spans by selecting at least one entity mention for each entity type corresponding to the relation type.

### Claim 10 (depends on 9)

The system of claim 9, wherein the mentions are associated with complex relation types in the test document characterized by one or more of i) a relation having more than two entity mention arguments, ii) a relation having entity mention arguments spanning across two or more sentences, iii) a relation having one or more missing entity mention arguments for a relation mention, and iv) a relation wherein one or more entity mention arguments have more than one values.

### Claim 11 (depends on 9)

The system of claim 9, wherein the one or more processors are further configured to extract the relation mention by ignoring a sentence span, from the one or more identified sentence spans, that misses at least one predefined pivot entity mention, wherein each of the at least one predefined pivot entity mention is associated with a predefined pivot entity type and each relation type is associated with at least one predefined pivot entity type.

### Claim 12 (depends on 9)

The system of claim 9, wherein the one or more processors are further configured to select at least one entity mention for each entity type corresponding to the relation type based on a predefined rule.

### Claim 13 (depends on 10)

The system of claim 10, wherein the predefined rule is one of (i) selecting an entity mention having a highest prediction confidence if there are more than one associated entity mentions for an entity type and the entity type has a single value; (ii) selecting all the entity mentions if there are more than one associated entity mentions for an entity type and the entity type has multiple values; (iii) selecting an entity mention randomly from the entity mentions of an associated entity type; or (iv) selecting an entity mention having a longest argument from the entity mentions of an associated entity type; and wherein the prediction confidence of an entity mention having multiple words is based on a geometric mean of the prediction confidence of the individual words therein.

### Claim 14 (depends on 9)

The system of claim 9, wherein the one or more processors are further configured to train a joint neural network model including the first RNN layer and the second RNN layer to obtain the trained joint neural network model prior to receiving the test document, wherein the training comprises:
receiving, a plurality of training documents of the same type as the test document, a list of entity mentions and a list of sentence spans comprised in each of the plurality of training documents, wherein each sentence span corresponds to a relation mention of a relation type between two or more entity types with associated entity mentions;
creating, by the first RNN layer, a sentence embedding for each sentence in each of the plurality of training documents, using a sequence of word embeddings of the words comprised therein; and
jointly training the first RNN layer and the second RNN layer of the joint neural network model, wherein the first RNN layer is trained using the received list of entity mentions to predict one or more entity mentions with an associated prediction confidence for each word in each sentence, and wherein the second layer is trained using the sentence embeddings created by the first RNN layer and the received list of sentence spans to predict a label for each sentence.

### Claim 15 (depends on 14)

The system of claim 14, wherein the one or more processors are further configured to combine one or more word embeddings in the sequence of word embeddings with one or more of (i) a Part-of-speech (POS) embedding, (ii) a contextual sentence embedding and (iii) a Named entity recognition (NER) embedding.

### Claim 16 (depends on 15)

The system of claim 15, wherein the one or more processors are further configured to obtain the contextual sentence embedding by:
obtaining, via the third RNN layer, a sentence embedding for each sentence in each of the plurality of training documents, using a sequence of word embeddings of the words comprised therein; and
creating, via the fourth RNN layer, a contextual sentence embedding for each obtained sentence embedding from the third layer.

### Claim 17

A computer program product comprising a non-transitory computer readable medium having a computer readable program embodied therein, wherein the computer readable program, when executed on a computing device, causes the computing device to:
receiving, via one or more hardware processors, a test document for extracting mentions including a plurality of entity mentions and a plurality of relation mentions using a trained joint neural network model, wherein the trained joint neural network model includes a jointly trained first Recurrent Neural Network (RNN) layer and a second RNN layer, wherein each relation mention in the plurality of relation mentions is a tuple of two or more entity mentions from the plurality of entity mentions;
creating, via the one or more hardware processors serving as the first RNN layer, a sentence embedding for each sentence in the test document and predicting the plurality of entity mentions with an associated prediction confidence for each word comprised therein:
predicting, via the one or more hardware processors serving as the second RNN layer, labels for each sentence in the test document, wherein the labels identify one or more sentence spans, each sentence span corresponding to a relation type between two or more entity types with associated entity mentions from the predicted plurality of entity mentions; and
extracting, via the one or more hardware processors, a relation mention for an associated relation type, from each of the identified one or more sentence spans by selecting at least one entity mention for each entity type corresponding to the relation type.
