Method, system and computer device for determining superior-female relationship

By obtaining multi-source information of hypernyms and entities to generate vector representations, and performing deep semantic vector generation in a fully connected neural network, the existing technology solves the problems of weak generalization ability and high algorithm overhead in distinguishing hypernym and hyponym relationships, and achieves Efficient and accurate judgment of hyponym relationship.

CN110209832BActive Publication Date: 2024-08-23TENCENT TECH (BEIJING) CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
CN201810898482.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2018-08-08
Publication Date
2024-08-23
Estimated Expiration
2039-05-14

AI Technical Summary

Technical Problem

Existing methods for identifying superior and hyponymic relationships rely on manual screening of dictionaries, have weak generalization capabilities and high algorithm overhead, and are unable to adapt to the discrimination of various superior and hyponymic relationships.

Method used

By obtaining multi-source information of hypernyms and entities, converting it into mathematical description, generating vector representation, and splicing and projecting it in a fully connected neural network, a deep semantic vector is generated to identify the hypernym relationship.

Benefits of technology

The algorithm overhead is reduced, the generalization ability is enhanced, and the accuracy and adaptability of discriminating between superior and inferior relations are improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN110209832B
    Figure CN110209832B
Patent Text Reader

Abstract

The present invention discloses a method, system and computer device for distinguishing a hypernym relationship. The method includes: obtaining hypernyms and entities corresponding to the hypernym relationship; converting the hypernyms and entities into corresponding mathematical descriptions through the obtained multi-source information to obtain vector representations corresponding to the hypernyms and entities respectively; splicing the vector representations of the hypernyms and entities corresponding to an information source to obtain a long vector; generating a deep semantic vector based on the projection of the long vector on a fully connected neural network, and the output of the deep semantic vector on the fully connected neural network corresponds to the result of distinguishing the hypernym relationship. For the discrimination of the hypernym relationship, it is only necessary to obtain the vector representation in the algorithm, and obtain the discrimination result by means of the fully connected neural network, so that the algorithm overhead is greatly reduced, and it can also be adapted to the discrimination of various hypernyms, and the generalization ability is enhanced, so that the semantic features can be accurately captured, thereby correspondingly improving the accuracy of the discrimination.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of Internet application technology, and in particular to a method, system and computer device for determining a superior-female relationship. Background Art

[0002] With the development of Internet application fields, natural language processing provides support for the implementation of many Internet applications. As the infrastructure of many Internet applications, it will realize intelligent language understanding capabilities in Internet applications by extracting the hierarchical relationships between keywords.

[0003] The constructed hierarchical relationships, for example, the hierarchical relationships constructed in the knowledge base, that is, the knowledge graph, need to be judged for correctness to ensure the accuracy of performing natural language processing tasks.

[0004] The existing identification of hyponymy and hyponymy relies on manually selected dictionaries on the one hand, and on various methods of calculating the hypernyms and entities in the hyponymy and hyponymy on the other hand, and then using a classification model to determine whether the hyponymy and hyponymy are correct.

[0005] The method that relies on the dictionary established by manual screening is to regard the hypernym as an attribute of the entity, and establish the entity's label dictionary based on the entity's label attribute. Therefore, for the hypernym in a hyponymy relationship, the semantic similarity between the hypernym and the entity label will be calculated in the label dictionary to determine whether the two are related. This method has a high accuracy in determining the hyponymy relationship, but because it relies on the dictionary established by manual screening, the generalization ability is weak.

[0006] Although human intervention is not required through the operation of hypernyms and entities in the hyponymy relationship and the prediction of the classification model, there is a very high algorithmic overhead and it is still not suitable for the discrimination of various hyponymy relationships.

[0007] With the continuous construction of hyponymy, we are faced with a large number of hypernyms, and each hypernym has one or even multiple entities. By analogy, a large number of hyponyms and hypernyms will be constructed for this purpose. How to adapt to the judgment of various hyponyms and hypernyms and reduce the algorithm overhead has become an urgent problem to be solved. Summary of the invention

[0008] In order to solve the technical problem that the determination of hierarchical and subhierarchical relationships in the related art is limited by the generalization ability and very high algorithm overhead, the present invention provides a method, system and computer device for determining hierarchical and subhierarchical relationships.

[0009] A method for determining a superior-female relationship, the method comprising:

[0010] Get the hypernyms and entities corresponding to the hyponym relationship;

[0011] Convert the hypernyms and entities into corresponding mathematical descriptions through the acquired multi-source information to obtain vector representations corresponding to the hypernyms and entities respectively;

[0012] The vector representations of the hypernyms and entities corresponding to an information source are concatenated to obtain a long vector;

[0013] A deep semantic vector is generated based on the projection of the long vector on the fully connected neural network, and the output of the deep semantic vector in the fully connected neural network corresponds to the discrimination result of the hierarchical relationship.

[0014] A system for distinguishing a superior-female relationship, the system comprising:

[0015] An acquisition module is used to acquire the hypernyms and entities corresponding to the hyponymy relationship;

[0016] A numerical conversion module, used to convert the hypernyms and entities into corresponding mathematical descriptions through the acquired multi-source information, and obtain vector representations corresponding to the hypernyms and entities respectively;

[0017] A concatenation module is used to concatenate the vector representations of hypernyms and entities corresponding to an information source to obtain a long vector;

[0018] A prediction module is used to generate a deep semantic vector based on the projection of the long vector on a fully connected neural network, wherein the output of the deep semantic vector on the fully connected neural network corresponds to the discrimination result of the hierarchical relationship.

[0019] In an exemplary embodiment, the multi-source information is text information related to the hypernyms and entities in multiple information sources, and the numerical conversion module is further used to perform mathematical description conversion of the hypernyms and entities in each information source according to the text information related to the hypernyms and entities in multiple information sources, so as to obtain vector representations corresponding to the hypernyms and entities in each information source.

[0020] In an exemplary embodiment, the multi-source information includes encyclopedia text, and the numerical conversion module includes:

[0021] A segmentation unit, used to perform segmentation processing on the encyclopedia text according to character segmentation granularity and word segmentation granularity respectively, and obtain characters and words obtained by segmentation in the encyclopedia text;

[0022] A vector training unit, used for representing the characters and words as real-valued vectors according to the encyclopedia text, to obtain character vectors and word vectors, wherein the word vectors are related to the context information of the encyclopedia text;

[0023] The first vector representation unit is used to construct vector representations of the hypernym and entity under the encyclopedia text respectively through the character vector and the word vector.

[0024] In an exemplary embodiment, the vector training unit comprises:

[0025] A replacement processing unit, used to replace the words obtained by segmentation with identifiers according to the corresponding semantic content, and to construct a mapping between the identifiers and the names indicated by the corresponding semantic content, wherein the words exist in the form of identifiers;

[0026] The training execution unit is used to train character vectors and word vectors for the characters and words obtained by segmentation according to the context information in the encyclopedia text, and map the character vectors to the corresponding characters, and map the word vectors to the identifiers of the corresponding words that are replaced.

[0027] In an exemplary embodiment, the first vector representation unit includes:

[0028] A word vector acquisition unit, used to acquire the word vector mapped by the word in the hypernym;

[0029] A density interpolation unit is used to perform density interpolation of the word vectors mapped by the words in the hypernym according to the order of the words in the hypernym and the specified expansion multiple, to obtain the vector representation of the hypernym under the encyclopedia text, and the vector representation is the initial word vector of the hypernym.

[0030] In an exemplary embodiment, the multi-source information includes labels, and the first vector representation unit includes:

[0031] A word vector acquisition unit, used to acquire the word vector corresponding to the entity according to the identifier mapped by the name;

[0032] A label vectorization unit is used to generate a vector representation of the entity in the encyclopedia text according to the word vector and the label of the entity, wherein the vector representation is an entity vector.

[0033] In an exemplary embodiment, the multi-source information includes category information, and the numerical conversion module includes:

[0034] A category acquisition unit, used to acquire category information corresponding to the hypernym and entity respectively;

[0035] The category vectorization unit is used to generate set representations corresponding to the hypernyms and entities respectively through the sets formed by the corresponding category information, and the set representations are vector representations corresponding to the hypernyms and entities respectively under the category information.

[0036] In an exemplary embodiment, the category acquisition unit is further used to acquire, based on all entities corresponding to the hypernym, category information corresponding to all entities as the category information corresponding to the hypernym.

[0037] In an exemplary embodiment, the category vectorization unit is further used to perform vector mapping of whether the corresponding category information exists in the set according to the set consisting of the category information corresponding to the hypernyms and entities, on the dimension value matching the number of divided categories, to obtain the set representations corresponding to the hypernyms and entities respectively.

[0038] In an exemplary embodiment, the prediction module comprises:

[0039] A non-linear encoding unit is used to perform non-linear encoding on each long vector through a hidden layer in the fully connected neural network to obtain a deep semantic vector that represents the information between the hypernym and the entity through a numerical description;

[0040] A summarizing unit, used to summarize the information of all deep semantic vectors, so as to obtain the corresponding hyponym relationship semantic vector for triggering the identification of the hyponym relationship;

[0041] The binary classification unit is used to perform binary classification of the hypernymy relationship according to the hypernymy semantic vector, and output the discrimination result through the fully connected neural network through the binary classification.

[0042] In an exemplary embodiment, the binary classification unit is further used to perform probability mapping of relationship correctness scores on the hyponymy and hyponymy semantic vectors through a binary classifier constructed by the output layer in the fully connected neural network to obtain a discrimination result indicating the probability of correctness of the hyponymy and hyponymy relationship.

[0043] A computer device, comprising:

[0044] Processor; and

[0045] A memory having computer-readable instructions stored therein, wherein the computer-readable instructions implement the aforementioned method when executed by the processor.

[0046] The technical solution provided by the embodiments of the present invention may have the following beneficial effects:

[0047] For a given hypernym relationship, the hypernym and entity corresponding to the hypernym relationship are obtained, and the hypernym and entity are converted into corresponding mathematical descriptions through the obtained multi-source information to obtain vector representations corresponding to the hypernym and entity respectively. For the vector representations of the hypernym and entity corresponding to each information source, the two represented vectors are concatenated to obtain a long vector. Finally, a deep semantic vector is generated based on the projection of the long vector on the fully connected neural network. This deep semantic vector will correspond to the discrimination result of the given hypernym relationship at the output of the fully connected network. Therefore, for the discrimination of the hypernym relationship, it is only necessary to obtain the vector representation in the algorithm, and the discrimination result is obtained with the help of the fully connected neural network. The algorithm overhead is greatly reduced, and it can also be adapted to the discrimination of various hypernyms. The generalization ability is enhanced, so that the semantic features can be accurately captured, thereby improving the accuracy of the discrimination accordingly.

[0048] It is to be understood that the foregoing general description and the following detailed description are exemplary only and are not restrictive of the invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0050] Figure 1 is a schematic diagram of an implementation environment involved in the present invention according to an exemplary embodiment;

[0051] Figure 2 is a block diagram of a device according to an exemplary embodiment;

[0052] Figure 3 is a flow chart of a method for determining a superior-female relationship according to an exemplary embodiment;

[0053] Figure 4 It is a flowchart of the steps of converting the mathematical description of the hypernyms and entities in each information source into the text information related to the hypernyms and entities in multiple information sources according to an exemplary embodiment, and obtaining the vector representation steps corresponding to the hypernyms and entities in each information source respectively when the multi-source information includes encyclopedia text;

[0054] Figure 5 is based on Figure 4 A flowchart describing step 353 is shown in the corresponding embodiment;

[0055] Figure 6 is based on Figure 5 A flowchart describing step 355 is shown in the corresponding embodiment;

[0056] Figure 7 is based on Figure 5 A flowchart describing step 355 is shown in the corresponding embodiment;

[0057] Figure 8 It is a flowchart describing the steps of converting the mathematical description of hypernyms and entities in each information source according to text information related to hypernyms and entities in multiple information sources, and obtaining vector representations corresponding to the hypernyms and entities in each information source, according to an embodiment;

[0058] Fig. 9 is based on Figure 3 A flowchart describing step 370 is shown in the corresponding embodiment;

[0059] Fig.10 is a schematic diagram of an application of superior-female relationship discrimination according to an exemplary embodiment;

[0060] Fig.11 The present invention is a structural block diagram of a system for distinguishing a hierarchical relationship according to an embodiment. DETAILED DESCRIPTION

[0061] Here, exemplary embodiments will be described in detail, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.

[0062] Figure 1 It is a schematic diagram of the implementation environment involved in the present invention according to an exemplary embodiment. In an exemplary embodiment, the hierarchical relationship discrimination implemented by the present invention will be implemented for the constructed knowledge base, that is, the knowledge graph, to ensure that the constructed hierarchical relationships are correct and eliminate incorrect hierarchical relationships.

[0063] like Figure 1 As shown, the real-time environment involved in the present invention includes a knowledge graph database 110 and an application service 130 implemented on this basis.

[0064] It should be understood that the application service 130 referred to herein, through the implementation of the present invention, performs hierarchical and subhierarchical relationship judgment on the knowledge graph database 110 to judge the correctness of each hierarchical and subhierarchical relationship in the knowledge graph database 110.

[0065] The knowledge graph database 110 stores knowledge graph data. For example, the knowledge graph data is stored in the form of "entity-relationship-event-attribute", and the relationship referred to here includes the hypernym-hypernym relationship, which is in the form of "hypernym-hypernym-entity-attribute".

[0066] The knowledge graph is the knowledge base in the machine's brain and the infrastructure for artificial intelligence applications. For machines and the artificial intelligence applications to be implemented, semantic-based retrieval and complex reasoning will be achieved through knowledge graphs.

[0067] Figure 1 In the implementation environment shown, when the application service 130 implementing the present invention is running, the knowledge graph data with hierarchical relationships are screened. If the existing hierarchical relationships are wrong through the judgment implemented by the present invention, the knowledge graph data needs to be eliminated accordingly to ensure the reliability of the knowledge graph database.

[0068] Figure 2 It is a block diagram of a device according to an exemplary embodiment. Figure 1 The application service 130 shown is running in a machine device, which may be an apparatus 200, for example, the apparatus 200 may be a server.

[0069] Reference Figure 2 The device 200 may have relatively large differences due to different configurations or performances, and may include one or more central processing units (CPU) 222 (for example, one or more processors) and memory 232, one or more storage media 230 (for example, one or more mass storage devices) storing application programs 242 or data 244. Among them, the memory 232 and the storage medium 230 can be short-term storage or persistent storage. The program stored in the storage medium 230 may include one or more modules (not shown in the figure), and each module may include a series of instruction operations on the server. Furthermore, the central processing unit 222 can be configured to communicate with the storage medium 230 and execute a series of instruction operations in the storage medium 230 on the device 200. The device 200 may also include one or more power supplies 226, one or more wired or wireless network interfaces 250, one or more input and output interfaces 258, and / or, one or more operating systems 241, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc. The following Figure 3 , Figure 4 , Figure 5 , Figure 6 , Figure 7 , Figure 8 and Fig. 9 The steps performed by the third party in the illustrated embodiment may be based on the Figure 2 The device structure shown.

[0070] Figure 3 is a flow chart of a method for determining a superior-inferior relationship according to an exemplary embodiment. In an exemplary embodiment, the method for determining a superior-inferior relationship is as follows: Figure 3 As shown, at least the following steps are included.

[0071] In step 310, the hypernyms and entities corresponding to the hyponym relationship are obtained.

[0072] Among them, the hypernym relationship indicates the relationship between the subject departments. If there is a hypernym relationship between a subject term with a broader concept and a subject term with a narrower concept, the subject term with a broader concept is the hypernym, and the subject term with a narrower concept is the entity. In other words, the hypernym is an attribute or classification method expressed by the entity.

[0073] For the constructed hypernymy relationship, in the correctness judgment, it is necessary to obtain the hypernym and entity of the hypernymy relationship. As mentioned above, the hypernymy relationship can exist in the knowledge graph.

[0074] Correspondingly, in an exemplary embodiment, step 310 includes: according to the hyponym and hyponym relationship determination triggered in the knowledge graph, the corresponding hypernyms and entities are obtained from the hyponym and hyponym relationships constructed in the knowledge graph, and the obtained hypernyms and entities are used to determine the hyponym and hyponym relationships.

[0075] In the knowledge graph, the edges between nodes indicate the relationship between the topics corresponding to the nodes, including the hierarchical relationship. By extracting entities, relationships, and attributes in the data, knowledge representation is obtained, and then the knowledge graph is formed after aligning the entities to build the ontology, and the hierarchical relationship existing in the knowledge graph is judged.

[0076] Therefore, it should be understood that in the execution of step 310, the hypernymy relationship refers to any existing hypernymy relationship, and the determination of the hypernymy relationship will be initiated by obtaining the hypernym and entity corresponding to the hypernymy relationship. For all constructed hypernymy relationships, the correctness determination can be achieved through the execution of the present invention.

[0077] In step 330, the hypernyms and entities are converted into corresponding mathematical descriptions through the acquired multi-source information to obtain vector representations corresponding to the hypernyms and entities respectively.

[0078] Among them, the hypernyms and entities obtained from a hyponym-hypernym relationship are respectively converted into corresponding mathematical descriptions to obtain the vector representation corresponding to the hypernym and the vector representation corresponding to the entity.

[0079] Regardless of hypernyms and entities, the corresponding vector representations are obtained based on the available multi-source information. Multi-source information is text information related to hypernyms and entities from multiple information sources. In an exemplary embodiment, the multi-source information includes encyclopedia texts, tags, and category information related to hypernyms and entities. In addition, it will also include information such as attributes, which is not limited here. Depending on the different information sources that can be accessed, a variety of different text information can be obtained.

[0080] In the multi-source information that can be obtained for hypernyms and entities, mathematical descriptions are performed for hypernyms and entities from multiple levels through the multiple text information contained therein, so as to obtain vector representations of hypernyms and entities at each level. In other words, in the multiple text information of the multi-source information, one or more text information is used to transform hypernyms and entities into mathematical descriptions, so as to obtain vector representations of hypernyms and entities at the corresponding levels.

[0081] Multi-source information is related to hypernyms and entities. The various text information in multi-source information comes from different information sources. Specifically, for encyclopedia text, the text information comes from the information items of encyclopedia text data, and the corresponding information source is encyclopedia data; for tags, the text information comes from the annotation data mapped by the entity in the knowledge graph, that is, the annotation data is an information source; for category information, the text information comes from the category attributes of the entity in the knowledge graph, which can be directly obtained from the knowledge graph. Therefore, for the acquisition of category information, the knowledge graph itself is an information source.

[0082] For the transformation of hypernyms and entities into mathematical descriptions, on one level, the corresponding vector representations will be obtained based on the encyclopedia text. Furthermore, the vector representations corresponding to the hypernyms and entities can be obtained based on the encyclopedia text and combined with the labels. On another level, the vector representations corresponding to the hypernyms and entities will also be obtained based on the labels, and so on, making full use of multi-source information to realize the mathematical description of hypernyms and entities.

[0083] At this point, since multi-source information is text that represents the semantics of hypernyms and entities, the hypernyms and entities are converted into corresponding mathematical descriptions and then vector representations are obtained. This process is implemented based on multi-source information, so that the mathematical descriptions of hypernyms and entities are related to semantics, and the semantics corresponding to the hypernyms and entities can be represented in the mathematical description, and the vector representation is closely related to the semantics.

[0084] In an exemplary embodiment, the multi-source information is text information related to hypernyms and entities in multiple information sources, and step 330 includes:

[0085] According to the text information related to the hypernyms and entities in multiple information sources, the mathematical description transformation of the hypernyms and entities in each information source is performed respectively to obtain the vector representations corresponding to the hypernyms and entities in each information source.

[0086] Among them, the text information related to hypernyms and entities comes from one information source and constitutes multi-source information together with the text information of other information sources. There is a correlation between this text information and hypernyms and entities. In other words, this text information is a semantic description of hypernyms and entities through various text contents. For example, if this text information is an encyclopedia text, the entry explanation of the hypernym is the text information referred to here, and this entry explanation involves the entity corresponding to the hypernym. For example, the entry explanation of a hypernym is often a conceptual description of the hypernym, and the specific affairs corresponding to the concept described, that is, an example of the entity. Therefore, for the entry explanation of this hypernym, there is a hierarchical relationship between the hypernym and the entity. In the judgment of the hierarchical relationship, the encyclopedia text related to the hypernym and the entity can be mathematically described to obtain a vector representation that is semantically adapted to the hypernym and the entity in the encyclopedia text.

[0087] The text information related to the hypernym and entity is the various types of texts related to the hypernym and entity, which can be obtained by searching the hypernym and entity respectively. The various types of text information obtained form multi-source information for judging the hypernym and entity relationship.

[0088] The judgment of the hyponym and hyponym relationship is carried out, and multi-source information with as rich semantics as possible is obtained according to the available information sources, so that the numerical conversion of hypernyms and entities can capture as many semantic features as possible with the assistance of multi-source information, so as to accurately judge whether there is indeed a hyponym and hyponym relationship between the hypernym and the entity in semantics, so as to avoid the occurrence of misjudgment.

[0089] In step 350, the vector representations of the hypernyms and entities corresponding to an information source are concatenated to obtain a long vector.

[0090] As mentioned above, the vector representation of hypernyms and entities corresponds to the information source, which is the text information based on which the vector representation of hypernyms and entities is generated. By executing step 330, at least one set of vector representations will be obtained, that is, a mathematical description of hypernyms and entities at a level provided by the information source, and by analogy, mathematical descriptions of hypernyms and entities will be performed at all levels.

[0091] Correspondingly, between hypernyms and entities, vector representations corresponding to the same information source are concatenated, that is, a set of vector representations are concatenated to obtain a long vector. Similarly, among several sets of vector representations corresponding to hypernyms and entities obtained from multi-source information, each set of vector representations is concatenated to obtain a long vector corresponding to each set of vector representations.

[0092] The vector representation of hypernyms and entities is closely related to semantics. Therefore, the long vector obtained by concatenation is a vector based on the semantic features of hypernyms and entities. On the one hand, the long vector provides a mathematical description of the semantic relevance of hypernyms and entities. On the other hand, it also provides a mathematical description of the relationship between hypernyms and entities through concatenation. Through the above steps, the long vector obtained can accurately mathematically describe the hypernyms, entities, and the relationship between the two in semantics, laying the foundation for the realization of accurate discrimination of the hypernym and hyponym relationship.

[0093] In step 370, a deep semantic vector is generated based on the projection of the long vector on the fully connected neural network. The output of the deep semantic vector on the fully connected neural network corresponds to the judgment result of the superior-subordinate relationship.

[0094] Among them, the fully connected neural network is obtained for the correctness prediction training of the upper and lower relations. Taking the long vector as input, the deep semantic vector representation is learned through the fully connected neural network, so as to obtain the fully connected neural network suitable for the correctness prediction training of the upper and lower relations.

[0095] There is a nonlinear relationship between hypernyms and entities. Therefore, the deep semantic vector obtained in the fully connected neural network will be obtained by mapping the learned nonlinear relationship, that is, the deep semantic relationship to the long vector.

[0096] Therefore, under the action of the obtained deep semantic vector, the fully connected neural network outputs the correctness probability of the corresponding hierarchical relationship, and the correctness probability of the hierarchical relationship indicates the judgment result of whether the corresponding hierarchical relationship is correct.

[0097] In a specific implementation of an exemplary embodiment, the fully connected neural network is a three-layer neural network, including an input layer, a hidden layer and an output layer. The hidden layer is used to fully utilize the information between the hypernym and the entity in the long vector through nonlinear combination to obtain a hidden layer vector containing the relationship between the two, that is, a deep semantic vector, which is a semantic feature representation of the hypernym relationship.

[0098] In the judgment of the hierarchical relationship, the semantically related multi-source information and the continuous in-depth capture of semantic features make the judgment results more accurate, and because only vector mapping and fully connected neural network prediction are required, the algorithm overhead is greatly reduced.

[0099] In addition, in the judgment of the hyponym and the relationship, since the hypernym and the entity are mapped into vectors and then realized through a fully connected neural network, it can be applied to various hypernyms and various entities corresponding to the hypernyms. The judgment of the hyponym and the relationship is no longer limited by various situations of the hypernym and the entity, and the expected results cannot be obtained. The judgment of the hyponym and the relationship is adapted to various hypernyms and has a very strong generalization ability.

[0100] Figure 4 It is a flowchart showing the steps of converting the mathematical description of the hypernyms and entities in each information source into vector representations corresponding to the hypernyms and entities in each information source respectively according to an exemplary embodiment when the multi-source information includes encyclopedia text.

[0101] In an exemplary embodiment, the multi-source information includes encyclopedic texts, such as Figure 4 As shown, according to the text information related to the hypernyms and entities in multiple information sources, the mathematical description transformation of the hypernyms and entities in each information source is performed to obtain the vector representation steps corresponding to the hypernyms and entities in each information source, including:

[0102] In step 331, the encyclopedia text is segmented according to the character segmentation granularity and the word segmentation granularity to obtain the characters and words obtained by segmentation in the encyclopedia text.

[0103] The segmentation process referred to herein is a process of segmenting the encyclopedia text according to a specified processing granularity. By executing the segmentation process, a number of segmentation results adapted to the specified processing granularity are obtained.

[0104] The processing granularity is the unit of segmentation of the encyclopedia text during the segmentation process, which is used to control the length between the current segmentation position and the next segmentation position during the segmentation of the encyclopedia text. This length facilitates the linear correlation of the processing granularity.

[0105] For the segmentation process, the processing granularity includes character segmentation granularity and word segmentation granularity. That is to say, the encyclopedia text is segmented according to character segmentation granularity on the one hand, and segmented according to word segmentation granularity on the other hand, thereby obtaining characters obtained by segmentation from the encyclopedia text and words obtained by segmentation according to word segmentation granularity respectively.

[0106] It should be understood that the characters obtained by segmentation are independent entities of all the characters in the encyclopedia text; correspondingly, the words obtained by segmentation are independent entities of all the words in the encyclopedia text.

[0107] It should be noted that the word granularity referred to includes consecutive English letters, numbers, Chinese characters and other symbols. In other words, consecutive English letters, a number, a Chinese character and another symbol are all a word.

[0108] In step 333, characters and words are represented as real-valued vectors according to the encyclopedia text to obtain character vectors and word vectors, where the word vectors are related to the context information of the encyclopedia text.

[0109] Among them, the encyclopedia text used for segmentation corresponds to certain semantic content. For the related hypernyms and entities, the semantic content corresponding to the encyclopedia text describes the hypernyms, entities and the semantic relationship between the two. Therefore, the characters and words will be represented as real value vectors according to the encyclopedia text.

[0110] All the characters obtained by segmentation are represented as real-valued vectors according to the encyclopedia texts to obtain word vectors; correspondingly, all the words obtained by segmentation are also represented as real-valued vectors according to the encyclopedia texts to obtain word vectors.

[0111] For the segmented characters and words, the corresponding character vectors or word vectors can be obtained. Both character vectors and word vectors correspond to the context information of the encyclopedia text, making full use of the semantic content in the encyclopedia text, thus fully improving the accuracy of mathematical description of character vectors and word vectors.

[0112] Context information is information that semantically describes the relationship between the word vector and the word in the encyclopedia text. In the encyclopedia text, the position of the word and its surrounding words will give the word certain semantic content, for example, the existence of words with the same name but different meanings in the text. Therefore, the acquisition of word vectors must be related to the context information of the encyclopedia text.

[0113] It should be understood that the implementation of steps 331 to 333 is not performed in the corresponding determination of the hyponymy relationship. It is only necessary to train the character vector and word vector in advance through the execution of steps 331 to 333. In other words, in the determination of the hyponymy relationship, the required character vector and word vector can be obtained according to the hypernym and entity, and it is not necessary to construct the character vector and word vector immediately.

[0114] In step 335, vector representations of hypernyms and entities in encyclopedia texts are constructed using character vectors and word vectors, respectively.

[0115] Among them, both hypernyms and entities are composed of certain characters and / or words. Therefore, the vector representation construction process related to the encyclopedia text is carried out through the corresponding character vectors and / or word vectors to obtain hypernym vectors and entity vectors.

[0116] Through this exemplary embodiment, hypernyms and entities can obtain corresponding vector representations by capturing the semantic content of the encyclopedia text, and in the performed encyclopedia text segmentation, even the character vectors and word vectors used to obtain the vector representations are adapted to the semantic content of the encyclopedia text. The processing process is simple and cannot guarantee accuracy, and does not require a large algorithm overhead.

[0117] Figure 5 is based on Figure 4 The flowchart of step 353 is shown in the corresponding embodiment. In an exemplary embodiment, as Figure 5 As shown, step 353 at least includes:

[0118] In step 401, the words obtained by segmentation are replaced with identifiers according to the corresponding semantic content, and a mapping between the identifier and the name indicated by the corresponding semantic content is constructed. The word exists in the form of an identifier.

[0119] As mentioned above, the characters and words in the encyclopedia text are obtained by segmentation through the execution of step 351. That is, through the segmentation process of character segmentation granularity and word segmentation granularity, both a number of characters mapped to the encyclopedia text and a number of words mapped to the encyclopedia text are obtained.

[0120] For all the words obtained by segmentation, they have different semantics at different positions in the encyclopedia text, that is, there are cases where the same name has different meanings (polysemy). Therefore, it is necessary to replace the identifiers according to the corresponding semantics in the encyclopedia text to avoid the same words with different semantics being treated the same, which will interfere with the obtained word vector and greatly affect the accuracy of the mathematical description of the semantics by the word vector.

[0121] The identifier is a globally unique identifier, namely ID (identity). For each word obtained by segmentation, the identifier is replaced according to the corresponding semantic content to uniquely identify the word corresponding to a semantic content.

[0122] The semantic content based on which the replacement identifier is based can be obtained from the encyclopedia text itself, on the one hand, and extracted from the constructed knowledge graph data, on the other hand, and can also be obtained by combining the encyclopedia text and text retrieval of the word, which is not limited here. For a word, its semantic content is the name, description or even explanation of the word, which can be expressed by text, images, audio and video.

[0123] Corresponding to a word of a semantic content, the activation of the corresponding identifier requires the construction of a mapping between the identifier and the name indicated by the semantic content to facilitate subsequent search, and the definition of the semantic content mapped by the identifier as the word.

[0124] The words obtained from the segmentation of the encyclopedia text are replaced by identifiers, and the segmented words exist in the data form of the identifiers.

[0125] In step 403, for the characters and words obtained by segmentation, character vectors and word vectors are trained according to the context information in the encyclopedia text, and the character vectors and word vectors are mapped to the corresponding characters, and the word vectors are mapped to the identifiers of the corresponding words that are replaced.

[0126] Among them, after replacing the identifiers of the words obtained by segmentation to eliminate the interference of polysemy, the character vector and word vector training can be carried out to obtain the character vector mapped by the character and the word vector mapped by the identifier.

[0127] As mentioned above, character vectors and word vectors will be trained based on the contextual information of the encyclopedia text to ensure that the obtained character vectors and word vectors can provide accurate semantic descriptions and fully capture semantic features.

[0128] For each character and each word, the character vector and word vector are mapped according to its context information in the encyclopedia text, that is, the surrounding characters and surrounding words. In an exemplary embodiment, the surrounding characters and surrounding words are obtained by the sliding window where the characters and words for vector mapping are located, and the sliding window is located, that is, the surrounding characters and surrounding words for vector mapping.

[0129] That is to say, in a specific implementation of an exemplary embodiment, in the character sequence and word sequence obtained after the segmentation, the context information is located under the control of the sliding window, and then vector mapping is performed on this basis.

[0130] Specifically, the character vector and word vector training is the process of building a dictionary by learning the representation of text and knowledge. The trained character vector and word vector form a dictionary. In this dictionary, the key value is the identifier corresponding to the character or word, and the character vector and word vector itself is the value mapped by the key value.

[0131] In an exemplary embodiment, the word vector and word vector training are implemented by the Word2Vec model. The word vector and word vector are trained separately using the Word2Vec model. For texts related to hypernyms and entities, i.e., encyclopedic texts, it is not limited to a single text. The word vector and word vector training is based on large-scale unstructured text. Therefore, both the word vector and word vector have certain semantic features.

[0132] Through this exemplary embodiment, the training of word vectors and character vectors under encyclopedia text is implemented, so as to obtain semantically accurate word vectors and character vectors.

[0133] Figure 6 is based on Figure 5 The flowchart of step 355 is shown in the corresponding embodiment. In an exemplary embodiment, as Figure 6 As shown, step 355 includes:

[0134] In step 501 , the word vector mapped to the word in the hypernym is obtained.

[0135] In step 503, density interpolation of the word vectors mapped by the words in the hypernym is performed according to the order of the words in the hypernym and the specified expansion multiple, to obtain a vector representation of the hypernym in the encyclopedia text, and the vector representation is the initial word vector of the hypernym.

[0136] Among them, for the hypernym, it is composed of characters. Therefore, the mapped character vector is obtained according to the characters in the hypernym, and the character vector mapped by the characters in the hypernym is converted into the dense vector of the hypernym, that is, the vector representation of the hypernym in the encyclopedia text. This vector representation is the initial word vector of the hypernym.

[0137] The vector representation of the hypernym is achieved by concatenating the word vectors mapped by the characters in the hypernym. This concatenation process will be performed according to the order of the characters in the hypernym and the specified expansion multiple.

[0138] The corresponding word vectors are spliced ​​according to the order of the characters in the hypernym, so that the word vectors at different positions constitute different parts of the word vector, which can ensure the string order information. The word vector contains a certain semantic similarity, so the word vector synthesized by the word vector has certain semantic characteristics, and the semantic accuracy represented by the spliced ​​vector is enhanced under the guaranteed string order information.

[0139] Specifying the expansion factor is used to control the dimensionality of the hypernym vector representation obtained. The number of characters in different hypernyms may vary greatly. When using character vectors to synthesize the hypernym vector representation, it is necessary to ensure that this vector representation has a fixed dimension and does not change accordingly with the number of characters in the hypernym, so as to avoid high computational complexity and amount of calculation.

[0140] Under the control of the specified expansion multiple, it is necessary to perform density interpolation of the word vectors mapped by the characters in the hypernym to ensure that the obtained vector representation is of fixed dimension, and under the effect of the order of the characters in the hypernym, the vector representation can adapt to the string order in the hypernym, thereby ensuring the semantics of the character combinations in different positions.

[0141] Regardless of the number of hypernyms, the vector representation obtained must meet the specified expansion factor, which is used to indicate the expansion factor of the dimension corresponding to the word vector, and the dimension of the word vector is fixed. Therefore, when facing hypernyms of any number of words, it is necessary to perform density interpolation of the word vectors mapped by the words in the hypernym to obtain the vector representation of the hypernym.

[0142] In this exemplary embodiment, the vector representation of the hypernym is obtained at the level of the encyclopedia text. This can be used as a basis for judging whether there is indeed a hypernym relationship between the hypernym and the entity. However, it is also possible to further enhance the accuracy of the mathematical description of the hypernym on this basis. Therefore, the vector representation of the hypernym obtained in this exemplary embodiment can be used as the initial vector of the hypernym.

[0143] In an exemplary embodiment, density interpolation of the word vectors mapped by the words in the hypernym is performed according to the order of the words in the hypernym and the specified expansion multiple to obtain the vector representation of the hypernym in the encyclopedia text. This process is achieved by executing a density interpolation vectorization algorithm.

[0144] Specifically, for a hypernym, the characters in which it exists are traversed in order, and the first i characters, the interpolation position of the corresponding word vector is determined by the order of the characters in the hypernym S , and then interpolate the position at the length corresponding to the specified expansion multiple S Compute interpolation density d , and then interpolate the word vectors in the word vector concatenation, that is:

[0145] v m =v m +d*char i

[0146] Among them, v represents the hypernym vector, char i Indicates i characters, M indicates the specified expansion multiple, m=0 to M-1 .

[0147] In a specific implementation of an exemplary embodiment, S=M*(i+1) ; d=pow(1-(abs(sm)) / M,2) .

[0148] Figure 7 is based on Figure 5 The flowchart of step 355 is shown in the corresponding embodiment. In an exemplary embodiment, the multi-source information includes tags, such as Figure 7As shown, step 355 includes:

[0149] In step 601, the word vector corresponding to the entity is obtained according to the identifier mapped to the name.

[0150] In step 603, a vector representation of the entity in the encyclopedia text is generated based on the word vector and the label of the entity, and the vector representation is an entity vector.

[0151] Among them, Figure 5 As described in the corresponding embodiment, for a word, the word vector is mapped to the identifier, and the identifier is mapped to the name indicated by the semantic content of the word. Therefore, when it is necessary to obtain the word vector corresponding to a word, it is only necessary to obtain it from the mapped identifier according to the name corresponding to the word. The name can be obtained through the semantic content of the entity in the knowledge graph data.

[0152] In the knowledge graph data, entities also have annotated labels, so the labels can be combined to further describe the semantics corresponding to the entity and obtain the entity vector.

[0153] At this point, under the influence of these two types of text information, encyclopedia text and tags, we can fully utilize the available multi-source information to capture the semantics of entities and provide accurate data input for subsequent relationship judgment.

[0154] The label of an entity can reflect the semantic characteristics of the entity. For example, the label of the "XXX" entity is "music, singer, Chinese", etc. Labels are closely related to semantics. The vector of the label corresponding to the entity is obtained based on the word vector, that is, {T 1 ,T 2 ,...,T n}, the number of entity tags is n.

[0155] The vectors of the entity and the label are averaged to obtain the entity vector (E+T 1 +T 2 +...+T n ) / (n+1), E is the word vector corresponding to the entity, and the average vector obtained by accumulating the word vector corresponding to the entity and the vectors of all labels is the entity vector.

[0156] Figure 8 The flowchart is a flowchart describing the steps of converting the mathematical description of hypernyms and entities in each information source into vector representations corresponding to the hypernyms and entities in each information source according to an embodiment. In an exemplary embodiment, the multi-source information includes category information, such as Figure 8As shown, according to the text information related to hypernyms and entities in multiple information sources, mathematical description transformation of hypernyms and entities in each information source is performed to obtain vector representation steps corresponding to hypernyms and entities in each information source, which at least includes:

[0157] In step 801, the category information corresponding to the hypernym and entity is obtained.

[0158] In step 803, a set is formed by corresponding category information, and set representations corresponding to hypernyms and entities are generated respectively. The set representations are vector representations corresponding to hypernyms and entities respectively under the category information.

[0159] The category information corresponding to the hypernym and entity word comes from the attributes of the hypernym and entity. For example, in the constructed knowledge graph data, both the hypernym and the entity have corresponding attributes, which indicate the corresponding category.

[0160] Whether it is a hypernym or an entity, the obtained category information indicates the several categories to which it belongs, and the categories indicated by the category information exist independently of each other. The category information including several categories is also a text. In this text, the order, grammar, syntax and other elements of the words are ignored, and it is only regarded as a collection of several words. Each word appears independently and does not depend on whether other words appear. In other words, any word that appears at any position in the text exists independently without being affected by the semantics of the text. Therefore, the set representation corresponding to the hypernym and entity will be generated to adapt to this feature.

[0161] The category information corresponding to the hypernym and the category information corresponding to the entity are obtained. The categories included in the obtained category information constitute a set, and the set is used as text to generate the set representation of the other party.

[0162] In another exemplary embodiment, step 803 includes: respectively performing a vector mapping of whether the corresponding category information exists in the set according to the set consisting of the category information corresponding to the hypernym and the entity on the dimension value matching the number of divided categories, and obtaining the set representation corresponding to the hypernym and the entity respectively.

[0163] In a specific implementation of an exemplary embodiment, a set consisting of corresponding category information is mapped to a vector through a bag-of-words model, and this vector is a set representation. Assuming that the total number of categories is N, the length of the vector generated by the mapping is N, where for the dimension value in the vector, if the corresponding category exists, it is mapped to 1, and if the corresponding category does not exist, it is mapped to 0.

[0164] Each entity corresponds to one or more categories, which reflect the semantic features of the entity. For example, the categories of the "XXX" entity are "movie star, singer", etc.

[0165] A hypernym may correspond to multiple entities. For a hypernym, the acquisition of its category information in the execution of step 801 includes: according to all entities corresponding to the hypernym, acquiring the category information corresponding to all entities as the category information corresponding to the hypernym.

[0166] In the knowledge graph data, a hypernym often has a hypernym relationship with multiple entities, and each entity has a corresponding category. It can be understood that the category of the corresponding entity is a semantic description of the hypernym from multiple aspects. Therefore, the categories corresponding to all entities form the category information corresponding to the hypernym.

[0167] Fig. 9 is based on Figure 3 The flowchart of step 370 is shown in the corresponding embodiment. In an exemplary embodiment, as Fig. 9 As shown, step 370 includes:

[0168] In step 371, nonlinear encoding is performed on each long vector through a hidden layer in a fully connected neural network to obtain a deep semantic vector that represents the information between the hypernym and the entity through numerical description.

[0169] As mentioned above, the fully connected neural network is a three-layer neural network, and it captures semantics from multiple levels through multiple text information in multiple source information, thereby obtaining multiple long vectors based on semantic features. In other words, the vector representations of the hypernyms and entities corresponding to an information source are concatenated to obtain more than one long vector.

[0170] The fully connected neural network is used to predict the correctness of the hierarchical relationship. In the prediction made by this fully connected neural network, a long vector is taken as input, and the output indicates the probability of whether the hierarchical relationship is correct, so as to obtain the judgment result accordingly.

[0171] In an exemplary embodiment, the fully connected neural network is configured with a hidden layer in addition to the input layer and the output layer. The hidden layer is between the input layer and the output layer, and is used to fully utilize the information between the hypernym and the entity through nonlinear combination to obtain a hidden layer vector containing the relationship between the two, that is, a deep semantic vector.

[0172] Each long vector input to the fully connected neural network obtains the corresponding deep semantic vector through the hidden layer. The original data, that is, the long vector, is input into the hidden layer, and the parameters trained by the fully connected neural network are projected to generate a new vector, that is, the feature generation process is performed, thereby obtaining the deep semantic vector corresponding to this long vector.

[0173] Through the nonlinear encoding of long vectors, the nonlinear mapping of long vectors is realized, and the semantic changes are fully utilized to perform nonlinear operations, thereby ensuring the realization of deeper semantic mining.

[0174] In step 373, information of all deep semantic vectors is summarized to obtain corresponding hyponymous and hyponymous relationship semantic vectors for triggering the identification of hyponymous and hyponymous relationships.

[0175] The information aggregation refers to the concatenation of all deep semantic vectors to obtain a semantic vector representation of the hierarchical relationship, namely, a hierarchical relationship semantic vector.

[0176] In step 375, a binary classification of the hypernymy relationship is performed based on the hypernymy semantic vectors, and a fully connected neural network is used to output the discrimination result through the binary classification.

[0177] Among them, the binary classification of the hierarchical relationship is the execution process of predicting whether the hierarchical relationship is correct or incorrect, and the binary classification of the hierarchical relationship will output one of the two results of correct and incorrect.

[0178] In a specific implementation of an exemplary embodiment, step 375 includes: performing probability mapping of the correctness of the relationship on the semantic vectors of the hierarchical relationship through a binary classifier constructed by the output layer in the fully connected neural network, and obtaining a judgment result indicating the probability of the correctness of the hierarchical relationship.

[0179] In a specific implementation of an exemplary embodiment, a softmax layer is used to perform binary classification of the superior-female relationship.

[0180] The softmax layer is used as the final decoding step to predict the correctness of the hierarchical relationship. The softmax layer gives the probability of the hierarchical relationship being correct and the probability of the hierarchical relationship being incorrect. The softmax layer enables selection based on the hierarchical relationship itself, rather than just based on the information captured from the context.

[0181] In the exemplary embodiment described above, the use of multi-source information makes the performed hierarchical relationship discrimination have rich semantically relevant information. Different information often has quite different distributions in different situations. Therefore, it can be utilized in the performed hierarchical relationship discrimination and integrated into the hierarchical relationship discrimination to improve the performance of the algorithm and enhance accuracy.

[0182] Through the exemplary embodiments described above, deep semantic representation of hypernyms and entities is achieved, and the semantic vectors of the hypernym and hyponym relationships, i.e., the long vector referred to above, are calculated from multi-source information such as encyclopedia texts, tags, entity categories, etc., and then a fully connected neural network is used to fully utilize the association between the semantics of the two to achieve relationship discrimination through nonlinear combination mapping.

[0183] Taking the knowledge graph as an example, the implementation of the above method to distinguish the upper and lower relationships is described to achieve the correctness of the upper and lower relationships. Each upper and lower relationship in the knowledge graph will be judged to ensure the correctness of the upper and lower relationships in the knowledge graph and eliminate incorrect upper and lower relationships.

[0184] The encyclopedia text is used as a large-scale unstructured text corpus to train word vectors and term vectors. The obtained term vector is mapped to a name corresponding identifier according to the semantics of the corresponding word. In other words, a dictionary is constructed by the trained word vectors and term vectors so that the required word vectors and term vectors can be directly obtained in the upper and lower level discrimination.

[0185] The correctness of the hypernymy and hyponymy in the knowledge graph is judged. The hypernymy and hyponymy relationships that are judged for correctness will obtain the corresponding hypernyms and entities, and then map them with the help of encyclopedia text, entity tags and entity type data to obtain hypernym vector representation and entity vector representation. Finally, the semantic vector representation is obtained under the action of the neural network, that is, the deep semantic vector mentioned above. The deep semantic vector is used to judge the hypernymy and hyponymy, that is, the correctness prediction of the hypernymy and hyponymy relationship.

[0186] In the implementation of this process, encyclopedia text, entity tags and entity type data constitute multi-source information, so that the implementation of hyponym and hyponym relationship discrimination can capture and utilize rich semantic features.

[0187] Fig.10 FIG. 1 is a schematic diagram of an application of a hierarchical relationship discrimination according to an exemplary embodiment. In an exemplary embodiment, Fig.10 As shown, first, character vectors and word vectors are trained in a corpus such as encyclopedia text, as shown in steps 1010 to 1020. In the execution of this process, the required character vectors and word vectors are trained through the Word2Vec model.

[0188] On this basis, a hypernym vector is generated for the hypernym through the DIE (Dense Interpolated Embedding) algorithm, as shown in step 1030 .

[0189] For entities, entity vectors are generated from the trained word vectors and entity labels, as shown in step 1040 .

[0190] This is the vector mapping process of hypernyms and entities assisted by encyclopedia text and entity labels. In addition, hypernym vectors and entity vectors will be constructed with the assistance of multi-source information such as entity type data. Specifically, as shown in step 1110, hypernyms and entities obtain hypernym vector representations and entity vector representations through entity type data under the action of the bag-of-words model.

[0191] The obtained hypernym vectors and entity vectors are input into the neural network. Under the action of the hidden layer in the neural network, hidden layer vector 1 and hidden layer vector 2 are obtained, which are the deep semantic vectors mentioned above. The semantic vector representation is obtained by concatenating hidden layer vector 1 and hidden layer vector 2, that is, the semantic vector of the hypernym relationship, thereby predicting the correctness of the corresponding hypernym relationship.

[0192] The implementation as described above can adapt to various hypernyms and various entities, and can thus achieve better results in the discrimination of any hypernym relationship, and has very good generalization capabilities. Under the influence of this implementation process, it can promote the development of knowledge mining, natural language processing, etc., and promote the advancement of artificial intelligence.

[0193] The following is an embodiment of the device of the present invention, which can be used to execute the above method embodiment of the present invention. For details not disclosed in the embodiment of the device of the present invention, please refer to the method embodiment of the present invention.

[0194] Fig.11 FIG. 1 is a structural block diagram of a system for distinguishing a hierarchical relationship according to an embodiment. Fig.11 As shown, in an exemplary embodiment, the hierarchical relationship determination system includes an acquisition module 1310 , a numerical conversion module 1330 , a splicing module 1350 and a prediction module 1370 .

[0195] An acquisition module 1310 is used to acquire hypernyms and entities corresponding to the hyponymy relationship;

[0196] A numerical conversion module 1330 is used to convert the hypernyms and entities into corresponding mathematical descriptions through the acquired multi-source information, and obtain vector representations corresponding to the hypernyms and entities respectively;

[0197] A concatenation module 1350 is used to concatenate vector representations of hypernyms and entities corresponding to an information source to obtain a long vector;

[0198] The prediction module 1370 is used to generate a deep semantic vector based on the projection of the long vector on the fully connected neural network, and the output of the deep semantic vector in the fully connected neural network corresponds to the discrimination result of the upper and lower relationship.

[0199] In another exemplary embodiment, the acquisition module 1310 is further used to determine the hyponymy relationship triggered in the knowledge graph, and to obtain corresponding hypernyms and entities from the hyponymy relationship constructed in the knowledge graph, and the hypernyms and entities are used to determine the hyponymy relationship.

[0200] In another exemplary embodiment, the multi-source information is text information related to the hypernyms and entities in multiple information sources, and the numerical conversion module 1330 is further used to perform mathematical description conversion of the hypernyms and entities in each information source according to the text information related to the hypernyms and entities in multiple information sources, so as to obtain vector representations corresponding to the hypernyms and entities in each information source.

[0201] In an exemplary embodiment, the multi-source information includes encyclopedia text, and the numerical conversion module 1330 includes:

[0202] A segmentation unit, used to perform segmentation processing on the encyclopedia text according to character segmentation granularity and word segmentation granularity, and obtain characters and words obtained by segmentation in the encyclopedia text;

[0203] A vector training unit, used for representing the characters and words as real-valued vectors according to the encyclopedia text, to obtain character vectors and word vectors, wherein the word vectors are related to the context information of the encyclopedia text;

[0204] The first vector representation unit is used to construct vector representations of the hypernym and entity under the encyclopedia text respectively through the character vector and the word vector.

[0205] In an exemplary embodiment, the vector training unit comprises:

[0206] A replacement processing unit, used to replace the words obtained by segmentation with identifiers according to the corresponding semantic content, and to construct a mapping between the identifiers and the names indicated by the corresponding semantic content, wherein the words exist in the form of identifiers;

[0207] The training execution unit is used to train character vectors and word vectors for the characters and words obtained by segmentation according to the context information in the encyclopedia text, and map the character vectors to the corresponding characters, and map the word vectors to the identifiers of the corresponding words that are replaced.

[0208] In an exemplary embodiment, the first vector representation unit includes:

[0209] A word vector acquisition unit, used to acquire the word vector mapped by the word in the hypernym;

[0210] A density interpolation unit is used to perform density interpolation of the word vectors mapped by the words in the hypernym according to the order of the words in the hypernym and the specified expansion multiple, to obtain the vector representation of the hypernym under the encyclopedia text, and the vector representation is the initial word vector of the hypernym.

[0211] In an exemplary embodiment, the multi-source information includes labels, and the first vector representation unit includes:

[0212] A word vector acquisition unit, used to acquire the word vector corresponding to the entity according to the identifier mapped by the name;

[0213] A label vectorization unit is used to generate a vector representation of the entity in the encyclopedia text according to the word vector and the label of the entity, wherein the vector representation is an entity vector.

[0214] In an exemplary embodiment, the multi-source information includes category information, and the numerical conversion module 1330 includes:

[0215] A category acquisition unit, used to acquire category information corresponding to the hypernym and entity respectively;

[0216] The category vectorization unit is used to generate set representations corresponding to the hypernyms and entities respectively through the sets formed by the corresponding category information, and the set representations are vector representations corresponding to the hypernyms and entities respectively under the category information.

[0217] In another exemplary embodiment, the category acquisition unit is further used to acquire, based on all entities corresponding to the hypernym, category information corresponding to all entities as the category information corresponding to the hypernym.

[0218] In another exemplary embodiment, the category vectorization unit is further used to perform vector mapping of whether the corresponding category information exists in the set according to the set consisting of the category information corresponding to the hypernyms and entities, on the dimension value matching the number of divided categories, to obtain the set representations corresponding to the hypernyms and entities, respectively.

[0219] In another exemplary embodiment, the prediction module 1370 includes:

[0220] A non-linear encoding unit is used to perform non-linear encoding on each long vector through a hidden layer in the fully connected neural network to obtain a deep semantic vector that represents the information between the hypernym and the entity through a numerical description;

[0221] A summarizing unit, used to summarize the information of all deep semantic vectors, so as to obtain the corresponding hyponym relationship semantic vector for triggering the identification of the hyponym relationship;

[0222] The binary classification unit is used to perform binary classification of the hypernymy relationship according to the hypernymy semantic vector, and output the discrimination result through the fully connected neural network through the binary classification.

[0223] Furthermore, the binary classification unit is further used to perform probability mapping of the relationship correctness scores of the hierarchical relationship semantic vectors through the binary classifier constructed by the output layer in the fully connected neural network, and obtain a discrimination result indicating the probability of the correctness of the hierarchical relationship.

[0224] Optionally, the present invention further provides a computer device, which can be used in the aforementioned implementation environment to execute all or part of the steps of any of the above methods. The computer device includes:

[0225] processor;

[0226] a memory for storing processor-executable instructions;

[0227] The computer readable instructions implement the aforementioned method when executed by the processor.

[0228] The specific manner in which the processor of the device in this embodiment performs operations has been described in detail in the embodiment of the aforementioned method, and will not be elaborated on here.

[0229] In an exemplary embodiment, a storage medium is also provided, which is a computer-readable storage medium, such as a temporary and non-temporary computer-readable storage medium including instructions. The storage medium, for example, includes a memory of instructions, and the instructions can be executed by a processor of the device to perform the above method.

[0230] It should be understood that the present invention is not limited to the exact construction that has been described above and shown in the drawings and that various modifications and changes may be performed without departing from its scope. The scope of the present invention is limited only by the appended claims.

Claims

1. A method for determining the relationship between superior and subordinate. It is characterized in that The method comprises: Get the hypernyms and entities corresponding to the hyponym relationship; For the hypernyms and entities obtained by a hyponymy relationship, the hypernyms and entity words are converted into mathematical descriptions using more than one text information in the text information of multi-source information to obtain vector representations of the hypernyms and entities at corresponding levels, wherein the multi-source information includes encyclopedia texts, labels and category information related to the hypernyms and entities; Between the hypernym and the entity, concatenate the vector representations corresponding to the same information source to obtain a long vector; A deep semantic vector is generated by projecting the long vector on a fully connected neural network. The output of the deep semantic vector on the fully connected neural network corresponds to the discrimination result of the hypernym and hyponym relationship. The fully connected neural network includes an input layer, a hidden layer and an output layer. The hidden layer is used to fully utilize the information between hypernyms and entities in the long vector through nonlinear combination to obtain a hidden layer vector containing the relationship between the two, which is a deep semantic vector.

2. The method according to claim 1, It is characterized in that The obtaining of the hypernyms and entities corresponding to the hyponymy relationship includes: According to the judgment of the hyponymy relationship triggered in the knowledge graph, the corresponding hypernyms and entities are obtained from the hyponymy relationship constructed in the knowledge graph, and the hypernyms and entities are used to judge the hyponymy relationship.

3. The method according to claim 2, It is characterized in that The multi-source information includes encyclopedia texts. The hypernyms and entities obtained for the hyponymy relationship are converted into mathematical descriptions using more than one type of text information in the text information of the multi-source information to obtain vector representations of the hypernyms and entities at the corresponding levels, including: Segmenting the encyclopedia text according to the character segmentation granularity and the word segmentation granularity to obtain the characters and words obtained by segmentation in the encyclopedia text; Representing the characters and words as real-valued vectors respectively according to the encyclopedia text, obtaining character vectors and word vectors, wherein the word vectors are related to the context information of the encyclopedia text; The vector representations of the hypernyms and entities under the encyclopedia text are respectively constructed by the character vectors and word vectors.

4. The method according to claim 3, It is characterized in that The step of representing the characters and words as real-valued vectors according to the encyclopedia text to obtain character vectors and word vectors includes: The words obtained by segmentation are replaced with identifiers according to the corresponding semantic contents, and a mapping between the identifiers and the names indicated by the corresponding semantic contents is constructed, wherein the words exist in the form of identifiers; For the characters and words obtained by segmentation, character vectors and word vectors are trained respectively according to the context information in the encyclopedia text, and the character vectors are mapped to the corresponding characters, and the word vectors are mapped to the identifiers of the corresponding words that are replaced.

5. The method according to claim 4, It is characterized in that The constructing the vector representation of the hypernym and entity under the encyclopedia text respectively by using the character vector and the word vector includes: Obtaining the word vector mapped to the word in the hypernym; According to the order of the characters in the hypernym and the specified expansion multiple, density interpolation of the character vectors mapped by the characters in the hypernym is performed to obtain a vector representation of the hypernym under the encyclopedia text, and the vector representation is the initial word vector of the hypernym.

6. The method according to claim 4, It is characterized in that The multi-source information includes labels, and the hypernyms and entities obtained for a hyponym relationship are converted into mathematical descriptions using more than one type of text information in the text information of the multi-source information. The vector representations corresponding to the hypernyms and entities at the corresponding levels are obtained by converting the obtained multi-source information into corresponding mathematical descriptions, including: Get the word vector corresponding to the entity according to the identifier mapped by the name; A vector representation of the entity in the encyclopedia text is generated according to the word vector and the label of the entity, and the vector representation is an entity vector.

7. The method according to claim 1, It is characterized in that The multi-source information includes category information, and the hypernyms and entities obtained for the hyponymy relationship are converted into mathematical descriptions using more than one type of text information in the text information of the multi-source information to obtain vector representations of the hypernyms and entities at the corresponding levels, including: Obtaining category information corresponding to the hypernym and entity respectively; The set representations corresponding to the hypernyms and entities are generated respectively through the set formed by the corresponding category information, and the set representations are vector representations corresponding to the hypernyms and entities respectively under the category information.

8. The method according to claim 7, It is characterized in that The obtaining of category information corresponding to the hypernym and entity respectively includes: According to all entities corresponding to the hypernym, category information corresponding to all entities is obtained as the category information corresponding to the hypernym.

9. The method according to claim 7, It is characterized in that The set formed by the corresponding category information, respectively generating the set representation corresponding to the hypernym and the entity, includes: According to the sets consisting of the category information corresponding to the hypernyms and entities, a vector mapping is performed on the dimension value matching the number of divided categories to determine whether the corresponding category information exists in the set, so as to obtain the set representations corresponding to the hypernyms and entities respectively.

10. The method according to claim 1, It is characterized in that The generating of a deep semantic vector according to the projection of the long vector on the fully connected neural network, wherein the output of the deep semantic vector on the fully connected neural network corresponds to the discrimination result of the upper and lower relationship, comprises: In the fully connected neural network, each long vector is nonlinearly encoded through a hidden layer to obtain a deep semantic vector that represents the information between the hypernym and the entity through a numerical description; Summarize the information of all deep semantic vectors to obtain the corresponding semantic vectors of the upper and lower relationships for triggering the upper and lower relationships to be judged; The hierarchical relationship is binary-classified according to the hierarchical relationship semantic vector, and the fully connected neural network is used to output the discrimination result through the binary classification.

11. The method according to claim 10, It is characterized in that Performing binary classification of the hypernymy relationship according to the hypernymy semantic vector, and outputting the discrimination result by performing the binary classification on the fully connected neural network, including: The binary classifier constructed in the output layer of the fully connected neural network is used to perform probability mapping of the relationship correctness score on the semantic vector of the hierarchical relationship, so as to obtain a discrimination result indicating the probability of the correctness of the hierarchical relationship.

12. A system for distinguishing superior and subordinate relationships. It is characterized in that The system comprises: An acquisition module is used to acquire the hypernyms and entities corresponding to the hyponymy relationship; A numerical conversion module, for converting the hypernyms and entities obtained by a hyponymy relationship into mathematical descriptions using more than one text information in the text information of multi-source information, and obtaining vector representations corresponding to the hypernyms and entities respectively by converting the obtained multi-source information into corresponding mathematical descriptions, wherein the multi-source information includes encyclopedia texts, labels and category information related to the hypernyms and entities; A concatenation module, used for concatenating vector representations corresponding to the same information source between the hypernym and the entity to obtain a long vector; A prediction module is used to generate a deep semantic vector based on the projection of the long vector on a fully connected neural network. The output of the deep semantic vector on the fully connected neural network corresponds to the discrimination result of the hypernym and hyponym relationship. The fully connected neural network includes an input layer, a hidden layer and an output layer. The hidden layer is used to fully utilize the information between the hypernym and the entity in the long vector through nonlinear combination to obtain a hidden layer vector containing the relationship between the two, which is the deep semantic vector.

13. The system according to claim 12, It is characterized in that The acquisition module is further used to determine the hyponymy relationship triggered in the knowledge graph, and to obtain corresponding hypernyms and entities from the hyponymy relationship constructed in the knowledge graph, and the hypernyms and entities are used to determine the hyponymy relationship.

14. A computer device, It is characterized in that The computer device comprises: Processor; and A memory having computer-readable instructions stored thereon, wherein the computer-readable instructions, when executed by the processor, implement the method according to any one of claims 1 to 11.

Citation Information

Patent Citations

  • Short text semantic similarity distinguishing method and system based on deep learning model Word2Vec

    CN106844346A

  • Natural language semantic analysis system and method based on depth neural network

    CN107015963A

  • Method capable of combining word vector with bootstrap learning for obtaining and organizing domain entity hyponymy

    CN107463607A

  • Neural network natural language inference method combining single word semantic knowledge

    CN107578106A

  • Translation method and device based on neural network

    CN107608973A