Method and system for constructing domain multi-modal knowledge graph

By constructing a multimodal knowledge graph on the neo4j database using web crawling technology and the TPLinker framework, the problem of visual data integration and interdisciplinary information integration in the field of paleontology was solved, and efficient and accurate information extraction and knowledge graph updating were achieved.

CN118568271APending Publication Date: 2024-08-30CHINA UNIV OF GEOSCIENCES (WUHAN)

Patent Information

Application Number
CN202410693808.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-31
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

Existing technologies struggle to effectively integrate and process visual data in paleontology, fail to accurately extract and utilize key attribute information from visual data, lack interdisciplinary information integration capabilities, and are not flexible enough in updating knowledge graphs to quickly reflect the latest research findings.

Method used

We use web crawling technology to download literature from academic papers, employ text and graph alignment technology for entity extraction and graph separation, combine the TPLinker framework for relation-entity joint extraction, and construct a multimodal knowledge graph based on the neo4j database.

Benefits of technology

It improves the efficiency and accuracy of information extraction, enables the integration of interdisciplinary information and flexible updating of knowledge graphs, and provides detailed and visualized paleontological knowledge support.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118568271A
    Figure CN118568271A
Patent Text Reader

Abstract

The invention belongs to the technical field of multi-modal knowledge graph construction, and discloses a method and system for constructing a domain multi-modal knowledge graph, and the method comprises the steps: firstly, employing an NER (entity naming recognition) technology as an entity extraction direction in forming a multi-modal paleontological knowledge graph; the knowledge graph class is not widely applied to the field of paleontology, so that a plurality of recognition and extraction corpora applied to paleontology have partial defects. Therefore, one of the innovation points of the method is that an advanced TPLinker model is used for performing entity-relation extraction on paleontological information to form a knowledge graph serving as a semantic library for a downstream task; according to the method, paleontological entity relations related to charts and contents in literatures are integrated, the efficient multi-modal visual knowledge graph is created, and paleontological information positioning of researchers in the aspect is improved to a certain extent. The important effect of constructing the multi-modal knowledge graph is to fully extract text data and visual data in literatures, so that the knowledge graph fully fuses chart information and then the scientificity is enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of constructing multimodal knowledge graphs, and in particular, relates to a method for constructing a domain multimodal knowledge graph. Background Art

[0002] There are some differences between the multimodal knowledge graph we want to create today and the traditional knowledge graph. The traditional knowledge graph mainly focuses on the study of entities and relationships in texts and databases, while the domain multimodal knowledge graph builds entities in multiple modes and multimodal semantic relationships between entities in multiple modes on the basis of the traditional knowledge graph. For example, in the construction of the paleontology knowledge graph in this article, the rock layer relationship in the constructed triple relationship belongs to the paleontology entity in the visual mode.

[0003] Existing technologies face several major technical problems in constructing knowledge graphs, especially in the field of paleontology:

[0004] 1. Challenges of visual data integration

[0005] Traditional knowledge graphs mainly focus on entities and their relationships in texts and databases, and have a weaker ability to process visual data containing rich information (such as pictures and charts in documents). These visual data often contain key attribute information about paleontology (such as geographic coordinates, strata, etc.), which is of great value to the research in the field of paleontology. However, it is difficult for existing technologies to effectively convert such visual data into standardized data for analysis and utilization.

[0006] 2. Difficulties in processing large-scale literature data

[0007] Researchers in the field of paleontology need to extract useful information from a large number of academic papers. The physical information in these papers is widely distributed, and a large amount of space is used to describe the sample collection, data analysis, and application summary of paleontological information, which has caused some interference to users who want to accurately locate paleontological information. Manual screening is inefficient when faced with a large amount of data, and automated processing methods are still insufficient in accuracy and coverage.

[0008] 3. Complexity of multimodal knowledge fusion

[0009] Paleontological research not only needs to process text data, but also needs to integrate data from multiple modalities such as images and tables. There are complex semantic relationships between these different modal data. Existing knowledge graph construction technology has limited ability to represent and integrate multimodal semantic relationships, making it difficult to effectively capture and express these complex semantic relationships.

[0010] 4. The need for cross-disciplinary information integration

[0011] Paleontology is an interdisciplinary science between life science and earth science, and its research results are widely scattered in the literature of different disciplines. Most of the existing academic knowledge graphs rely on data sets in specific fields, lack the ability to integrate interdisciplinary information, and cannot fully reflect the multidisciplinary characteristics and complexity of paleontological research.

[0012] 5. Dynamic update of knowledge graph

[0013] Paleontology research is a field that is constantly evolving, with new research results and data being generated continuously. The existing knowledge graph update mechanism is not flexible enough to quickly and accurately reflect the latest research results and academic trends.

[0014] To solve the above technical problems, it is necessary to develop more advanced technical methods that can effectively integrate multimodal data, improve the efficiency and accuracy of large-scale literature data processing, and at the same time have the ability to integrate interdisciplinary information and a flexible knowledge graph update mechanism. Summary of the invention

[0015] In response to the problems existing in the prior art, the present invention provides a method for constructing a domain multimodal knowledge graph.

[0016] The present invention is implemented as follows: a method for constructing a domain multimodal knowledge graph includes:

[0017] Step 1: Search for literature using the keywords "Cambrian", "fossil", and "trilobite" through the Web of Science paper index database, use the download tool provided by WOS to download the DOI numbers of all the literature in the form of an Excel spreadsheet, and then use crawler technology to combine the URL number with the DOI to crawl several websites such as sci-hub.se and sci-hub.ren;

[0018] Step 2: Data processing is performed on the crawled literature, text and chart are aligned, and two important stripping information methods are extracted by entity extraction and chart separation of the obtained precise paleontological information to form a paleontological data atlas library;

[0019] Step 3: Select the relation-entity joint extraction model TPlinker as the ner-re operation of the text. In terms of pre-training learning, use the manual annotation tool brat in the Linux environment to annotate the sentences stored in one thousand txt documents prepared in advance, and then perform relation-entity extraction on the text to form a set of triples with specific relations.

[0020] Step 4: Create a detailed and realizable knowledge graph based on the neo4j database.

[0021] To this end, the present invention provides a domain multimodal knowledge graph construction system using the TPLinker framework, including the following modules:

[0022] Crawler module: It consists of crawler nodes, control nodes and databases, and is responsible for crawling paleontology-related literature and data on the Internet based on preset keywords;

[0023] Data processing module: responsible for converting PDF documents and aligning text and graphics to achieve entity extraction and graphic information extraction;

[0024] Entity and relationship extraction module: Adopting the TPLinker framework, the information of entities and relationships is integrated through joint learning to achieve efficient joint extraction of entities and relationships;

[0025] Knowledge graph construction module: Based on the neo4j database, it uses the extracted entity and relationship data to build a domain multimodal knowledge graph and supports graphical interface display.

[0026] Furthermore, the crawler module is specifically implemented as follows:

[0027] Control node submodule: responsible for allocating work threads and calling crawler nodes to crawl information based on specific keywords;

[0028] Crawler node submodule: realizes the download of website content and preprocessing of web page text information to ensure accurate acquisition and effective storage of information;

[0029] Database submodule: stores crawled documents and data, provides data support for entity and relationship extraction, and ensures the continuous updating and expansion of the knowledge graph.

[0030] Furthermore, the data processing module is further refined as follows:

[0031] Text processing submodule: convert PDF files into HTML format, extract text data and pre-process it;

[0032] Chart extraction submodule: Identify and separate chart information in documents, extract key data and caption information in charts, and provide auxiliary information for knowledge graph construction.

[0033] Furthermore, the TPLinker framework module further includes:

[0034] Handshake tagging scheme submodule: responsible for converting the joint extraction task into a token pair linking problem and designing link tags to achieve one-step joint extraction of entities and relations;

[0035] Decoding submodule: decodes all entities and their overlapping relationships based on the link matrix obtained by the handshake tagging scheme to avoid inconsistency between training and testing;

[0036] Loss function submodule: processes the loss function of the handshake tag part, optimizes the model training process, and improves the accuracy of entity and relationship extraction.

[0037] In combination with the above technical solutions and the technical problems solved, the advantages and positive effects of the technical solutions to be protected by the present invention are as follows:

[0038] First, the innovation of the present invention is to use NER (named entity recognition technology) as an entity extraction direction in the formation of a multimodal paleontological trilobite knowledge graph. Because multimodal knowledge graphs have not been widely used in the field of paleontology, many recognition and extraction corpora used in paleontology are partially missing. Therefore, one of the innovations of the present invention is to use the more advanced TPLinker model to extract the entity-relationship of paleontological information to form a knowledge graph that serves as a semantic library for downstream tasks; the advantage of the present invention is to collect paleontological entities and relationships related to the content of the charts and contents in the literature, create an efficient multimodal visual knowledge graph, and to a certain extent improve the positioning of researchers in this area for paleontological information. The important role of the present invention in constructing a multimodal knowledge graph is to fully extract the text data and visual data in the literature, so that the knowledge graph can be fully integrated with the chart information to enhance the scientificity. Finally, the construction of the knowledge graph is completed on the basis of the Neo4j database, which allows the construction of a detailed and visual knowledge structure.

[0039] The technical solution of the present invention fills the technical gap in the industry at home and abroad: the multimodal knowledge graph construction method proposed in the present invention fills the technical gap in the field of automatic construction of multimodal knowledge graphs (taking paleontology as an example) using scientific literature at home and abroad.

[0040] Second, in the field of paleontology research, the traditional way of accumulating knowledge mainly relies on the review and organization of literature. However, faced with a large amount of PDF documents, how to efficiently extract and organize valuable paleontological information from them and construct a knowledge graph that is easy to query and understand has always been a challenge faced by researchers. Traditional literature processing methods are often inefficient and it is difficult to ensure the accuracy and completeness of information.

[0041] The present invention proposes a method for constructing a multimodal knowledge graph in a field, especially for the field of paleontology. The method first retrieves and crawls relevant documents through the web of science paper index library, and then uses text and graph alignment technology to perform entity extraction and graph separation on the paleontological information in the document. Then, the relationship-entity joint extraction model TPlinker is selected to perform ner-re operation on the text to form a triple set of specific relationships. Finally, a detailed and realizable knowledge graph is constructed based on the neo4j database. This method not only improves the efficiency of information extraction, but also ensures the accuracy and completeness of the information, providing strong support for paleontological research.

[0042] The technical innovations of the present invention are mainly reflected in the following aspects: First, the efficient retrieval and download of documents are realized through the web of science paper index library and crawler technology, which solves the problem of low efficiency in traditional document search and sorting; second, the accurate extraction and sorting of paleontological information in the documents is realized by using text and chart alignment technology, which improves the accuracy and completeness of the information; third, the relationship-entity joint extraction model TPlinker is used to perform ner-re operations to form a triple set of specific relationships, which provides strong data support for the construction of knowledge graphs; fourth, the knowledge graph built based on the neo4j database has the characteristics of being detailed and verifiable, which is convenient for users to query and understand. These technical innovations not only improve the efficiency of the construction of knowledge graphs in the field of paleontology, but also provide more comprehensive, accurate and easy-to-understand knowledge support for scientific researchers.

[0043] This paper proposes a method for constructing a multimodal knowledge graph in a field, and successfully applies it to the field of paleontology. This method achieves comprehensive integration and visualization of knowledge in the field of paleontology through efficient literature retrieval, accurate information extraction, relationship-entity joint extraction, and database composition based on neo4j. In the future, with the continuous development and improvement of technology, this method is expected to be applied and promoted in more fields, providing scientific researchers with more convenient and efficient knowledge acquisition and organization tools. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 It is a flow chart of a method for constructing a domain multimodal knowledge graph provided by an embodiment of the present invention.

[0045] Figure 2 This is a graph of documents crawled by a crawler provided in an embodiment of the present invention.

[0046] Figure 3 It is a Neo4j property graph model diagram provided by an embodiment of the present invention.

[0047] Figure 4It is a web of science search keyword graph provided by an embodiment of the present invention.

[0048] Figure 5 It is a partial screenshot of the document download excel provided in an embodiment of the present invention.

[0049] Figure 6 It is an HTML front-end label diagram provided by an embodiment of the present invention.

[0050] Figure 7 It is a p tag selected content diagram in an HTML text provided by an embodiment of the present invention.

[0051] Figure 8 It is a screenshot of the annotated dataset document provided by an embodiment of the present invention.

[0052] Fig. 9 This is a screenshot of the marked sentence format in txt provided by an embodiment of the present invention.

[0053] Fig.10 This is a labeled entity attribute graph provided by an embodiment of the present invention.

[0054] Fig.11 This is a diagram of annotation attributes and relationships provided by an embodiment of the present invention.

[0055] Fig.12 It is a TPLinker framework diagram provided by an embodiment of the present invention.

[0056] Fig.13 It is a token pair marking matrix diagram provided by an embodiment of the present invention.

[0057] Fig.14 It is a token pair matrix diagram for deleting the lower triangular area provided by an embodiment of the present invention.

[0058] Fig.15 This is a screenshot illustration of the knowledge graph provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0059] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0060] The following are two specific embodiments of the method for constructing a domain multimodal knowledge graph provided by the present invention:

[0061] Example 1: Constructing a multimodal knowledge graph in the field of paleontology

[0062] 1. Data processing and entity extraction: First, collect paleontology-related PDF documents from scientific literature databases and use automated tools to convert PDF documents into HTML format for subsequent processing. Use natural language processing technology to extract entities from text content, including information such as paleontological species, fossil discovery sites, and ages. At the same time, use chart separation technology to extract chart information in documents, such as fossil structure diagrams and geological time scales.

[0063] 2. Application of crawler technology: Develop a special web crawler to crawl more paleontology-related literature and data from academic websites and databases based on set keywords, such as "paleontology" and "fossil record". Use crawler nodes to download web page content, pre-process text information, and store the acquired data in the database to provide raw materials for subsequent data processing and knowledge graph construction.

[0064] 3. Relation-entity joint extraction: The TPlinker model is used to perform relation-entity joint extraction on the annotated sentences to obtain the relationship between entities in the field of paleontology and form triple data. These triple data describe the relationship between paleontology, such as "belongs to", "lives in", etc.

[0065] 4. Knowledge graph construction: Use the neo4j database to construct a knowledge graph based on the extracted entities and relationships. The nodes in the graph represent entities in the field of paleontology, and the edges represent the relationships between entities. After the construction is completed, the knowledge network in the field of paleontology can be displayed through a graphical interface, providing researchers with intuitive data exploration and analysis tools.

[0066] Example 2: Constructing a multimodal knowledge graph in the field of geology

[0067] 1. Data processing and entity extraction: Collect documents in PDF format from geological journals and papers and convert them into HTML format for easy processing. Use text and chart alignment technology to extract geology-related entities, such as mineral types, stratigraphic information, geological age, etc., and extract data related to these entities from charts.

[0068] 2. Application of crawler technology: Using customized web crawlers, crawl relevant information from professional geological databases and websites based on keywords such as "geology" and "mineralogy". Through the application of crawler technology, the geological data source is continuously expanded to provide a richer data foundation for the construction of the knowledge graph.

[0069] 3. Relationship-entity joint extraction: Use the TPlinker model to process text in the field of geology, extract the relationship between entities, and generate triple data describing geological knowledge. These data help reveal important geological knowledge such as the relationship between minerals and strata and the division of geological ages.

[0070] 4. Knowledge graph construction: Based on the extracted entity and relationship data, a multimodal knowledge graph in the field of geology is constructed using the neo4j database. The graph contains information such as core geological concepts, mineral resources, stratigraphic structures, and various relationships between these entities, providing a powerful knowledge management and query tool for geological research and teaching.

[0071] These two examples show how to build multimodal knowledge graphs for specific disciplines by combining natural language processing, crawler technology, entity and relationship extraction, and graph database technology. These knowledge graphs can provide researchers and scholars with rich information resources and promote knowledge discovery and academic exchanges.

[0072] The following is a detailed explanation of the working principle of the method for constructing a domain multimodal knowledge graph and its related features mentioned in the embodiment of the present invention:

[0073] 1. Method for constructing domain multimodal knowledge graph

[0074] Step 1 and Step 2: Data processing of PDF documents and crawled documents

[0075] Align text with diagrams: The purpose of this step is to ensure that the text description corresponds to the relevant diagram in terms of data. For example, in paleontology literature, the text describes the characteristics of a certain ancient organism, while the diagram shows the morphology of this ancient organism. By aligning the two, it can be ensured that the information of the text and diagram can be correctly matched when extracting entities and relationships.

[0076] Entity extraction: Identify and extract key entities from text and graphs, such as the name, type, and characteristics of ancient organisms.

[0077] Chart separation and information extraction: Separate charts from text and perform information extraction specifically on charts. This involves image recognition technology to extract key data and information from charts.

[0078] Form a paleontological data atlas library: Integrate the extracted entities and relationships into a atlas library to provide a data foundation for subsequent knowledge graph construction.

[0079] Step 3: Relation-Entity Joint Extraction and Data Preparation

[0080] Select the TPlinker model: TPlinker is a relation-entity joint extraction model that can simultaneously identify entities in text and their relations.

[0081] Pre-training and labeling: Use manual labeling tools (such as brat) in the Linux environment to label sentences in one thousand txt documents to train the TPlinker model. These labeled data will be used by the model to learn how to identify and extract entities and relationships.

[0082] Relation-entity extraction: Use the trained TPlinker model to extract relations and entities from texts to form a set of triplets of specific relations. These triplets will serve as the basic units in the knowledge graph.

[0083] Step 4: Build a knowledge graph based on neo4j

[0084] Choose neo4j database: neo4j is a high-performance graph database suitable for storing and querying graph structured data.

[0085] Knowledge graph construction: Import the entities and relationships extracted in the previous step into the neo4j database to construct a detailed and practical knowledge graph. This graph can be used to query, analyze and visualize relevant knowledge of paleontology.

[0086] 2. Composition and functions of crawler technology

[0087] Crawler technology mainly consists of three parts: crawler node, control node and database.

[0088] Control node: responsible for the control logic of the entire crawler, such as allocating work threads to crawler nodes according to URL addresses, and guiding crawler nodes to crawl information according to specific keywords.

[0089] Crawler node: It is the main part of the crawler and is responsible for crawling website content according to the set algorithm. This includes downloading web pages, preprocessing web page text (such as removing advertisements, extracting text, etc.), and storing the obtained results in the database.

[0090] Database: used to store data obtained by crawlers, such as web page content, URL addresses, etc.

[0091] 3. Data processing method: HTML-based text data extraction

[0092] This method is mainly used to extract text and chart data from PDF files.

[0093] Convert PDF to HTML: Use tools such as pdf2html to convert PDF files to HTML format. The converted HTML file retains most of the structure and information of the original PDF file, but the format is more suitable for web browsing.

[0094] Data extraction and alignment: Based on the tag structure of HTML, text data and chart data can be easily extracted. For example, by identifying Tags can extract image data and identify Tags can extract text data. At the same time, because the HTML file retains the layout structure of the original PDF file, the text and chart can be aligned.

[0095] Data integration and storage: Integrate the extracted text and chart data into a data structure (such as a graph library) and store it in the corresponding database for subsequent knowledge graph construction and analysis.

[0096] Through the above methods and techniques, relevant knowledge of paleontology can be effectively extracted from PDF documents and network resources, and a multimodal knowledge graph can be constructed to provide strong data support for the research and application of paleontology.

[0097] like Figure 1 As shown, the present invention provides a method for constructing a domain multimodal knowledge graph, comprising the following steps:

[0098] S101, data processing of PDF documents, alignment of text and graphs, and the formation of a paleontological data atlas library by entity extraction and graph separation of the obtained precise paleontological information;

[0099] Search for literature using the Web of Science paper index using the keywords "Cambrian", "fossil", and "trilobite". Use the built-in download tool of WOS to download the DOI numbers of all the literature in the form of an Excel spreadsheet. Then use crawler technology to combine the URL number with the DOI to crawl several websites such as sci-hub.se and sci-hub.ren.

[0100] S102, then data processing is performed on the crawled literature, text and chart are aligned, and two important stripping information methods are extracted by entity extraction and chart separation of the obtained precise paleontological information to form a paleontological data atlas library;

[0101] S103, selecting the relation-entity joint extraction model TPlinker as the ner-re operation of the text, and in terms of pre-training learning, using the manual annotation tool brat in the Linux environment to annotate the sentences stored in one thousand txt documents prepared in advance, and then performing relation-entity extraction data on the text to form a triple set of specific relations;

[0102] S104, create a detailed and realizable knowledge graph based on the neo4j database.

[0103] The crawler technology provided by the present invention is the whole network crawler crawling process:

[0104] (1) First, the initial URL is obtained by crawling keywords by the user; this initial URL address is usually specified by the user, but it can also be obtained by crawling web pages specified by the user;

[0105] (2) The crawler starts crawling the web page corresponding to the initial URL address, and then stores the web page in the initial resource library. At the same time, the initial web page will also contain the new URL address. Before putting the new URL address into the URL queue, the URL address corresponding to the crawled web page needs to be placed in a URL list specially used for deduplication;

[0106] (3) Put the new URL that has been obtained into the queue of executable crawling URLs, so that after obtaining a new URL address next time, the new URL address will be put into the URL queue;

[0107] (4) Read the next URL from the URL queue, then crawl the web page corresponding to the new URL, and at the same time obtain the new URL from the new web page and repeat the above crawling process;

[0108] (5) Stop crawling.

[0109] The data processing method provided by the present invention:

[0110] Text data extraction based on HTML format

[0111] After converting a PDF file to an HTML file, although the page only changes slightly (the effect of HTML text being viewed on a web page is much weaker), the format of the file will change to a certain extent, and all information will have different tags according to the category; for example, the tag format of image data is , the label format of text data is , and these tags conform to the layout structure of the context in the structure of the article;

[0112] At the same time, many data tags will also retain relevant path and caption information; for example, the img tag stores the local path of the image, that is, the corresponding image data, and the upper and lower p tags of the tag generally include the caption information of the image;

[0113] So based on pdf2html, the pdf files are converted to html files with high fidelity; the converted html format files are placed in the same path of the original pdf files. Since only the file format is changed, each pdf file will be attached to the self-generated html file.

[0114] The image-text alignment method provided by the present invention:

[0115] Select the corresponding tag of the picture in the html file With paragraph This chart search method is based on the stable chart and introduction format of the literature. The previous or next line of the chart must be a comment on the chart content. When traversing the HTML front-end code program, when you find When formatting, it will stop to query the two lines before and after The text content in the tag, and then use the NER module to query to find the entity attributes, and then compare the entity with The image names corresponding to the format are matched to the triple format of the final knowledge graph; the relationship extraction of the image is completely separated from the text extraction, which is the data integration diagram of the second part;

[0116] Therefore, for the alignment of pictures and tables in multimodal text, this solution takes the traversal operation of the HTML web page code, and each time a Tag, a txt text document will be generated in the current folder, and then Enter the image name in the tag, and then use the space command to separate it from the following text information. Then the next Tags are used to extract information; as shown in the figure below, in the literature style, the next line of the chart contains comments on the chart, so the p tag is removed. The next line of the label is the corresponding text information, which is also put into this txt document. Similarly, each document will generate a folder under the same path, and the folder contains txt documents that align the charts and text information.

[0117] The Txt document only contains the chart name and annotation information. Next, the annotation information will be extracted using the ordinary NER to extract key entities. Because there is already a "chart" relationship between the annotation information and the chart, this solution does not include relationship extraction for the extraction of annotation information. The extracted entity information will form an independent triple relationship data set with the chart name; finally, this part of the data set is combined with the text extraction data set to generate a multimodal knowledge graph.

[0118] The TPlinker model provided by the present invention includes: a TPLinker framework, a handshake marking scheme, decoding, and a loss function.

[0119] The TPLinker framework provided by the present invention:

[0120] Extracting entities and relations from unstructured text is a key step in automatically building a knowledge base. However, the traditional pipeline method is to extract entities first, then compare the candidate entities with their relation types and classify them. If entity detection and relation classification are completely separated, the correlation between the two tasks will be ignored, which is prone to cascading errors. Therefore, we choose to use joint learning to effectively integrate the information of entities and relations, so as to achieve better performance in these two subtasks. The second problem that follows is exposure bias, because during training, the ground truth tags are used as context, while during inference, the entire sequence is generated by the generated model itself, so the previous tags generated by the model are provided as context. Therefore, the predicted tags during training and inference come from different distributions, that is, from data distributions that are opposite to the model distribution, which will also affect the model effect to a certain extent.

[0121] In order to deal with this problem, TPLinker proposes a one-stage method for the union of entities and overlapping relations, which can bridge the gap between training and reasoning and convert the joint extraction task into a token pair linking problem. For the entities and specific relations in the sentence, a handshake tagging scheme is designed, and three token connection matrices are annotated between each relationship to answer the above questions.

[0122] The innovation of this paper is first to use NER (named entity recognition technology) as the entity extraction direction in the formation of multimodal paleontology knowledge graph. Because knowledge graphs are not widely used in the field of paleontology, many recognition and extraction corpora used in paleontology are partially missing. Therefore, one of the innovations of this paper is to use the more advanced TPLinker model to extract the entity-relationship of paleontological information to form a knowledge graph that serves as a semantic library for downstream tasks. The multimodal paleontology direction combines the knowledge graph to form an avant-garde research corpus knowledge base in this field. At the same time, it is also a field-type innovation point, which is the direction of the multimodal biological field extending to the paleontology. It includes the characteristics of the surface rock strata where paleontology was discovered, the period of survival, the location of fossil excavation, etc., and constructs a knowledge graph around specific fossil types in a certain period.

[0123] The knowledge graph visualization method provided by the present invention:

[0124] Neo4j graphs are constructed from a large number of nodes and the relationships between them. Users also annotate a large number of entity labels between nodes and relationships. Finally, users can log in to the Neo4j data browser to view the graph.

[0125] (1) Node: The basic unit of Neo4j graph. It contains properties with key-value pairs.

[0126] (2) Relationship: Countless nodes can form an important component of a graph. It refers to the connection between two nodes in the graph. Each relationship also contains a start node and an end node, which means that the connection between graph nodes is a directed connection. Relationships can also contain attributes as key-value pairs.

[0127] (3) Attribute: A key-value pair that specifically describes the relationship between nodes in a graph.

[0128] (4) Label: The purpose of Label is to associate a user-defined label with a set of nodes or relationships. Of course, nodes and relationships can also be labeled with multiple labels.

[0129] (5) Data Browser: Once Neo4j is installed, you can access the Neo4j Data Browser at http: / / localhost:7474 / browser / .

[0130] Pre-training data annotation based on TPLinker:

[0131] Before you want to extract entities from text, you need to pre-train the NER model. This solution will extract 500 paper titles from 2,000 articles in the text as a pre-training set and use the brat tool for manual annotation. Brat is a web-based text annotation tool that adds annotations to text. The text annotation tool will structure the results of manual annotations into a format that can be processed by computers.

[0132] Figure 8 Screenshot of the annotation dataset document; Fig. 9 Screenshot of the annotated sentence format in txt; the last step is to select the annotated attributes and relationships. This solution annotates the five entity attributes of period, fossil_categories, fossil_name, terrane, and address according to the knowledge graph entities and relationships, as well as the relationships between the four entity attributes of fossil_name, discovered_in, fossil_period, and exist_in. Next, you only need to log in to the brat annotation browser and enter the folder for manual annotation. The annotation information first selects between the words in the sentence, then selects the attributes based on the content, and then annotates the relationship between the annotated attributes. The specific process is as shown in the figure below:

[0133] Fig.10 To label the entity attribute graph; Fig.11 To annotate attribute and relationship graphs. This solution requires extracting entities and relations from unstructured text, which has attracted increasing attention, but remains challenging due to the difficulty in identifying overlapping relations with shared entities. Previous studies have shown that joint learning can significantly improve performance. However, they usually involve consecutive related steps and suffer from exposure bias. During training, they use ground truth conditions for prediction, while at inference time, they have to extract from scratch. This difference leads to error accumulation. To alleviate this problem, the present invention uses a single-stage joint extraction model, namely TPLinker, which is able to discover overlapping relations that share one or two entities while not being affected by exposure bias.

[0134] TPLinker method details:

[0135] First, TPLinker converts the joint extraction task into a token pair linking problem. For the entities and specific relations in the sentence, a handshake tagging scheme is designed, and three token connection matrices are annotated between each relation to answer the above questions.

[0136] The second part is to use the link matrix obtained by the decoder from the handshake tagging scheme to decode the different tagging results, from which all entities and their overlapping relations can be extracted.

[0137] Using this approach, TPLinker does not contain any interdependent extraction steps, so it avoids dependence on ground truth conditions during training and achieves consistency in training and testing.

[0138] Fig.12 TPLinker framework; Handshake tagging scheme: First, according to the entity and relation triple (s, r, o), it can be determined by aligning the boundary tags of the subject entity s and the object entity o under the condition of relation r, and a one-step joint extraction is achieved by marking the tag pairs with link labels. That is, given a sentence, enumerate all token pairs and use a matrix to mark the token links. In the matrix, the attributes of the entity are marked with different colors. For example, in the figure below, purple tags are used to indicate that the corresponding two positions are the start and end tags of the entity, respectively. For example, "New York City" and "De Blasio" are two entities in the sentence, so the tag pairs ("New", "City") and ("De", "Blasio") are assigned purple tags. From the subject head to the object head, the red tag indicates that the two positions are the start tags of the paired subject entity and object entity, respectively. For example, there is a "mayor" relationship between "New York City" and "De Blasio", so the tag pair ("New" and "De") is assigned a red tag. The blue markers have similar logic to the red markers, which means the two positions are the end markers of the paired subject entity and object entity respectively.

[0139] However, the matrix formed in this way is very sparse, as can be seen in the figure below, especially in the lower triangular area. The reason for this is that the tail of the entity does not appear before the head of the entity, so the marks in the lower triangular area are all zero, which is also a huge waste of memory. However, the object entity appears before the corresponding main entity, which means that it is unreasonable to delete the lower triangular area directly. Before that, map all the marks 1 in the lower triangular area to the marks 2 in the upper triangular area, and then delete the lower triangular area. After doing this, it is no longer a complete matrix. In actual operation, in order to facilitate tensor calculations, TPLinker concatenates the remaining items into a sequence and uses mapping to remember the positions in the original matrix. The sequence is similar to a handshake of all tokens.

[0140] Fig.13 Token pair labeling matrix; Fig.14 Delete the lower triangular region token pair matrix; Fig.12 In the entire TPLinker framework, ("New York", "New York"), ("New York", "City"), and ("De", "Blasio") are marked as 1 in the EH to ET sequence, which means that "New York", "New York City", and "De Blasio" are three entities. For the relationship "mayor", ("New", "De") is marked as 1 in the SH to OH sequence, which means that the mayor of the subject starting with "New" is the object starting with "De". ("City", "Blasio") is marked as 1 in the ST to OT sequence, which means that the subject and object are entities ending with "City" and "Blasio" respectively. According to the information represented by these three sequences, the triple can be decoded: ("New York City", mayor, "De Blasio"). For each relation, first decode the tuples (subject tail position, object tail position) from the ST to OT sequence and add them to the set E, then decode the (subject head position, object head position) tuples from the SH to OH sequence and look up all entities starting from the head position in the dictionary D. Finally, iterate over all candidate subject-object pairs to check if their tail position is in E. If so, extract a new triple and add it to the result set T.

[0141] Loss Function

[0142]

[0143] This model mainly processes the loss function of the handshake tag part, where N is the length of the input sentence, l is the real tag, and E, H, and T represent the tags from EH to ET, SH to OH, and ST to OT, respectively.

[0144] Table 4.1 Experimental training indicators

[0145] Model Pricise / Recall / F1 Traintime TPlinker 0.76 / 0.40 / 0.53 17.3s

[0146] Because the annotated data set is limited, the indicators obtained after multiple trainings have always been very different, and each experimental result cannot achieve higher precision and recall. However, when facing relationship and entity extraction events, higher precision meets the experimental tasks. Therefore, this scheme here selects a training indicator with higher precision as the experimental standard. The present invention forms a knowledge graph based on the neo4j graph engine database with the obtained data. The experiment of the present invention is implemented on the neo4j graph database platform and in the jdk environment. First of all, neo4j is a Java-based graph database. Running Neo4j requires starting the JVM process, so the JDK of JAVA SE must be installed. Download Java SE JDK from the official website of Oracle. The current version is JDK8.

[0147] Neo4j creates a knowledge graph, and the data set format is strictly arranged according to the attributes of the knowledge graph. The knowledge graph is composed of the relationship between nodes. Nodes are entities in the graph, and the lines in the graph are used to express the relationship between entities. It is precisely because of the clean and concise expression style of the knowledge graph that it stands out in today's Internet environment of rich and colorful information query, and has become a widely used data organization method at all levels of disciplines.

[0148] The Neo4j graph data set is in the format of <"entity", "relationship", "entity">. This information is placed line by line in the local txt file and recognized by the code to form a graph. The knowledge graph is as follows:

[0149] Fig.15 This is a screenshot of the knowledge graph. In the Neo4j composition diagram, all the orange circles are entities, including biological names, pictures, periods of existence, etc., and the lines between entities express the relationship between each entity. The image-text alignment part is a large number of external entity circles with only singular lines, because when aligning the image and text, the picture is only used as a separate "picture" relationship with the biological name, and among the 5,000 entities, pictures account for more than 3,000, because the biological names themselves are interconnected, and the period is fixed in the Cambrian period because the search is fixed, so the number of entities is reduced due to a large number of repetitions. However, due to the independence of the name of the picture itself, each picture is selected in the knowledge graph.

[0150] The main research contents of the present invention are as follows:

[0151] (1) From the origin of life on Earth to the present, there are multiple eras dominated by different life forms. In each era, life multiplied infinitely and there were many species. Therefore, the complete paleontological knowledge map that is to be constructed based on the entire paleontological community is likely to be separated into multiple large and small groups due to the faults between eras. Therefore, the present invention chooses to start from the trilobites that were distributed all over the world during the Cambrian period, and forms an accurate and sufficient knowledge map through a variety of information such as the existence period of trilobites (including the Early Cambrian, Middle Cambrian, and Late Cambrian), species, living locations, fossil layers, etc.

[0152] (2) Most of the existing academic knowledge graphs are based on bibliometric data collection, and typical examples are AceKG, MAG, and AMiner knowledge graphs. This solution adds multiple modal information such as pictures and tables to the traditional knowledge graph. The multimodal knowledge graph not only processes structured data and text data, but also extracts and integrates unstructured, i.e., visual data. This allows users to obtain more comprehensive query results when comprehensively considering text and visual features.

[0153] Of course, the present invention also has shortcomings. First, the image data of the text is obtained because there will be certain data distortion when converting the PDF format to the HTML format. Therefore, this experimental method lacks more accurate chart information extraction. The next line of the picture tag in the HTML format The label does not necessarily contain the name of the ancient organism in the chart, so the inaccurate correspondence of some charts is also a space for further modification and improvement of the multimodal knowledge graph. Secondly, because the knowledge graph is difficult to handle the mismatch between entities caused by the era fault, the ancient biological entities in the constructed knowledge graph will form large and small biological communities according to the attribute of the period, so only the trilobite fossils of the Cambrian period are drawn.

[0154] The innovation of the present invention is first to use NER (named entity recognition technology) as an entity extraction direction in the formation of a multimodal paleontological knowledge graph. Because knowledge graphs are not widely used in the field of paleontology, many recognition and extraction corpora used in paleontology are partially missing. Therefore, one of the innovations of the present invention is to use the more advanced TPLinker model to extract the entity-relationship of paleontological information to form a knowledge graph that serves as a semantic library for downstream tasks; the advantage of the present invention is to collect the paleontological entity relationships related to the graphs and contents in the literature, create an efficient multimodal visual knowledge graph, and to a certain extent improve the positioning of paleontological information by researchers in this field. The important role of the present invention in constructing a multimodal knowledge graph is to fully extract the text data and visual data in the literature, so that the knowledge graph can fully integrate the chart information to enhance the scientificity.

[0155] The above description is only a specific implementation mode of the present invention, but the protection scope of the present invention is not limited thereto. Any modifications, equivalent substitutions and improvements made by any technician familiar with the technical field within the technical scope disclosed by the present invention and within the spirit and principle of the present invention should be covered by the protection scope of the present invention.

Claims

1. A method for constructing a domain multimodal knowledge graph, It is characterized in that The following steps are involved: Step 1: Data processing of PDF documents, alignment of text and charts, and two important stripping information methods are used to extract entities and separate charts from the obtained accurate paleontological information to form a paleontological data atlas library; Step 2: Data processing is performed on the crawled literature, text and chart are aligned, and two important stripping information methods are extracted by entity extraction and chart separation of the obtained precise paleontological information to form a paleontological data atlas library; Step 3: Select the relation-entity joint extraction model TPlinker as the ner-re operation of the text. In terms of pre-training learning, use the manual annotation tool brat in the Linux environment to annotate the sentences stored in one thousand txt documents prepared in advance, and then perform relation-entity extraction on the text to form a set of triples with specific relations. Step 4: Create a detailed and realizable knowledge graph based on the neo4j database.

2. The method for constructing a domain multimodal knowledge graph as claimed in claim 1, It is characterized in that The core of the crawler technology consists of three parts: crawler node, control node and database; Control node: The core control node of web crawler technology. Its functions include allocating working threads according to URL addresses and calling crawler nodes to crawl information based on specific keywords. Crawler node: The web crawler crawls the website according to the set algorithm through this node; its function is the main body of the crawler, mainly including downloading web pages and preprocessing the text information of the web pages. After the entire crawler code is run, the obtained results will be stored in the corresponding database.

3. The method for constructing a domain multimodal knowledge graph as claimed in claim 1, It is characterized in that The crawler technology is the crawling process of the whole network crawler: (1) First, the initial URL is obtained by crawling keywords by the user; this initial URL address is usually specified by the user, but it can also be obtained by crawling web pages specified by the user; (2) The crawler starts crawling the web page corresponding to the initial URL address, and then stores the web page in the initial resource library. At the same time, the initial web page will also contain the new URL address. Before putting the new URL address into the URL queue, the URL address corresponding to the crawled web page needs to be placed in a URL list specially used for deduplication; (3) Put the new URL that has been obtained into the queue of executable crawling URLs, so that after obtaining a new URL address next time, the new URL address will be put into the URL queue; (4) Read the next URL from the URL queue, then crawl the web page corresponding to the new URL, and at the same time obtain the new URL from the new web page and repeat the above crawling process; (5) Stop crawling.

4. The method for constructing a domain multimodal knowledge graph as claimed in claim 1, It is characterized in that The data processing method: Text data extraction based on HTML format After converting a PDF file to an HTML file, although the page will only change slightly (the effect of HTML text being viewed on a web page is much weaker), the format of the file will change to a certain extent, and all information will have different tags according to the category; for example, the tag format of image data is , the label format of text data is , and these tags conform to the layout structure of the context in the structure of the article; At the same time, many data tags will also retain relevant path and caption information; for example, the img tag stores the local path of the image, that is, the corresponding image data, and the upper and lower p tags of the tag generally include the caption information of the image; So based on pdf2html, the pdf files are converted to html files with high fidelity; the converted html format files are placed in the same path of the original pdf files. Since only the file format is changed, each pdf file will be attached to the self-generated html file.

5. The method for constructing a domain multimodal knowledge graph as claimed in claim 1, It is characterized in that The image-text alignment method: Select the corresponding tag of the picture in the html file With paragraph The format of the label is used to find the correspondence between the image and the text; This chart search method is based on the stable chart and introduction format of the literature. The previous or next line of the chart must be a comment on the chart content. So when traversing the HTML front-end code program, when you find When formatting, it will stop to query the two lines before and after The text content in the tag, and then use the NER module to query to find the entity attributes, and then compare the entity with The image names corresponding to the format are matched to the triple format of the final knowledge graph; the relationship extraction of the image is completely separated from the text extraction, which is the data integration diagram of the second part; Therefore, for the alignment of pictures and tables in multimodal text, this solution takes the traversal operation of the HTML web page code, and each time a Tag, a txt text document will be generated in the current folder, and then Enter the image name in the tag, and then use the space command to separate it from the following text information. Then the next Tags are used to extract information; as shown in the figure below, in the literature style, the next line of the chart contains comments on the chart, so the p tag is removed. The next line of the label is the corresponding text information, which is also put into this txt document; and so on, each document will generate a folder under the same path, and the folder contains a txt document with aligned charts and text information.

6. A domain multimodal knowledge graph construction system using the TPLinker framework, It is characterized in that Includes the following modules: Data processing module: responsible for converting PDF documents and aligning text and graphics to achieve entity extraction and graphic information extraction; Crawler module: It consists of crawler nodes, control nodes and databases, and is responsible for crawling paleontology-related literature and data on the Internet based on preset keywords; Entity and relationship extraction module: Adopting the TPLinker framework, the information of entities and relationships is integrated through joint learning to achieve efficient joint extraction of entities and relationships; Knowledge graph construction module: Based on the neo4j database, it uses the extracted entity and relationship data to build a domain multimodal knowledge graph and supports graphical interface display.

7. The system according to claim 1, It is characterized in that The TPLinker framework module further includes: Handshake tagging scheme submodule: responsible for converting the joint extraction task into a token pair linking problem and designing link tags to achieve one-step joint extraction of entities and relations; Decoding submodule: decodes all entities and their overlapping relationships based on the link matrix obtained by the handshake tagging scheme to avoid inconsistency between training and testing; Loss function submodule: processes the loss function of the handshake tag part, optimizes the model training process, and improves the accuracy of entity and relationship extraction.

8. The system according to claim 1, It is characterized in that The data processing module is further refined as follows: Text processing submodule: convert PDF files into HTML format, extract text data and pre-process it; Chart extraction submodule: Identify and separate chart information in documents, extract key data and caption information in charts, and provide auxiliary information for knowledge graph construction.

9. The system according to claim 1, It is characterized in that The crawler module is specifically implemented as follows: Control node submodule: responsible for allocating work threads and calling crawler nodes to crawl information based on specific keywords; Crawler node submodule: realizes the download of website content and preprocessing of web page text information to ensure accurate acquisition and effective storage of information; Database submodule: stores crawled documents and data, provides data support for entity and relationship extraction, and ensures the continuous updating and expansion of the knowledge graph.

Citation Information

Patent Citations

  • Knowledge graph-based human skeleton movement rehabilitation model construction method

    CN114676260A

  • Knowledge graph construction method for intestine-brain axis and knowledge graph system

    CN116226404A

  • Method and system for constructing astronomical multi-mode knowledge graph based on paper PDF (Portable Document Format)

    CN117094394A

  • Science popularization field named entity identification method, equipment and medium

    CN117634493A

  • Entity relation mining method based on biomedical literature

    US20230007965A1

Cited By

  • Method and device for constructing medical condition image-text knowledge base, and medium

    CN119782505A

  • A method, device and medium for constructing a scientific information graphic and text knowledge base

    CN119782505B

  • Method and device for acquiring literature information and automatically constructing literature knowledge graph

    CN120509472A