With the improvement of people’s health awareness and the development of Internet and medical treatment,people are increasingly inclined to use public medical websites such as 39 health network and xunyiwenyao network to obtain relevant medical information and solve medical problems.Although these websites have a wealth of medical knowledge,they have a wide range of functions and mixed information,which makes it inconvenient to directly obtain information about certain diseases or symptoms.At the same time,the specific information about diseases or symptoms contained in the websites is displayed in large paragraphs of text,which is not very visible and is not very relevant to other medical entities.The online consultation function provided by the website has a low degree of automation and cannot meet the relevant needs of users.Therefore,these websites cannot enable users to intuitively understand relevant medical information,and cannot solve user problems in a timely and rapid manner.The automatic question answering system can automatically give clear answers by analyzing user questions,searching the knowledge base,etc.,and has a high degree of intelligence.The knowledge graph can intuitively display the semantic information between entities,with strong visibility,and support retrieval and reasoning at the same time.Therefore,the development of a medical intelligent question answering system based on knowledge graphs to realize intelligent question answering and knowledge graph display has extremely important theoretical and practical significance for effectively integrating medical resources,visually displaying medical information,solving users’ medical problems in a timely and rapid manner,and meeting related medical needs.This paper mainly designs and implements a medical intelligent question answering system based on knowledge graph.The system includes the following modules.The first module is data collection,processing and fusion.This module uses urllib to crawl the information of 39 health network and xunyiwenyao network,uses regular expressions and lxml to parse the content of the webpage,and then processes and integrates the obtained data.Finally semi-structured medical data in the form of json is obtained.The second module is to construct a knowledge graph.This module designs the conceptual model of the knowledge graph by analyzing medical data,defines the entity types,entity attributes and relationship types of the knowledge graph,and then directly extract the entities,entity attributes and relationships from the semistructured medical data,and use py2neo to import the data into Neo4j to construct a knowledge graph.The third module is intelligent question and answer,which includes entity recognition,question classification,dependency parsing,entity mapping,query knowledge graph,generate response.First the ALBERT-BiLSTM-CRF model is used to identify the entity in the question,the CNN model is used to classify the question category,and the dependency parsing is used to obtain the semantic triples in the question;secondly,the question entity and the entity in the semantic triple are mapped to the knowledge graph entity;then the question is transformed into Cypher sentences to query the knowledge graph and get the corresponding results according to the graph entity,semantic triples and question categories.Finally,according to the result of the query,a response is generated by matching the corresponding response template according to different question categories.The fourth module is the knowledge graph display.This module uses Cytoscape to display the knowledge graph based on the results of the intelligent question and answer module,and realizes more functions such as highlighting neighbor nodes and expanding the next-level nodes.This system uses cardiovascular disease data as an example to realize a medical intelligent question answering system based on knowledge graphs for cardiovascular disease.The system is developed based on the Python language,and adopts the development method of separation of front and back ends.The front end of the system uses technologies such as HTML5,BootStrap,Cytoscape,etc.to realize interfaces for intelligent question answering and knowledge graph display.The back end of the system adopts a relatively portable Flask framework,the database adopts Neo4j,and the comprehensive use of ALBERT-BiLSTM-CRF,CNN,dependency parsing,Cypther query and other technologies to realize medical intelligent question answering and knowledge graph display. |