# US 2021/0241050 A1 · System and method for efficient multi-relational entity understanding and retreival

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

- Number: US 2021/0241050 A1
- Document ID: US20210241050A1
- Status: Published application
- Kind: A1
- Application number: 16/900,664
- Filed: 2020-06-12
- Published: 2021-08-05
- Earliest claimed: 2020-02-03
- Assignees: Samsung Electronics Co., Ltd.
- Applicants: Samsung Electronics Co., Ltd.
- Inventors: Dalkandura Arachchige Kalpa Shashika Silva Gunaratna; Hongxia Jin
- Web page: https://patentgrep.com/patent/US20210241050A1

## CPC

- G06F 16/288: {Entity relationship models}
- G06F 16/24564: {Applying rules; Deductive queries}
- G06F 16/367: {Ontology}
- G06F 18/214: Generating training patterns; Bootstrap methods, e.g. bagging or boosting
- G06N 3/04: Architecture, e.g. interconnection topology
- G06N 3/042: Knowledge-based neural networks; Logical representations of neural networks
- G06N 3/045: Combinations of networks
- G06N 3/0464: Convolutional networks [CNN, ConvNet]
- G06N 3/08: Learning methods
- G06N 3/09: Supervised learning
- G06N 5/022: Knowledge engineering; Knowledge acquisition
- G06N 5/025: Extracting rules from data
- G06N 5/041: {Abduction}
- G06V 30/1988: {Graph matching (graphical image representation G06V30/18181)}
- G06N 3/044: Recurrent networks, e.g. Hopfield networks
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING

## Abstract

A method, an electronic device and computer readable medium for entity-relationship embeddings using automatically generated entity graphs instead of a traditional knowledge graph are provided. The method includes receiving, by a processor, an input text. The method also includes identifying a primary entity, a secondary entity and a context from the input text, wherein the context comprises a relationship between the primary entity and the secondary entity. The method additionally includes generating, by the processor, an entity context graph based on the primary entity, the secondary entity, and the context by: extracting, from the context, one or more text segments comprising a plurality of words describing one or more additional relationships between the primary entity and the secondary entity, and generating a plurality of context triples from the one or more text segments, each of the plurality of context triples defining a respective relationship between primary entity and the secondary entity.

## Claims

### Claim 1

A method comprising:
receiving, by a processor, an input text;
identifying a primary entity, a secondary entity and a context from the input text, wherein the context comprises a relationship between the primary entity and the secondary entity;
generating, by the processor, an entity context graph based on the primary entity, the secondary entity, and the context by:
extracting, from the context, a prominent relationship between the primary entity and the secondary entity, and
extracting, from the context, text segments comprising a plurality of words describing a relationship between the first entity and the second entity, and
generating a plurality of context triples from the text segments, each of the plurality of context triples defining a relationship between primary entity and the secondary entity.

### Claim 2 (depends on 1)

The method of claim 1, wherein identifying the primary entity, the secondary entity, and the context from the input text comprises obtaining a pre-existing knowledge-graph triple.

### Claim 3 (depends on 2)

The method of claim 2, further comprising:
receiving an inquiry regarding the primary entity;
determining that the pre-existing knowledge-graph triple does not contain a matching relationship to the inquiry; and
providing an answer based on at least one of the plurality context triples in the entity context graph.

### Claim 4 (depends on 3)

The method of claim 3, further comprising:
creating an enhanced knowledge-graph by updating the pre-existing knowledge-graph based on the entity context graph.

### Claim 5 (depends on 1)

The method of claim 1, wherein generating the plurality of context triples from the text segments, each of the plurality of context triples defining the relationship between the primary entity and the secondary entity further comprises:
encoding the relationship;
looking up the primary entity and secondary entity in an embedding matrix; and
updating, based on the encoded relationship and looked-up entities, weights for the encoding and vectors in the embedding matrix.

### Claim 6 (depends on 5)

The method of claim 5, wherein the encoding is performed by a convolution neural network (CNN), the CNN configured to:
embed the context using a pre-trained word embedding;
mine different length features by applying different window size convolutions and max pooling; and
combine the mined features.

### Claim 7 (depends on 1)

The method of claim 1, wherein extracting the secondary entity comprises:
extracting a plurality of secondary entities, and
wherein generating a plurality of context triples from the text segments comprises generating n triple patterns based on n number of secondary entities extracted.

### Claim 8

An electronic device comprising:
a processor; and
a memory operably coupled to the processor, the memory including instructions executable by the processor to:
receive an input text,
identify a primary entity, a secondary entity and a context from the input text, wherein the context comprises a relationship between the primary entity and the secondary entity, and
generate, by the processor, an entity context graph based on the primary entity, the secondary entity, and the context by:
extracting, from the context, one or more text segments comprising a plurality of words describing one or more additional relationships between the primary entity and the secondary entity, and
generating a plurality of context triples from the one or more text segments, each of the plurality of context triples defining a respective relationship between primary entity and the secondary entity.

### Claim 9 (depends on 8)

The electronic device of claim 8, wherein to identify the primary entity, the secondary entity, and the context from the input text, the instructions executable by the processor to:
obtain a pre-existing knowledge-graph triple.

### Claim 10 (depends on 9)

The electronic device of claim 9, wherein, the instructions are further executable by the processor to:
receive an inquiry regarding the primary entity;
determine that the pre-existing knowledge-graph triple does not contain a matching relationship to the inquiry; and
provide an answer based on at least one of the plurality context triples in the entity context graph.

### Claim 11 (depends on 10)

The electronic device of claim 10, wherein, the instructions are further executable by the processor to:
create an enhanced knowledge-graph by updating the pre-existing knowledge-graph based on the entity context graph.

### Claim 12 (depends on 8)

The electronic device of claim 8, wherein to generate the plurality of context triples from the text segments, the instructions are further executable by the processor to:
encode the relationship;
look up the primary entity and secondary entity in an embedding matrix; and
update, based on the encoded relationship and looked-up entities, weights for the encoding and vectors in the embedding matrix.

### Claim 13 (depends on 12)

The electronic device of claim 12, wherein the processor comprises a convolution neural network (CNN) configured to:
embed the context using a pre-trained word embedding;
mine different length features by applying different window size convolutions and max pooling; and
combine the mined features.

### Claim 14 (depends on 13)

The electronic device of claim 13, wherein to extract the secondary entity, the memory includes instructions to:
extract a plurality of secondary entities, and
wherein generating a plurality of context triples from the text segments comprises generating n triple patterns based on n number of secondary entities extracted.

### Claim 15

A non-transitory machine-readable medium containing instructions that when executed cause at least one processor of an electronic device to:
identify a primary entity, a secondary entity and a context from the input text, wherein the context comprises a relationship between the primary entity and the secondary entity; and
generate, by the processor, an entity context graph based on the primary entity, the secondary entity, and the context by:
extracting, from the context, one or more text segments comprising a plurality of words describing one or more additional relationships between the primary entity and the secondary entity, and
generating a plurality of context triples from the one or more text segments, each of the plurality of context triples defining a respective relationship between primary entity and the secondary entity.

### Claim 16 (depends on 15)

The non-transitory machine-readable medium of claim 15, wherein to identify the primary entity, the secondary entity, and the context from the input text, comprise instructions that when executed cause the at least one processor to:
obtain a pre-existing knowledge-graph triple.

### Claim 17 (depends on 16)

The non-transitory machine-readable medium of claim 16, further comprising instructions that when executed cause the at least one processor to:
receive an inquiry regarding the primary entity;
determine that the pre-existing knowledge-graph triple does not contain a matching relationship to the inquiry; and
provide an answer based on at least one of the plurality context triples in the entity context graph.

### Claim 18 (depends on 17)

The electronic device of claim 17, further comprising instructions that when executed cause the at least one processor to:
create an enhanced knowledge-graph by updating the pre-existing knowledge-graph based on the entity context graph.

### Claim 19 (depends on 15)

The non-transitory machine-readable medium of claim 15, further comprising instructions that when executed cause the at least one processor to:
encode the relationship;
look up the primary entity and secondary entity in an embedding matrix; and
update, based on the encoded relationship and looked-up entities, weights for the encoding and vectors in the embedding matrix.

### Claim 20 (depends on 15)

The non-transitory machine-readable medium of claim 15, wherein identifying a primary entity, a secondary entity and a context from the input text comprises obtaining a knowledge-graph triple, and
wherein to extract the secondary entity, comprise instructions that when executed cause the at least one processor to:
extract a plurality of secondary entities, and
wherein generating a plurality of context triples from the text segments comprises generating n triple patterns based on n number of secondary entities extracted.
