# US 2023/0066314 A1 · Method and device for preserving context in conversations

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

- Number: US 2023/0066314 A1
- Document ID: US20230066314A1
- Status: Published application
- Kind: A1
- Application number: 17/797,313
- Filed: 2021-02-05
- Published: 2023-03-02
- Earliest claimed: 2020-02-07
- Assignees: Koninklijke Philips N.V.
- Applicants: Koninklijke Philips N.V.
- Inventors: SHREYA ANAND; RITHESH SREENIVASAN; SHEIKH SADID AL HASAN; OLADIMEJI FEYISETAN FARRI
- Web page: https://patentgrep.com/patent/US20230066314A1

## CPC

- G06F 16/3329: Natural language query formulation
- G10L 15/183: using context dependencies, e.g. language models
- G06F 16/335: Filtering based on additional data, e.g. user or group profiles (filtering in web context G06F16/9535, G06F16/9536)
- G10L 15/063: {Training}
- G10L 2015/0631: {Creating reference templates; Clustering}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G10L: SPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING

## Abstract

The present disclosure relates to preserving context in a conversation between a user (101) and a digital assistant device (102). During training, the digital assistant device (102) is provided with a plurality of conversations having a plurality of dialogues. Each of the plurality of dialogue is assigned an ID based on a context. Further, two or more test queries having a same context is provided as input and the two are more queries are assigned an ID based on the context. Thereafter, the digital assistant device (102) is configured to retrieve one or more dialogues from the plurality of dialogues where the ID of the one or more dialogues match the ID of the two or more queries. In real-time, one or more queries are received and based on a context of the one or more queries, one or more dialogues are retrieved and are provided to the user.

## Claims

### Claim 1

A method of preserving context in a conversation, comprising:
receiving, by a digital assistant device, one or more queries;
determining, by the digital assistant device, a context of each of the one or more queries;
retrieving, by the digital assistant device, one or more dialogues from a plurality of dialogues stored in an external memory associated with the digital assistant device, based on the context of each of the one or more queries and an Identity (ID) assigned to each of the plurality of dialogues based on a context of each of the plurality of dialogues; and
providing, by the digital assistant device, the one or more dialogues in response to the one or more queries, wherein the one or more queries and the one or more dialogues form a conversation, wherein a context of the conversation is preserved when the context of the one or more queries is similar to the context of the one or more dialogues.

### Claim 2 (depends on 1)

The method as claimed in claim 1 is performed by an end-to-end memory network (MEMN2N) model configured in the digital assistant device.

### Claim 3 (depends on 1)

The method as claimed in claim 1, wherein determining the context of each of the one or more queries comprises:
generating one or more feature vectors for each of the one or more queries; and
applying one or more natural language processing techniques on each of the one or more feature vectors to determine the context of each of the one or more queries.

### Claim 4 (depends on 1)

The method as claimed in claim 1, wherein retrieving the one or more dialogues comprises:
determining a relation between the context of each of the one or more queries and the context of each of the plurality of dialogues;
assigning a score to each relation between the context of each of the one or more queries and the context of each of the plurality of dialogues; and
retrieving the one or more dialogues from the plurality of dialogues when a score assigned to a relation between the one or more dialogues and the one or more queries is above a threshold value.

### Claim 5 (depends on 1)

The method as claimed in claim 1, wherein the ID assigned to each of the one or more dialogues is identical when the context of each of the one or more dialogues are similar.

### Claim 6

A digital assistant device for preserving context in a conversation, comprising:
one or more processors; and
a memory communicatively coupled to the one or more processors, storing processor executable instructions, which, on execution causes the one or more processors to:
receive one or more queries;
determine a context of each of the one or more queries;
retrieve one or more dialogues from a plurality of dialogues stored in an external memory associated with the digital assistant device, based on the context of each of the one or more queries and an Identity (ID) associated with each of the plurality of dialogues based on a context of each of the plurality of dialogues; and
provide the one or more dialogues in response to the one or more queries, wherein the one or more queries and the one or more dialogues form a conversation, wherein a context of the conversation is preserved when the context of the one or more queries is similar to the context of the one or more dialogues.

### Claim 7 (depends on 6)

The digital assistant device as claimed in claim 6, implements an end-to-end memory network (MEMN2N) model.

### Claim 8 (depends on 6)

The digital assistant device as claimed in claim 6, wherein the one or more processors determines the context of each of the one or more queries when the one or more processors are configured to:
generate one or more feature vectors for each of the one or more queries; and
apply one or more natural language processing techniques on each of the one or more feature vectors.

### Claim 9 (depends on 6)

The digital assistant device as claimed in claim 6, wherein the one or more processors retrieves the one or more dialogues when the one or more processors are configured to:
determine a relation between the context of each of the one or more queries and the context of each of the plurality of dialogues;
assign a score to each relation between the context of each of the one or more queries and the context of each of the plurality of dialogues; and
retrieve the one or more dialogues from the plurality of dialogues when a score assigned to a relation between the one or more dialogues and the one or more queries is above a threshold value.

### Claim 10 (depends on 6)

The digital assistant device as claimed in claim 6, wherein the one or more processors assign the an identical ID to each of the one or more dialogues when the context of each of the one or more dialogues are similar.

### Claim 11

A method of training a digital assistant device to preserve context in a conversation, the method comprising:
assigning, by a digital assistant device (102), an Identity (ID) to each dialogue from a plurality of dialogues stored in an external memory associated with the digital assistant device, based on one or more contexts in the conversation, wherein one or more dialogues from the plurality of dialogues having similar context are assigned with identical ID;
receiving, by the digital assistant device, two or more test queries; and
assigning, by the digital assistant device, the ID to each of the two or more test queries based on a context of each of the two or more test queries, wherein the digital assistant device retrieves one or more dialogues from the plurality of dialogues in response to the two or more test queries based on the ID assigned to the two or more test queries and the ID assigned to the plurality of dialogues, wherein the two or more queries and the one or more dialogues form a conversation, wherein the context of the conversation is preserved when the context of the one or more queries is similar to the context of the one or more dialogues.
