IP Library Granted Patent US 11,556,719
Granted Patent B2
US 11,556,719 · App. 17/020,160 · Granted Jan 17, 2023

Dialogue interaction method and apparatus, device, and storage medium

Inventors: Wensong He (Beijing, CN); Yafei Miao (Beijing, CN); Qichao Tang (Beijing, CN); Ben Xu (Beijing, CN); Jian Xie (Beijing, CN)
Assignees: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.; SHANGHAI XIAODU TECHNOLOGY CO. LTD.
G06F40/35G06F40/242G06F40/289G06F40/56
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 11,556,719
App. No.
17/020,160
Granted
Jan 17, 2023
Kind
B2
Abstract

Embodiments of the present disclosure relate to a dialogue interaction method and apparatus, a device and a storage medium, and relate to the field of artificial intelligence technology. The method may include: determining a first semantic encoding of received user information according to a sentence tree; determining a second semantic encoding for responding to the user information from a dialogue tree according to the first semantic encoding, the sentence tree and the dialogue tree being trained and obtained through sentence node information and/or word node information in a logical brain map sample; and determining a target response sentence of the second semantic encoding from the sentence tree, to be used for a dialogue with a user.

Claims (72)

1. A dialogue interaction method, applied in an intelligent device with a dialogue function, comprising:

receiving voice information input by a user, and converting the voice information to a text for using as user information;

determining a first semantic encoding of the user information according to a sentence tree;

determining a second semantic encoding for responding to the user information from a dialogue tree according to the first semantic encoding, the sentence tree and the dialogue tree being trained and obtained through sentence node information and/or word node information in a logical brain map sample, the dialogue tree comprising a plurality of groups of dialogues, and each group of dialogues corresponding to a dialogue logic and comprising a plurality of layers of dialogue semantics, wherein each layer of dialogue semantics corresponds to a single sentence corresponding to a sentence node of the logic brain map sample, and the sentences corresponding to the plurality of layers of dialogue semantics have a response relationship between any two sentences;

determining a target response sentence of the second semantic encoding from the sentence tree; and

converting the target response sentence to target voice information for outputting to the user through the intelligent device,

wherein the determining a second semantic encoding for responding to the user information from the dialogue tree according to the first semantic encoding comprises:

positioning, in the dialogue tree, a target user sentence node consistent with the first semantic encoding, the target user sentence node corresponding to a layer of dialogue semantics in the dialogue tree:

determining at least one candidate sentence node, in the dialogue tree, having a response relationship with the target sentence node, and extracting a response sentence node, from the at least one candidate sentence node, according to a conversion probability of the candidate sentence node; and

determining the second semantic encoding of the response sentence node.

2. The method according to claim 1 , wherein the sentence tree is used to represent a combination relationship between a word and a sentence.

3. The method according to claim 1 , wherein the sentence tree and the dialogue tree are determined by:

learning and obtaining a node in the sentence tree and a node in the dialogue tree according to the logical brain map sample; and

determining, in the sentence tree and the dialogue tree, a conversion probability between nodes.

4. The method according to claim 3 , wherein learning and obtaining the node in the sentence tree according to the logical brain map sample comprises:

performing a word node depth search on the logical brain map sample to obtain a complete dialogue path;

constituting a dialogue dictionary according to word nodes in the complete dialogue path;

performing sentence semantic compression on a sentence composed of words in the dialogue dictionary to generate a sentence node in the sentence tree, and obtaining a combination of word nodes in the sentence node according to the dialogue dictionary; and

adding a semantic encoding identifying sentence semantics to the sentence node according to semantics of the combination of the word nodes in the sentence node.

5. The method according to claim 3 , wherein learning and obtaining the node in the dialogue tree according to the logical brain map sample comprises:

performing semantic compression on sentence nodes in the logical brain map sample to generate a sentence node in the dialogue tree;

determining a response relationship between sentence nodes in the dialogue tree based on a dialogue logic represented by a connection relationship between sentence nodes in the logical brain map; and

obtaining the dialogue tree according to the sentence nodes and the response relationship between the sentence nodes, and adding a semantic encoding identifying sentence semantics to the sentence nodes according to semantics of the sentence nodes.

6. The method according to claim 1 , wherein the determining a first semantic encoding of received user information according to a sentence tree comprises:

traversing from a word node to a sentence node in the sentence tree according to word information of the user information, and determining a combination of target word nodes constituting the user information; and

determining, from a sentence node to which the combination of the target word nodes belongs, the first semantic encoding for representing the user information, according to the combination of the target word nodes.

7. The method according to claim 1 , wherein the determining a target response sentence of the second semantic encoding from the sentence tree comprises:

finding a target response sentence node consistent with the second semantic encoding from the sentence tree;

extracting, according to conversion probabilities of candidate word nodes having a combination relationship with the target response sentence node, target response word nodes from the candidate word nodes; and

combining the target response word nodes to obtain the target response sentence.

8. An electronic device with a dialogue function, comprising:

at least one processor; and

a storage device, communicatively connected with the at least one processor, wherein the storage device stores an instruction executable by the at least one processor, and the instruction is executed by the at least one processor, to cause the at least one processor to perform operations, the operations comprising:

receiving voice inform receiving voice information input by a user, and converting the voice information to a text for using as user information;

determining a first semantic encoding of the user information according to a sentence tree;

determining a second semantic encoding for responding to the user information from a dialogue tree according to the first semantic encoding, the sentence tree and the dialogue tree being trained and obtained through sentence node information and/or word node information in a logical brain map sample, the dialogue tree comprising a plurality of groups of dialogues, and each group of dialogues corresponding to a dialogue logic and comprising a plurality of layers of dialogue semantics, wherein each layer of dialogue semantics corresponds to a single sentence corresponding to a sentence node of the logic brain map sample, and the sentences corresponding to the plurality of layers of dialogue semantics have a response relationship between any two sentences;

determining a target response sentence of the second semantic encoding from the sentence tree; and

converting the target response sentence to target voice information for outputting to the user through the electronic device,

wherein the determining a second semantic encoding for responding to the user information from the dialogue tree according to the first semantic encoding comprises:

positioning, in the dialogue tree, a target user sentence node consistent with the first semantic encoding, the target user sentence node corresponding to a layer of dialogue semantics in the dialogue tree;

determining at least one candidate sentence node, in the dialogue tree, having a response relationship with the target sentence node, and extracting a response sentence node, from the at least one candidate sentence node, according to a conversion probability of the candidate sentence node; and

determining the second semantic encoding of the response sentence node.

9. The electronic device according to claim 8 , wherein the sentence tree is used to represent a combination relationship between a word and a sentence.

10. The electronic device according to claim 8 , wherein the sentence tree and the dialogue tree are determined by:

learning and obtaining a node in the sentence tree and a node in the dialogue tree according to the logical brain map sample; and

determining, in the sentence tree and the dialogue tree, a conversion probability between nodes.

11. The electronic device according to claim 10 , wherein learning and obtaining the node in the sentence tree according to the logical brain map sample comprises:

performing a word node depth search on the logical brain map sample to obtain a complete dialogue path;

constituting a dialogue dictionary according to word nodes in the complete dialogue path;

performing sentence semantic compression on a sentence composed of words in the dialogue dictionary to generate a sentence node in the sentence tree, and obtaining a combination of word nodes in the sentence node according to the dialogue dictionary; and

adding a semantic encoding identifying sentence semantics to the sentence node according to semantics of the combination of the word nodes in the sentence node.

12. The electronic device according to claim 10 , wherein learning and obtaining the node in the dialogue tree according to the logical brain map sample comprises:

performing semantic compression on sentence nodes in the logical brain map sample to generate a sentence node in the dialogue tree;

determining a response relationship between sentence nodes in the dialogue tree based on a dialogue logic represented by a connection relationship between sentence nodes in the logical brain map; and

obtaining the dialogue tree according to the sentence nodes and the response relationship between the sentence nodes, and adding a semantic encoding identifying sentence semantics to the sentence nodes according to semantics of the sentence nodes.

13. The electronic device according to claim 8 , wherein the determining a first semantic encoding of received user information according to a sentence tree comprises:

traversing from a word node to a sentence node in the sentence tree according to word information of the user information, and determining a combination of target word nodes constituting the user information; and

determining, from a sentence node to which the combination of the target word nodes belongs, the first semantic encoding for representing the user information, according to the combination of the target word nodes.

14. The electronic device according to claim 8 , wherein the determining a target response sentence of the second semantic encoding from the sentence tree comprises:

finding a target response sentence node consistent with the second semantic encoding from the sentence tree;

extracting, according to conversion probabilities of candidate word nodes having a combination relationship with the target response sentence node, target response word nodes from the candidate word nodes; and

combining the target response word nodes to obtain the target response sentence.

15. A non-transitory computer readable storage medium, applied in an intelligent device with a dialogue function and storing a computer instruction, wherein the computer instruction is used to cause a computer to perform operations, the operations comprising:

receiving voice information input by a user, and converting the voice information to a text for using as user information;

determining a first semantic encoding of the user information according to a sentence tree;

determining a second semantic encoding for responding to the user information from a dialogue tree according to the first semantic encoding, the sentence tree and the dialogue tree being trained and obtained through sentence node information and/or word node information in a logical brain map sample, the dialogue tree comprising a plurality of groups of dialogues, and each group of dialogues corresponding to a dialogue logic and comprising a plurality of layers of dialogue semantics, wherein each layer of dialogue semantics corresponds to a single sentence corresponding to a sentence node of the logic brain map sample, and the sentences corresponding to the plurality of layers of dialogue semantics have a response relationship between any two sentences;

determining a target response sentence of the second semantic encoding from the sentence tree; and

converting the target response sentence to target voice information for outputting to the user through the intelligent device,

wherein the determining a second semantic encoding for responding to the user information from the dialogue tree according to the first semantic encoding comprises:

positioning, in the dialogue tree, a target user sentence node consistent with the first semantic encoding, the target user sentence node corresponding to a layer of dialogue semantics in the dialogue tree;

determining at least one candidate sentence node, in the dialogue tree, having a response relationship with the target sentence node, and extracting a response sentence node, from the at least one candidate sentence node, according to a conversion probability of the candidate sentence node; and

determining the second semantic encoding of the response sentence node.

Assignments (7)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 18, 2022
From: BAIDU.COM TIMES TECHNOLOGY (BEIJING) CO., LTD.
To: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.
Reel/Frame 061824/0741 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 18, 2022
From: BEIJING BAIDU NETCOM SCIENCE AND TECHNOLOGY CO., LTD.
To: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.
Reel/Frame 061824/0764 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Nov 18, 2022
From: XU, BEN; XIE, JIAN
To: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.
Reel/Frame 061824/0808 →
EMPLOYMENT AGREEMENT Recorded Nov 18, 2022
From: HE, WENSONG
To: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.
Reel/Frame 061966/0301 →
EMPLOYMENT AGREEMENT Recorded Nov 18, 2022
From: MIAO, YAFEI
To: BAIDU.COM TIMES TECHNOLOGY (BEIJING) CO., LTD.
Reel/Frame 061966/0321 →
EMPLOYMENT AGREEMENT Recorded Nov 18, 2022
From: TANG, QICHAO
To: BEIJING BAIDU NETCOM SCIENCE AND TECHNOLOGY CO., LTD.
Reel/Frame 061966/0369 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded May 30, 2021
From: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.
To: BAIDU ONLINE NETWORK TECHNOLOGY (BEIJING) CO., LTD.; SHANGHAI XIAODU TECHNOLOGY CO. LTD.
Reel/Frame 056811/0772 →
Priority Claims (1)
CN 202010017420.6 · Jan 8, 2020 · national
Continuity (1)
Related Publication 20210209312A1 · Jul 8, 2021