US 12,019,990 B2
Representation learning method and device based on natural language and knowledge graph
Haifeng Wang, Beijing (CN); Wenbin Jiang, Beijing (CN); Yajuan Lv, Beijing (CN); Yong Zhu, Beijing (CN); and Hua Wu, Beijing (CN)
Assigned to BEIJING BAIDU NETCOM SCIENCE TECHNOLOGY CO., LTD., (CN)
Filed by BEIJING BAIDU NETCOM SCIENCE TECHNOLOGY CO., LTD., Beijing (CN)
Filed on Dec. 16, 2020, as Appl. No. 17/124,030.
Application 17/124,030 is a continuation of application No. PCT/CN2020/095108, filed on Jun. 9, 2020.
Claims priority of application No. 201911297702.X (CN), filed on Dec. 17, 2019.
Prior Publication US 2021/0192364 A1, Jun. 24, 2021
Int. Cl. G06N 20/00 (2019.01); G06F 18/214 (2023.01); G06F 18/2413 (2023.01); G06F 40/279 (2020.01); G06F 40/30 (2020.01); G06N 5/022 (2023.01)
CPC G06F 40/30 (2020.01) [G06F 18/214 (2023.01); G06F 18/24147 (2023.01); G06F 40/279 (2020.01); G06N 5/022 (2013.01)] 15 Claims
OG exemplary drawing
 
1. A text processing method based on natural language and a knowledge graph comprises:
receiving a text processing request input by a user, wherein the text processing request is used to request that a text be processed according to a semantic representation of a prediction object in the text;
inputting the prediction object to a joint learning model that has been pre-trained to obtain the semantic representation of the prediction object, wherein the joint learning model is used for knowledge graph representation learning and natural language representation learning, and the semantic representation is obtained by the joint learning model by combining the knowledge graph representation learning and the natural language representation learning; and
processing the text according to the semantic representation;
wherein before the receiving the text processing request input by the user, further comprising:
performing training on training samples to obtain the joint learning model, wherein the joint learning model comprises a natural language learning layer, a joint learning correlation layer and a knowledge graph learning layer, and the joint learning correlation layer is used to correlate the knowledge graph learning layer with the natural language learning layer;
wherein the performing the training on the training samples to obtain the joint learning model comprises:
determining, at the natural language learning layer, a neighbor sample of a target training sample in the training samples;
determining, at the joint learning correlation layer, a weight of the target training sample relative to each entity in the knowledge graph learning layer according to the neighbor sample;
determining a knowledge graph semantic representation of the target training sample according to the weight of each entity; and
determining a training result of the target training sample according to the knowledge graph semantic representation and the neighbor sample.