| Event inference research is a current research direction of great interest in the field of natural language understanding.This research inferred a sequence of event contexts in order to explore possible subsequent events.Unlike most existing approaches that focus on generic task scenarios,this study focuses on event inference tasks involving complex cause-effect and measure-relationship safety classes.The safety incident text involves specific scenarios,especially in terms of text input(incident description)and required outcome(corresponding incident cause analysis and improvement measures).The existing direct event reasoning methods proposed by the industry have been tried and failed to meet the actual scenario requirements because they do not conform to the reasoning content based on the elements of "accident history,accident causes and accident measures".Therefore,this study proposes a textual reasoning and generation method for "accident description,cause analysis and improvement measures" required in safety analysis scenarios.The main research work is as follows:(1)To address the interference problems of redundant information and diversity of accident element descriptions due to long safety accident text sequences,an Inference Feature Enhancement Module(IFEM)is designed to address to some extent the potential impact caused by the interference of redundant information and diversity of element descriptions in long sequence texts.Specifically,the forward and reverse sequence fusion operations at the feature level are used to obtain more effective inference information with a view to improving the model’s ability to learn knowledge related to the security scenario domain.(2)Given that natural language reasoning is a classification task,it is not possible to generate elementalized text with both cause analysis and improvement measures when reasoning about the relationship between two accident texts in a safety scenario.For this reason,a Database Sentence Matching Module(DSM)is designed.By constructing an inference database and incorporating sentence matching algorithms,this module compensates for the shortcomings of natural language inference as a classification task only.At the same time,we unify IFEM module and DSM module into BERT network structure to build Inference Database Matching Module(IDMM)to realize incident inference in safety scenarios.In addition,to make the BERT pre-trained model more adaptable to the security scenario task,we prepared the RNLI(Revise Natural Language Inference)dataset and fine-tuned the model to improve its linguistic logic expression in security scenarios.After several ablation experiments and comparison experiments,the IDMM model proposed in this study achieved 83.73% inference results on the RNLI dataset,and the results of the test text conformed to the semantic logic and relational expressions.This proves the effectiveness of the IDMM network model. |