Named entity recognition is pivotal in constructing knowledge graphs, particularly for extracting information from unstructured text related to coal mine safety accidents. This paper introduces an entity extraction method utilizing lexical information and a large-scale Chinese pre-trained language model. Initially, we compile a dataset from relevant coal mine text data and develop an ontology model of coal mine safety accidents, incorporating 12 conceptual categories based on comprehensive safety assessments. Subsequently, we integrate lexical features using RoBERTa for character embeddings, AC automata for word matching, and GloVe for word embeddings, synthesizing these into fusion vectors through a self-attention mechanism. For NER, the integrated lexical information is leveraged with a BiLSTM-CRF model to capture contextual features and enforce label constraints, achieving an F1-score of 91.63% in entity recognition. The extracted 6564 entities are stored in a Neo4j graph database for foundational querying capabilities. This work advances entity extraction and dataset construction, establishing a basis for developing specialized domain knowledge graphs in coal mine safety.