A coal spontaneous combustion early warning method and system based on knowledge graph reasoning

By using a knowledge graph-based approach, multi-source coal spontaneous combustion data is converted into structured records and a knowledge graph is constructed, solving the problem of fragmented knowledge about coal spontaneous combustion, improving the accuracy of intelligent identification and early warning, and realizing the comprehensiveness and practicality of coal spontaneous combustion risk assessment.

CN123033348APending Publication Date: 2026-11-03XIAN UNIV OF SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611549049.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-08
Publication Date
2026-11-03

AI Technical Summary

Technical Problem

The fragmented and unstructured nature of knowledge about coal spontaneous combustion disasters makes it difficult to effectively support intelligent identification and causal evolution analysis. Existing technologies struggle to unify and utilize multi-source data related to coal spontaneous combustion.

Method used

The method employs knowledge graph-based reasoning, which transforms multi-source raw data into structured records through a data input layer, data processing layer, knowledge extraction layer, graph construction layer, and application layer. It then performs text standardization and semantic encoding to construct a knowledge graph, and combines it with current monitoring data to output risk level correction and response measures.

Benefits of technology

It enables intelligent identification and early warning of coal spontaneous combustion risks, improves the accuracy and comprehensiveness of early warnings, and can better explore the temporal causal relationship and risk propagation patterns, achieving the integration of knowledge structure management and intelligent early warning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123033348A_ABST
    Figure CN123033348A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of coal spontaneous combustion disaster prevention, and discloses a coal spontaneous combustion early warning method and system based on knowledge graph reasoning, which comprises the following steps: obtaining coal spontaneous combustion related multi-source original data, and converting the multi-source original data into key-value pair structured records; generating structured output samples retaining time sequence, stage attributes and risk transmission context information through text standardization; performing semantic coding modeling, identifying entities, constructing effective entity pairs based on distance, type, same sentence and causality constraints, determining semantic relationship types such as time sequence causality and risk propagation, and generating initial knowledge triples; screening, deduplicating, fusing and aligning the initial triples, and constructing a coal spontaneous combustion knowledge graph containing entity nodes and relationship edges; and finally, combining monitoring data and rule identification to determine the initial risk level, correcting the risk level based on the risk-related causality information in the graph, determining the coal spontaneous combustion stage and risk trend and outputting disposal measures.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of coal spontaneous combustion disaster prevention technology, and relates to, but is not limited to, a coal spontaneous combustion early warning method and system based on knowledge graph reasoning. Background Technology

[0002] Spontaneous coal combustion is one of the most common and serious hazards in coal mining, characterized by its high degree of concealment, long incubation period, complex influencing factors, and difficulty in prevention and control. During the low-temperature oxidation process, coal typically undergoes dynamic changes in indicators such as CO, O2, CO2, C2H4, C2H2, temperature, and air leakage intensity, with clear coupling relationships and evolutionary patterns between different stages. While a wealth of knowledge has been accumulated in the prevention and control of spontaneous coal combustion, including accident cases, on-site monitoring records, research papers, technical specifications, and summaries of fire prevention and extinguishing measures, this knowledge is mostly scattered in textual form, lacking a unified organizational method and structured expression, making it difficult to directly use for intelligent analysis and decision support. Summary of the Invention

[0003] In view of this, embodiments of this application provide a coal spontaneous combustion early warning method and system based on knowledge graph reasoning, which at least solves the problem that the fragmented and unstructured knowledge related to coal spontaneous combustion cannot support intelligent identification of coal spontaneous combustion risks and causal evolution analysis.

[0004] The technical solution of this application embodiment is implemented as follows: In a first aspect, embodiments of this application provide a method for early warning of spontaneous combustion of coal based on knowledge graph reasoning, the method comprising: The raw data related to spontaneous combustion of coal is obtained from multiple sources using the data input layer. The raw data is then converted into structured records stored in the form of a key-value dictionary, and at least includes title, body, source and metadata fields. The structured records are processed by a data processing layer to perform text standardization, and a structured output sample is constructed that retains the timing of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the context of risk transmission. The structured output samples are semantically encoded and sequence modeled using a knowledge extraction layer to identify entities in the structured output samples. Valid entity pairs are constructed based on the entities and preset constraints. The semantic relationship type of the valid entity pairs is determined. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship type includes at least temporal causal relationship, risk propagation relationship, and stage evolution relationship. Based on the effective entity pairs and corresponding semantic relationship types, the knowledge extraction layer generates an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information. The initial knowledge triples are subjected to confidence-based filtering, deduplication, and conflict-based optimal fusion using a graph construction layer, followed by entity alignment and relation normalization to obtain normalized knowledge triples. The normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. The system utilizes current monitoring data of the coal spontaneous combustion site obtained at the application layer, and determines an initial risk level based on preset risk identification rules and multi-indicator coupling rules. Based on the causal relationship information of the knowledge graph, the initial risk level is corrected to obtain a target risk level. Based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, the current coal spontaneous combustion stage and risk evolution trend are determined, and corresponding recommended disposal measures are output.

[0005] Secondly, embodiments of this application provide a coal spontaneous combustion early warning system based on knowledge graph reasoning, the system comprising: The data input layer is used to acquire multi-source raw data related to spontaneous combustion of coal and convert the raw data into structured records stored in the form of key-value pairs and containing at least title, body, source and metadata fields; The data processing layer is used to perform text standardization processing on the structured records and construct structured output samples that retain the occurrence sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the risk transmission context information. The knowledge extraction layer is used to perform semantic encoding and sequence modeling on the structured output samples, identify entities in the structured output samples, construct effective entity pairs based on the entities and preset constraints, and determine the semantic relationship type of the effective entity pairs. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship type includes at least temporal causal relationship, risk propagation relationship, and stage evolution relationship. The knowledge extraction layer is also used to generate an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information based on the effective entity pairs and corresponding semantic relationship types. The graph construction layer is used to perform confidence-based filtering, deduplication, and conflict-based optimal fusion on the initial knowledge triples, and to perform entity alignment and relation normalization to obtain normalized knowledge triples; the normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. The application layer is used to acquire current monitoring data of the coal spontaneous combustion site, determine the initial risk level based on preset risk identification rules and multi-indicator coupling rules; based on the causal relationship information of the knowledge graph, the initial risk level is corrected to obtain the target risk level; based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, the current coal spontaneous combustion stage and risk evolution trend are determined, and corresponding recommended disposal measures are output.

[0006] The beneficial effects of the technical solutions provided in this application include at least the following: This application first transforms multi-source raw data into standardized structured records while retaining key contextual information. Then, it extracts entities and relationships through a multi-layer model, filters effective entity pairs based on multiple constraints, and constructs knowledge triples containing multiple types of related information. After cleaning, fusion, and alignment, a knowledge graph is built. Finally, it combines current monitoring data with graph reasoning to complete risk level correction, stage and trend determination, and output disposal measures. This effectively solves the problem of fragmented, unstructured, and difficult-to-use knowledge in the field of coal spontaneous combustion. It fully explores the temporal causal, stage evolution, and risk propagation laws of coal spontaneous combustion, enabling more accurate intelligent identification of coal spontaneous combustion risks, improving the accuracy, comprehensiveness, and practicality of coal spontaneous combustion risk early warning, and realizing the integration of knowledge structured management, intelligent early warning, and decision support. Attached Figure Description

[0007] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort, wherein: Figure 1 A flowchart illustrating a coal spontaneous combustion early warning method based on knowledge graph reasoning, provided as an embodiment of this application; Figure 2 This is a schematic diagram of the processing flow of a data processing layer provided in an embodiment of this application; Figure 3 A schematic diagram of the model architecture and process of a knowledge extraction layer provided in this application embodiment; Figure 4 A schematic diagram illustrating the architecture and process of a BERT-BiLSTM-CRF model in a knowledge extraction layer, provided for embodiments of this application; Figure 5 A detailed schematic diagram of the BERT coding layer in a BERT-BiLSTM-CRF model provided in this application embodiment; Figure 6A schematic diagram illustrating the architecture and process of a relation extraction module in a knowledge extraction layer, provided for an embodiment of this application; Figure 7 This application provides a schematic diagram of the processing flow for a map construction layer. Figure 8 A schematic diagram illustrating the fusion strategy and rule base processing flow of a graph construction layer provided in an embodiment of this application; Figure 9 This application provides a schematic diagram of a knowledge graph structure for a graph construction layer. Figure 10 This application provides a schematic diagram of the functional architecture of an application layer. Figure 11 A diagram illustrating a knowledge graph construction and early warning application mechanism for spontaneous combustion of coal based on BERT-BiLSTM-CRF, provided in this application embodiment; Figure 12 A schematic diagram of the overall process architecture of an intelligent early warning method for spontaneous combustion of coal based on deep semantic self-extraction and knowledge graph reasoning, provided for an embodiment of this application; Figure 13 This is a schematic diagram of the composition structure of a coal spontaneous combustion early warning system based on knowledge graph reasoning, provided as an embodiment of this application. Detailed Implementation

[0008] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. The following embodiments are used to illustrate this application, but are not intended to limit the scope of this application. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0009] In the following description, references are made to “some embodiments,” which describe a subset of all possible embodiments. However, it is understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0010] It should be noted that the terms "first, second, and third" used in the embodiments of this application are merely to distinguish similar objects and do not represent a specific ordering of objects. It is understood that "first, second, and third" can be interchanged in a specific order or sequence where permitted, so that the embodiments of this application described herein can be implemented in an order other than that illustrated or described herein.

[0011] It will be understood by those skilled in the art that, unless otherwise defined, all terms used herein (including technical and scientific terms) have the same meaning as commonly understood by one of ordinary skill in the art to which the embodiments of this application pertain. It should also be understood that terms such as those defined in general dictionaries should be understood to have a meaning consistent with their meaning in the context of the prior art, and should not be interpreted in an idealized or overly formal sense unless specifically defined as herein.

[0012] This application provides a method and system for early warning of spontaneous combustion of coal based on knowledge graph reasoning, applicable to electronic devices. These electronic devices include, but are not limited to, mobile phones, laptops, tablets, handheld internet devices, multimedia devices, streaming media devices, mobile internet devices, wearable devices, or other types of electronic devices. The functions implemented by this method can be achieved by a processor in the electronic device calling program code. The program code can be stored in a computer storage medium; therefore, the electronic device includes at least a processor and a storage medium. The processor can be used to perform the coal spontaneous combustion early warning processing based on knowledge graph reasoning, and the storage medium can be used to store the data required and generated during the coal spontaneous combustion early warning process based on knowledge graph reasoning.

[0013] Figure 1 This application provides a schematic diagram of a coal spontaneous combustion early warning method based on knowledge graph reasoning. The method is applied to a coal spontaneous combustion early warning system based on knowledge graph reasoning. The system includes an L1 data input layer, an L2 data processing layer, an L3 knowledge extraction layer, an L4 graph construction layer, and an L5 application layer. Figure 1 As shown, the method includes at least the following steps: Step S110: Use the data input layer to obtain multi-source raw data related to spontaneous combustion of coal, and convert the raw data into a structured record stored in the form of a key-value dictionary and containing at least title, body, source and metadata fields; The aforementioned multi-source raw data related to coal spontaneous combustion refers to data directly collected from different channels around the coal mine spontaneous combustion business scenario, including coal spontaneous combustion accident cases, standards and specifications, academic papers, and historical monitoring data. The coal spontaneous combustion accident cases provide factual information such as the location of coal spontaneous combustion, evolution process, abnormal signs, changes in monitoring indicators, prevention and control measures, and handling results. The standards and specifications provide terminology definitions, indicator thresholds, and rule basis for coal mine fire prevention and extinguishing, monitoring and early warning, and safety management. The academic papers provide theoretical knowledge such as coal spontaneous combustion mechanism, indicator gas evolution law, prevention and control technology and its application effect. The historical monitoring data are dynamic sensing data such as temperature, gas concentration, and wind speed collected in the coal mine at historical moments, which can reflect the underground environmental status and potential risk characteristics of coal spontaneous combustion in real time.

[0014] Because the aforementioned data sources differ significantly in format, structure, field naming, and expression, this application establishes a unified intermediate data structure module at the data input layer. This module converts data from different sources into a standardized record format, ensuring a consistent data interface and unified data organization before entering subsequent processing stages. The system converts the raw data into a list of multiple structured records. Each structured record stores its title, body, source, and metadata fields in a key-value dictionary format. The system uniformly organizes the input data into a list of structured records, which can be represented as follows: ,in, Represents a structured collection of records. This represents the nth structured record. Each structured record is represented in key-value pair format, i.e.: ,in, This represents the i-th structured record. For the first in the structured record The field names of each field. Retrieve values ​​for the corresponding fields. For any original input sample (i.e., the original data). The system maps it to structured records using a unified structure transformation function f: This enables the conversion and organization of multi-source heterogeneous text data into a unified intermediate data structure (i.e., structured records).

[0015] Step S120: The structured record is processed by the data processing layer to perform text standardization processing to construct a structured output sample that retains the occurrence sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the risk transmission context information. Among them, the sequence of coal spontaneous combustion events refers to the chronological relationship of the development of coal spontaneous combustion events, such as "air leakage occurs → indicator gas rises → spontaneous combustion hazard forms". The coal spontaneous combustion stage attributes are used to mark the development stage of coal spontaneous combustion, such as the normal state stage, oxidation and heating stage, critical stage, spontaneous combustion stage and other stage characteristics. The risk transmission context information is used to retain the semantic relationship between the preceding and following events, and to record how the risk is transmitted from one indicator to another, that is, the context of risk evolution and causal relationship.

[0016] The data processing layer cleanses, normalizes, and structures the structured records to improve the recognition accuracy and semantic consistency of the subsequent knowledge extraction layer. It ultimately constructs a structured output sample containing text content, tag location information, source information, and contextual information, which serves as the direct input to the knowledge extraction layer.

[0017] Step S130: The structured output sample is semantically encoded and sequence modeled using the knowledge extraction layer to identify entities in the structured output sample. Valid entity pairs are constructed based on the entities and preset constraints. The semantic relationship type of the valid entity pairs is determined. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship types include at least temporal causal relationships, risk propagation relationships, and stage evolution relationships. The preset constraints are used in the entity pair screening stage, in the construction and filtering process of candidate entity pairs, and in eliminating invalid entity combinations to improve the accuracy of entity pair generation in the knowledge extraction stage.

[0018] The knowledge extraction layer is the core algorithm layer of the system, used to automatically identify entities and their semantic relationship types from the normalized structured output samples, realizing the transformation into structured knowledge. The knowledge extraction layer is built based on a deep learning model and can combine a bidirectional pre-trained language model (Bidirectional Encoder Representations from Transformers, BERT), a bidirectional long short-term memory network (BiLSTM), and a conditional random field (CRF). The BERT-BiLSTM-CRF framework is used to complete the named entity recognition task. The semantic representation ability, sequence dependency modeling ability, and global label constraint ability are enhanced by cascading multiple models. On this basis, a relation extraction model is further built to determine the semantic relationship type between entities.

[0019] After entity recognition is completed, the extracted entities are traversed, and condition verification is performed one by one based on each preset constraint. Entities that satisfy the preset constraints are paired up to obtain valid entity pairs with actual semantics and domain logic. The distance constraint is used to limit the character / word interval range between two entities in the structured output sample, filtering entity combinations that are too far apart or have no actual relationship, and reducing the number of invalid entity pairs. The entity type constraint is used to filter according to the predefined entity categories, allowing only entities of the specified type to form entity pairs, and excluding entity combinations that do not match types or cannot form a valid semantic relationship. The same sentence constraint requires that the two entities constituting the entity pair appear in the same sentence, and entity combinations across sentences are not accepted to ensure the validity of semantic association. The causal relationship constraint is used to pre-screen the potential causal logic between entities by combining prior knowledge of the coal spontaneous combustion domain, and eliminate entity combinations that violate domain common sense and have no causal relationship.

[0020] The temporal causal relationship can be represented as "cause_of", which is used to characterize the temporal sequence and logical causal relationship between entities, describing the temporal evolution logic between coal spontaneous combustion phenomena, indicators, and events; the risk propagation relationship can be represented as "propagate_to", which is used to characterize the relationship of risk factors being transmitted and diffused from one entity to another, reflecting the transmission process of coal spontaneous combustion hazards and abnormal states; the stage evolution relationship can be represented as "evolve_to", which is used to characterize the step-by-step transition and sequential advancement relationship between entities corresponding to different spontaneous combustion stages, reflecting the stage evolution law of coal spontaneous combustion gradually developing from a normal state to a spontaneous combustion state.

[0021] The specific sub-types and definitions of the semantic relation types are shown in Table 1 below: Table 1. Semantic Relation Types

[0022] This application uses the semantic relationship types shown in Table 1 to unify and associate monitoring indicators, evolutionary states, risk stages, and prevention and control measures in the field of coal spontaneous combustion, thereby realizing the transformation from static knowledge association to dynamic risk evolution reasoning, and thus improving the accuracy and interpretability of coal spontaneous combustion risk identification and early warning analysis.

[0023] Step S140: Using the knowledge extraction layer, an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information is generated based on the effective entity pairs and corresponding semantic relationship types. Based on valid entity pairs and corresponding semantic relationship types, a structured knowledge representation (i.e., initial knowledge triples) is finally output. These initial knowledge triples include a head entity, a tail entity, and the semantic relationship type between the head and tail entities. The temporal causal information is used to characterize the logical relationships of causal association between various monitoring indicators and abnormal states; the coal spontaneous combustion stage evolution information records the stage divisions, state transitions, and evolutionary patterns of the entire process from initial oxidation to explosion; and the risk propagation information reflects the diffusion path and transmission relationship of risk across spatial regions and different monitoring points.

[0024] Step S150: The initial knowledge triples are subjected to confidence-based filtering, deduplication, and conflict-based optimal fusion processing using the graph construction layer, and entity alignment and relation normalization processing are performed to obtain normalized knowledge triples; the normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. The graph construction layer is used to unify, standardize, and structure the entity and semantic relationship types output by the knowledge extraction layer, constructing a knowledge graph for coal spontaneous combustion monitoring and early warning, and realizing the transformation from a "set of relational results" to a "graph-structured knowledge system". This layer is oriented towards the organization, optimization, and storage of structured knowledge, and its core tasks include: triple fusion, entity alignment, relation normalization, graph structure modeling, graph database construction, and application interface implementation. In the knowledge fusion process, this application introduces classification constraint rules for the coal spontaneous combustion evolution stages. These rules are used by the knowledge graph construction layer to classify and merge the initial knowledge triples output by the knowledge extraction layer into structured constraints. The classification constraint rules include: classifying the coal spontaneous combustion evolution stages corresponding to the initial knowledge triples based on entity attribute information, relation type information, and stage feature keyword information within the knowledge triples; specifically, when the entity attributes, relation types, or associated semantics in the knowledge triples contain features of the oxidation-heating stage such as temperature rise and abnormal increase in indicator gas concentration, the corresponding knowledge triple is classified as belonging to the oxidation-heating stage; when the entity attributes, relation types, or associated semantics in the knowledge triples contain features of the critical stage such as critical temperature, continuous oxidation, and increased risk, the corresponding knowledge triple is classified as belonging to the critical stage; and when the entity attributes, relation types, or associated semantics in the knowledge triples contain features of the spontaneous combustion stage such as obvious spontaneous combustion signs, combustion risk, and disaster state, the corresponding knowledge triple is classified as belonging to the spontaneous combustion stage. By using the above-mentioned stage classification rules, knowledge triples corresponding to different coal spontaneous combustion evolution stages are linked in the knowledge graph with stage labels, providing a data foundation for subsequent stage association path analysis.

[0025] In the knowledge triple integration and confidence screening stage, based on the effective entity pairs and corresponding semantic relation types output by the knowledge extraction layer, an initial set of knowledge triples as shown in formula (1) can be obtained. : Formula (1); in, Represents the initial set of knowledge triples; Represents the i-th entity; Represents the j-th entity. It is a physical entity and entity The semantic relationship types between them This represents the relation confidence level corresponding to the initial knowledge triples. To ensure the reliability of the knowledge graph, a threshold filtering mechanism can be introduced to construct the set of effective triples after confidence filtering, as shown in formula (2). : Formula (2); in, This represents the set of valid triples after filtering by the confidence threshold. As a confidence threshold, only retain those with a confidence level of not less than [a certain threshold]. The triplet is used to remove low-confidence erroneous noise relationships, thereby improving the accuracy and reliability of the spectrum.

[0026] When knowledge originates from multiple texts or multiple models, as shown in formula (3), the same triples are fused, and their fusion confidence is calculated: Formula (3); in, It is a triple after multi-source fusion The overall confidence level (i.e., fusion confidence level). For triples The number of knowledge sources, including different text sources or different model outputs; It is the triplet in the kth knowledge source The original confidence level. Through multi-source fusion, cross-document consistency of knowledge can be enhanced, and the stability of key relationships can be improved.

[0027] After multi-source fusion, the triple set is deduplicated and conflict-resolved to form the final high-quality triple set. : The deduplication process retains only a unique instance of identical triples, eliminating data redundancy. In the conflict resolution process, when a unified entity pair corresponds to multiple different relation types, the relation type with higher fusion confidence or higher multi-source support is retained first to resolve relation conflicts.

[0028] In the entity alignment and normalization stage, to address the issues of numerous synonymous expressions, descriptions at different granularities, and semantic redundancy, entities are uniformly standardized and a normalized entity mapping function is constructed. This function can map different expressions of the same concept to a unique standard entity; for example, "CO", "carbon monoxide", and "carbon monoxide concentration" are all mapped to the same standard entity. This stage employs a multi-strategy fusion approach to entity alignment and normalization, including domain dictionary matching, thesaurus mapping, and rule merging (regular expression / rule base matching). Through multi-strategy collaboration, a standardized and unified entity representation is achieved, eliminating semantic redundancy and improving the consistency of entities in the knowledge graph and the reliability of subsequent reasoning.

[0029] In the relation normalization and mapping stage, to avoid inconsistencies in relation expression across different texts or models, the semantic relation types are standardized, and a relation normalization mapping function as shown in formula (4) is constructed: Formula (4); in, Represents a relational normalization mapping function; This is the original semantic relation type. This is a standardized relation type. A unified relation set for the field of spontaneous combustion of coal can be constructed: The set `act_on, affect}` defines all legal standard relation types in this application, and the relation normalization mapping function. The output results all belong to the set This relational system fully covers the entire semantic chain of "spatial location - state evolution - indicator response - prevention and control measures - mechanism of action" in the spontaneous combustion process of coal, ensuring that relational expressions from different sources can be mapped to a unified and unambiguous standard type.

[0030] In the graph structure modeling phase, the normalized set of triples is... Mapped to the graph structure of a knowledge graph ,in, , Based on entity nodes and relation edges, a coal spontaneous combustion evolution network is constructed. The graph fully carries the stage association paths of each stage of coal spontaneous combustion, the risk propagation paths corresponding to the risk transmission logic, and the causal relationship association paths behind the disaster evolution. Each node of the knowledge graph contains entity name, entity type, and attribute information; relation edges contain relation type and source information.

[0031] In the construction and storage phase of graph databases (such as Neo4j), graph databases (Neo4j) are used to store and manage knowledge graphs. The graph construction layer realizes the key transformation from structured relational results to graph structure knowledge system, providing high-quality data support for subsequent knowledge reasoning and intelligent early warning of coal spontaneous combustion. It is the core intermediate layer connecting knowledge extraction and decision-making applications.

[0032] Step S160: Obtain current monitoring data of the coal spontaneous combustion site using the application layer; determine the initial risk level based on preset risk identification rules and multi-indicator coupling rules; correct the initial risk level based on the causal relationship information of the knowledge graph to obtain the target risk level; determine the current coal spontaneous combustion stage and risk evolution trend based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, and output the corresponding recommended disposal measures.

[0033] At the application layer, a risk warning module enables dynamic identification, correction, and early warning of coal spontaneous combustion risks. This module, based on relationship chains in a knowledge graph and current monitoring data, constructs a coal spontaneous combustion risk identification and early warning mechanism, and is the core module for realizing the system's practical application value. Let the current monitoring data set be... for: ,in, Indicates carbon monoxide concentration. Indicates oxygen concentration. Indicates temperature.

[0034] The preset risk identification rules are pre-configured basic judgment logics that set thresholds and change judgment conditions for single monitoring indicators such as carbon monoxide, oxygen, and temperature to achieve preliminary screening of abnormal states. The multi-indicator coupling rules are based on the inherent correlation between various monitoring indicators and combine the coupling characteristics of synchronous changes and mutual inversion of multiple indicators for comprehensive judgment, avoiding the problem of misjudgment by a single indicator and further ensuring the reliability of the initial risk level judgment results.

[0035] Risk identification functions can be constructed based on preset risk identification rules and multi-indicator coupling rules: , This indicates the initial risk level. In practical applications, it can be expressed in rule form as follows: ,in, This indicates an increase in carbon monoxide concentration. This indicates a decrease in oxygen concentration. This indicates an increase in monitored temperature. When all of the above conditions are met simultaneously, the initial risk level is determined to be high risk.

[0036] At the same time, combining the causal relationship paths in the knowledge graph "To achieve a comprehensive assessment of the risk status and obtain the target risk level, the causal relationship path indicates: an increase in carbon monoxide concentration ( )instruct( The coal body is in an abnormal state, and this abnormal state is the cause of ( The direct cause of coal spontaneous combustion risk can be identified through causal relationship reasoning, which can correct the initial risk level obtained by rule judgment and achieve a more comprehensive and reliable risk assessment.

[0037] The described stage-related path comprehensively depicts the entire progressive process of coal spontaneous combustion, from slow oxidation, accelerated oxidation, and critical state to spontaneous combustion. It also associates the characteristics of monitoring indicators such as gases and temperatures corresponding to each stage. Based on the target risk level, the system matches the current monitoring data with the characteristic conditions of each stage in the stage-related path, thereby accurately determining the current stage of coal spontaneous combustion.

[0038] The risk propagation path is used to characterize the spatial diffusion path and temporal evolution of coal spontaneous combustion risk. By combining the determined coal spontaneous combustion stage with the temporal change characteristics of current monitoring data, the risk propagation range, propagation direction and subsequent development trend can be analyzed based on the risk propagation path, so as to achieve dynamic prediction of risk evolution trend.

[0039] This application pre-binds standardized disposal plans to each stage node of the knowledge graph, forming a corresponding relationship between the coal spontaneous combustion stage, risk evolution trend and disposal measures. After clarifying the current coal spontaneous combustion stage and risk evolution trend, the system automatically matches and retrieves suitable disposal plans and outputs recommended disposal measures, thereby completing the complete business process from risk assessment and trend analysis to decision guidance.

[0040] This risk warning module can integrate multi-indicator information and use semantic relationships in a knowledge graph for reasoning to achieve multi-dimensional identification and dynamic early warning of coal spontaneous combustion risk. This application not only identifies risks based on single indicators, but also performs staged dynamic reasoning based on multi-indicator coupling relationships and temporal causal paths.

[0041] In the above embodiments, multi-source raw data is first transformed into standardized structured records while retaining key contextual information. Then, entities and relationships are extracted through a multi-layer model. Valid entity pairs are screened by combining multiple constraints, and knowledge triples containing multiple types of related information are constructed. After cleaning, fusion, and alignment, a knowledge graph is built. Finally, risk level correction, stage and trend determination are completed by combining current monitoring data and graph reasoning, and disposal measures are output. This effectively solves the problem of fragmented, unstructured, and difficult-to-use knowledge in the field of coal spontaneous combustion. It fully explores the temporal causal, stage evolution, and risk propagation laws of coal spontaneous combustion, improves the accuracy, comprehensiveness, and practicality of coal spontaneous combustion risk early warning, and realizes the integration of knowledge structured management, intelligent early warning, and auxiliary decision-making.

[0042] The knowledge triples output by this application not only include the static relationships between traditional entities, but also focus on expressing the temporal relationships, risk propagation relationships, and stage evolution relationships in the dynamic evolution of coal spontaneous combustion, thus achieving a structured expression of coal spontaneous combustion mechanism knowledge. Unlike traditional knowledge graphs that only establish static connections of "entity-relationship-entity," this application focuses on constructing dynamic semantic relationships between "indicators-states-processes-risks-measures" in the coal spontaneous combustion process. Through the above structured knowledge representation, the system can further construct the dynamic evolution chain of coal spontaneous combustion and realize multi-hop propagation reasoning between risk states. By mapping the temporal causal relationships in the coal spontaneous combustion evolution process to structured knowledge triples, this application realizes the transformation of coal spontaneous combustion mechanism knowledge from unstructured text to a dynamic semantic graph, providing basic support for subsequent knowledge fusion, risk propagation analysis, and dynamic early warning reasoning.

[0043] In some embodiments, step S120, "using the data processing layer to perform text standardization processing on the structured records to construct a structured output sample that retains the occurrence sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the risk transmission context information," includes: The data processing layer sequentially performs data cleaning and format standardization, key domain terminology mapping standardization, professional terminology normalization, text structuring processing, and traceable sample construction processing on the structured records to generate structured output samples that retain the time sequence of coal spontaneous combustion events, coal spontaneous combustion stage attributes, and risk transmission context information.

[0044] The data processing layer cleans, standardizes, and structures the raw data input from the data input layer to improve the recognition accuracy and semantic consistency of coal spontaneous combustion-related data in the subsequent knowledge extraction layer. This layer first cleans up garbled characters, invalid symbols, duplicate content, abnormal line breaks, and redundant fields in the structured records, and standardizes Chinese and English punctuation, number formats, and encoding formats, while simultaneously performing data quality verification. Then, it standardizes key entity fields in the structured records, mapping different expressions of the same entity to unified standard names. For example, expressions such as "CO," "carbon monoxide," and "carbon monoxide concentration" are merged into the same entity, and location expressions such as "upper corner," "upper corner of the working face," and "upper corner of the return air" are standardized. Based on this, the system further integrates a thesaurus, synonym list, and rule base for coal spontaneous combustion terminology to normalize professional terms such as accident types, monitoring indicators, risk status, prevention and control measures, and equipment names. It also performs sentence segmentation, paragraphing, long text slicing, and standard serialization of the text in the structured records to meet the input requirements of deep learning models. To ensure the traceability of knowledge extraction results in the subsequent graph construction process, this application also generates a unique identifier code for each case, document or text record, and finally constructs a structured output sample containing text content, tag location information, source information and contextual association information, which serves as the direct input to the knowledge extraction layer.

[0045] Figure 2 This is a schematic diagram of the processing flow of a data processing layer provided in an embodiment of this application. This layer cleans, standardizes, and structures multi-source heterogeneous data to eliminate data noise, unify semantic definitions, and improve the recognition accuracy and semantic consistency of subsequent knowledge extraction. The processing flow is as follows: Data cleaning and standardization: First, the list data structure (i.e., structured record) composed of multiple dictionary records is cleaned, formatted, and quality checked. Formatting includes unifying Chinese and English punctuation, number formats, and encoding formats to ensure data consistency and standardization, and to remove invalid and noisy data.

[0046] Entity normalization: After the data has been cleaned and standardized, entity identification, synonym representation normalization and standardized mapping are performed to achieve entity disambiguation and standardization. Different expressions of the same entity are mapped to a unified standard form, eliminating the problems of synonyms and homonyms.

[0047] Terminology normalization: Based on domain knowledge resources, the standardized data of the execution entities undergo terminology normalization, including the standardization of professional terms such as accident types, monitoring indicators, risk status, prevention and control measures, and equipment names, to establish a unified terminology system and ensure the consistency of domain semantic expression.

[0048] Text structuring: The text, after being normalized by technical terms, is processed by sentence segmentation, paragraphing, and long text slicing, and then converted into a JSON standard serialization representation, transforming unstructured text into structured sequence data suitable for model input.

[0049] Structured output sample construction: A unique identifier is assigned to the data after the text has been structured, and a structured output sample containing text content, label location information, source information and contextual information is constructed. Finally, the output is sent to the L3 knowledge extraction layer to provide standardized corpus for the semantic encoding and knowledge extraction of subsequent models.

[0050] Through the above process, unified cleaning, standardization, and structuring of multi-source heterogeneous data were achieved, effectively improving the accuracy and consistency of subsequent knowledge extraction and providing a high-quality data foundation for the construction of a coal spontaneous combustion knowledge graph.

[0051] In the above embodiments, multiple processes such as data cleaning, format standardization, vocabulary mapping, and terminology normalization are carried out sequentially during the text standardization process. This can comprehensively purify the original structured data, unify the domain expression form, and completely retain information related to the coal spontaneous combustion sequence, stage attributes, and risk transmission. This further ensures the data quality of subsequent knowledge extraction work and avoids knowledge extraction deviations caused by messy data formats and inconsistent terminology, laying a reliable data foundation for subsequent entity recognition and relationship mining.

[0052] In some embodiments, the knowledge extraction layer includes a BERT module, a BiLSTM module, and a CRF module. Step S130, "using the knowledge extraction layer to perform semantic encoding and sequence modeling on the structured output sample to identify entities in the structured output sample," includes: Step S1301: The BERT module is used to sequentially perform multi-dimensional embedding encoding, vector fusion, Transformer self-attention feature encoding and feature edge transformation on the structured output sample to obtain the context semantic vector sequence corresponding to the structured output sample. Step S1301 can be achieved through the following steps: Step S13011: The BERT module is used to convert the structured output sample into word embedding vector, position embedding vector and segment embedding vector, and the word embedding vector, position embedding vector and segment embedding vector are fused to obtain a fused embedding vector sequence. The BERT module is used to perform contextual semantic modeling on the structured output samples, mapping the discrete word sequences in the structured output samples into vector representations with deep semantic information, thereby providing high-quality semantic features for subsequent entity recognition and relation extraction. Let the structured output samples be: t represents the number of feature dimensions of the sample. The structured output sample represents the first... Each feature / token.

[0053] First, a fused embedding vector sequence is constructed through the embedding layer of the BERT module: ,in, Represents the i-th word element The fused embedding vector is composed of the fused embedding vectors of all words, forming a complete sequence of fused embedding vectors. It is the i-th word element The word embedding vector is used to represent the semantics of the word itself; It is the i-th word element Position encoding (i.e., position embedding vector) is used to introduce the i-th word. Location information; It is the i-th word element The sentence segmentation encoding (i.e., segmentation embedding vector) is used to distinguish different sentence segments.

[0054] Step S13012: Using the multi-layer Transformer encoder of the BERT module, based on the self-attention mechanism, calculate the relevance weight between any two words in the fused embedding vector sequence, and perform feature extraction and updating layer by layer based on the relevance weight to obtain the intermediate feature vector sequence output by the last layer encoder and encoded by multiple layers. Subsequently, context modeling is performed using the multi-layer Transformer encoder of the BERT module, with self-attention mechanism at its core. Where Q, K, and V are the query matrix, key matrix, and value matrix obtained by linear transformation of the fused embedding vector sequence, respectively. The key matrix is ​​formed by stacking the key vectors corresponding to each word in the fused embedding vector in sequence. The dimension of the key vector serves as a scaling factor used to scale the similarity score. This indicates the transpose operation. The original similarity score matrix between words is normalized by the softmax function to obtain the relevance weights between two words. Finally, the weighted summation of the summation matrix V yields a single word feature vector that incorporates global contextual information. By combining the word feature vectors corresponding to all words in their original order, the feature sequence after a single round of encoding is obtained. The Transformer encoder extracts and updates features layer by layer based on the self-attention mechanism. Finally, the intermediate feature vector sequence output by the last encoder layer after multiple layers of encoding is obtained. This mechanism models the global contextual dependency by calculating the relevance weights between words, which can effectively capture long-distance semantic information and complex logical relationships.

[0055] Step S13013: Standardize the intermediate feature vector sequence to obtain a context semantic vector sequence composed of vectors corresponding to each position in the fused embedding vector sequence.

[0056] Standardization can normalize the mean and variance of the feature vectors corresponding to individual words, eliminating differences in feature distribution and accelerating model convergence. After multi-layer Transformer encoding and standardization, the context semantic representation (i.e., the sequence of context semantic vectors) is obtained: ,in, The intermediate feature vector sequence, The context semantic vector sequence, For the first The context semantic vector corresponding to each lexical position. The number of lexical units in the context semantic vector sequence. Let be the set of real numbers, and d be the vector dimension of the context semantic vector corresponding to each word. This sequence of context semantic vectors can effectively capture the semantics of technical terms, long-distance dependencies, causal relationships, and stage evolution relationships in the text of spontaneous combustion of coal, and can accurately characterize the deep information of the text, providing high-quality semantic input for subsequent sequence feature modeling.

[0057] In summary, the BERT module can provide a high-quality contextual feature foundation for subsequent sequence modeling and label prediction.

[0058] By splitting word embeddings, position embeddings, and segment embeddings and fusing them, a basic embedding vector is obtained. Deep feature iteration and update are completed by relying on a multi-layer Transformer self-attention mechanism. Finally, the feature sequence is standardized to comprehensively capture text word semantics, positional information and long-distance dependencies, unify feature data distribution, further enhance the ability to express contextual semantics, output higher quality semantic vector sequences, and improve the effect of subsequent feature extraction and entity recognition.

[0059] Step S1302: The BiLSTM module is used to extract the forward feature vector sequence and the backward feature vector sequence of the context semantic vector sequence respectively. The forward feature vector sequence and the backward feature vector sequence are concatenated according to the time step dimension to obtain the bidirectional feature vector sequence. After obtaining the context semantic vector sequence output by the BERT module, a bidirectional long short-term memory network (BiLSTM) is introduced to further model the context semantic vector sequence in order to enhance the ability to identify temporal dependencies and entity boundaries.

[0060] For the aforementioned context semantic vector sequence, the BiLSTM module models it from both forward and backward directions: the forward propagation process can be represented as... , This represents the forward feature vector of the context semantic vector output by the forward LSTM at the i-th time step. Let represent the hidden state at the (i-1)th time step of the forward LSTM. The forward feature vectors from multiple time steps together constitute the forward feature vector sequence. The backpropagation process can be represented as follows: , This represents the inverse feature vector of the context semantic vector output by the inverse LSTM at the i-th time step. This represents the hidden state at the (i+1)th time step of the inverse LSTM. The inverse feature vectors from multiple time steps form the inverse feature vector sequence. By fusing the bidirectional propagation results, we obtain the bidirectional feature vector at the ith time step. , Let represent the bidirectional feature vector output at the i-th time step. Multiple bidirectional feature vectors from various time steps form a bidirectional feature vector sequence. In the forward and backward propagation processes described above, the feature vector calculation at each time step is implemented using a standard LSTM unit.

[0061] The BiLSTM module enhances entity boundary recognition capabilities and improves contextual continuity modeling, addressing the modeling challenges of long and complex sentences in coal spontaneous combustion texts. Furthermore, it captures temporal dependencies, supplementing the BERT module's limitations in local sequence modeling and improving fine-grained semantic expression. Through the bidirectional structure of the bidirectional Long Short-Term Memory network, the BiLSTM module can simultaneously utilize both preceding (historical dependencies) and following (future) contextual information, significantly improving its ability to model entity boundaries, long entity recognition, and contextual semantic continuity in coal spontaneous combustion texts.

[0062] Step S1303: Using the linear layer and label transition matrix of the CRF module, determine the global total score of each label sequence; using the Viterbi algorithm, determine the target label sequence based on the global total score of each label sequence; based on the target label sequence, extract entities from the text sequence corresponding to the structured output sample to obtain a candidate entity set.

[0063] Step S1303 can be achieved through the following steps: Step S13031: Using the weight matrix and bias of the linear layer of the CRF module, perform a linear mapping on the bidirectional feature vector sequence to obtain the emission score of the tag corresponding to each position of the bidirectional feature vector sequence; In this embodiment, the entities can be labeled using a BIO annotation system with entity types, and the label sequence is defined as: Y Where Y is the label sequence, Let B be the label corresponding to the i-th position in the bidirectional feature vector sequence. Label B - entity type indicates that the corresponding word is the starting word of the current type entity, label I - entity type indicates that the corresponding word is an internal / subsequent word of the current type entity, and label O indicates that the corresponding word is a non-entity word. A Conditional Random Field (CRF) module can be introduced to globally optimize the label sequence to ensure the consistency and validity of the annotation results. The bidirectional feature vector sequence output by the BiLSTM module is linearly mapped to obtain the emission score. ,in, The weight matrix of the linear layer. For the bias of the linear layer, The label corresponding to the i-th position in the bidirectional feature vector sequence The launch score.

[0064] Step S13032: Based on the emission score of the tag corresponding to each position and the transfer score from the tag corresponding to the previous position to the tag corresponding to the current position in the tag transfer matrix of the CRF module, determine the global total score of each tag sequence; The label transition matrix is ​​a trainable parameter matrix of the CRF module, used to store the transition scores between different labels, reflecting the legitimate transition relationships between labels; the global total score of the label sequence Y corresponding to the bidirectional feature vector sequence can be calculated by formula (5): ; in, Represents a bidirectional eigenvector sequence. Represents a label sequence. This indicates the label corresponding to the previous position i-1. To the label corresponding to the current position i The transfer fraction, For label sequence The total score.

[0065] Conditional probability is defined as shown in formula (6): ; in, This represents the label probability distribution of the bidirectional feature vector sequence. For all possible label sequences corresponding to the bidirectional feature vector sequence, Represents a possible label sequence The global total score; during training, the log-likelihood function is maximized. The parameters of the CRF module are adjusted to maximize the prediction probability of the CRF module for the real label sequence, thereby learning the legitimate transition relationships between labels.

[0066] Step S13033: Using the Viterbi algorithm, the label sequence with the highest global total score is determined as the target label sequence. The target label sequence is used to characterize the position and entity type of the entity in the text corresponding to the bidirectional feature vector sequence. In the prediction phase, the Viterbi algorithm is used to find the optimal path: , The target label sequence is the sequence with the highest global total score selected from all possible label sequences. The CRF module can effectively introduce label constraints to avoid illegal sequences, improve entity integrity, ensure entity boundary integrity, and improve overall annotation consistency.

[0067] Step S13034: Based on the target label sequence, entity extraction is performed on the text sequence corresponding to the structured output sample to obtain a candidate entity set.

[0068] Specifically, based on the BIO annotation rules and the one-to-one correspondence between the target tag sequence and the text sequence, entity recognition can be performed on the text: the starting boundary and internal range of the entity are distinguished by the B and I tags, achieving accurate positioning of the entity boundary; at the same time, the entity type carried by the B and I tag suffixes is directly read to determine the type of the corresponding entity. After traversing the complete text sequence, all the identified entities with entity type information are summarized to form a candidate entity set.

[0069] First, the emission scores of each label are obtained through linear mapping. Then, the global total score of the complete label sequence is calculated by combining the label transition scores. The optimal label sequence is selected and entity extraction is completed by relying on the Viterbi algorithm. The logical transition rules between text labels are fully considered to avoid recognition errors caused by independent label judgment, improve the rationality of entity label division and the accuracy of entity extraction, and adapt to the sequence labeling scenario of coal spontaneous combustion professional text.

[0070] In the above embodiments, a hierarchical model combining BERT, BiLSTM, and CRF is used to complete entity recognition. BERT is used to achieve deep semantic encoding to obtain context vectors. BiLSTM is used to bidirectionally mine forward and backward features of the text. Then, CRF is used in combination with label transfer rules and the Viterbi algorithm to solve for the optimal label sequence and extract entities. By fully integrating semantic features and context sequence features, the accuracy and reliability of entity recognition in the field of spontaneous combustion of coal are improved, and various target entities can be accurately extracted from the text.

[0071] In some embodiments, the knowledge extraction layer further includes a relation extraction module, and step S130, "constructing effective entity pairs based on the entities and preset constraints; determining the semantic relation type of the effective entity pairs," includes: Step S1304: Using the relation extraction module, construct multiple candidate entity pairs based on the candidate entity set, and filter valid entity pairs from the multiple candidate entity pairs according to preset constraints; The relation extraction module is used to automatically identify the semantic relationships (i.e., semantic relationship types) between entities based on the identified entities, realize the structured mapping from entity sets to knowledge triples, and achieve the key transformation from unstructured text to structured knowledge. It is a key link in the construction of knowledge graphs.

[0072] A standard entity set is obtained based on the named entity recognition results. Construct a candidate entity set based on the standard entity set: in, Represents the set of candidate entities. Let m be the m-th candidate entity. We combine entities in the candidate entity set pairwise to form candidate relation pairs: ( ),in, Indicates the first One candidate entity, Indicates the first One candidate entity, ≠ Candidate entities Corresponding entity Candidate entities Corresponding entity To improve the accuracy of relation extraction, preset constraints can be introduced to filter candidate entity pairs and obtain valid entity pairs. The preset constraints include distance constraints (used to limit the maximum span between entities), entity type constraints (used to exclude entity pairs that cannot have a relationship based on preset entity type combination rules), and same sentence constraints (used to limit entities to be located in the same sentence to avoid cross-sentence mismatch).

[0073] Step S1305: Introduce entity location markers into the valid entity pairs to obtain a marker sequence; To highlight the target entity, an entity marker can be introduced to construct a marker sequence: , Represents a labeled sequence. This indicates a special start marker, placed at the very beginning of the entire sequence. and For two entities in a valid entity pair, and Entities The start and end markers, and Entities By using start and end markers, this method can enhance the perception of the target entity's location, reduce interference from irrelevant words, and improve the accuracy of relation classification.

[0074] Step S1306: Input the labeled sequence into the BERT encoder of the relation extraction module to obtain a set of context vectors composed of the context vectors of each word in the labeled sequence, and extract the set of word vectors corresponding to the entity from the set of context vectors. Input the labeled sequence into the BERT encoder to obtain a set of context vectors: , For the set of context vectors, For the first The context vector corresponding to each word.

[0075] Step S1307: Based on the word vector set of each entity, generate the semantic vector of the corresponding entity through average pooling; based on the sentence vector of the tag sequence and the semantic vectors of the two entities in each entity pair, generate the fused feature vector of the corresponding entity pair. The sentence vector representation of the marked sequence is as follows: (X') , The sentence vector representing the marked sequence, the marked sequence Input the BERT encoder and retrieve special markers. The corresponding output vector serves as the sentence vector, which encodes the global semantic information of the entire token sequence. The semantic vector of the corresponding entity can be generated using the average pooling method shown in formula (7): = Formula (7); in, Represents the i-th entity. Representing entities The number of lexical units included. This is the word vector at position k in the context vector set. For entities The semantic vector. Similarly, entities can be generated. semantic vectors .entity and entity The fused feature vector corresponding to the entity pair can be represented as: , To fuse feature vectors, introducing entity-level representations can significantly enhance the model's ability to express local semantics and entity features.

[0076] Step S1308: Using the fully connected layer of the relation extraction module, based on the fusion feature vector of each entity pair, determine the predicted probability that the corresponding entity pair belongs to each preset relation type, and determine the relation type with the highest predicted probability as the semantic relation type of the corresponding entity pair.

[0077] Among them, the fused feature vector can be input into the fully connected layer of the relation extraction module for relation classification, and the entity can be calculated by the following formula (8). and entity The entity pair relation probability distribution vector of the formed entity pairs: ) Formula (8); in, It is a vector of entity-pair relation probability distributions, where each element corresponds to the predicted probability of a relation type. For the bias of the fully connected layer, To fuse feature vectors. This is used to map the output of the fully connected layer to a probability distribution of relation categories, which can determine the relation type with the highest predicted probability as the semantic relation type of the corresponding entity pair.

[0078] To handle a large number of unrelated entity pairs, an unrelated category "None" is introduced to filter invalid relationships and improve the robustness of the model.

[0079] To train the relation extraction module, the cross-entropy loss function is used to calculate the loss between the predicted results and the true labels of all entities. To alleviate the class imbalance problem, this embodiment introduces Focal Loss for optimization. By reducing the weight of easily classified samples, the model's ability to learn minority class relations is improved, thus alleviating the class imbalance problem.

[0080] Figure 3 This application provides a schematic diagram of the model architecture and process of a knowledge extraction layer. The knowledge extraction layer uses a BERT-BiLSTM-CRF model combined with a relation extraction module to achieve accurate extraction of entities and relations in the field of spontaneous combustion of coal. The schematic diagram of the architecture and process of the BERT-BiLSTM-CRF model is shown below. Figure 4 As shown, the BERT-BiLSTM-CRF model includes a BERT module (also known as the BERT encoding layer), a BiLSTM module (also known as the BiLSTM layer), a CRF module (also known as the Conditional Random Field layer), and a relation extraction module. The specific process is as follows: The input data is a preprocessed structured output sample. The structured output sample is marked with CLS and SEP special tags at the beginning and end, respectively. The structured output sample contains key semantic units in the field of coal spontaneous combustion, such as location, accident, gas, level, measures, equipment, date, warning, and region, providing complete contextual information for subsequent encoding.

[0081] The BERT coding layer performs word embedding, sentence embedding, and position embedding on the structured output samples, converting the text into a vector representation containing contextual semantic information, such as word embedding vectors, position embedding vectors, and sentence embedding vectors (also known as segmented embedding vectors).

[0082] like Figure 5 As shown, a word embedding vector consists of multiple vectors, and the vector indices are used to distinguish the corresponding lexical units or special tags: , Vectors corresponding to the special markers of CLS and SEP respectively; , , , , , , , , The subscripts are identifiers for the corresponding domain words, representing the word vectors of the corresponding words "location", "accident", "gas", "level", "measure", "equipment", "date", "warning", and "region".

[0083] Segment embedding vectors are uniformly adopted The subscript A indicates that the current text belongs to the same sentence segment; the position embedding vector is... , , , , , , , , , , The subscript number represents the position number of the word in the sequence.

[0084] The three types of embedding vectors are added bit by bit to obtain a fused embedding vector sequence. Then, a multi-layer bidirectional semantic encoding is performed by a Transformer encoder to generate a context semantic vector sequence with dimensions (B,L,H) to capture long-distance dependencies between words in the text, where B represents the batch size, L represents the sequence length, and H represents the hidden layer dimension.

[0085] The BiLSTM layer performs bidirectional sequence modeling on the context semantic vector sequence output by the BERT encoding layer, extracting the sequence features of the text from both the forward and reverse directions to obtain a bidirectional feature vector sequence of dimension (B,L,2H), further capturing the local contextual dependencies of the text and providing richer sequence features for subsequent entity boundary recognition.

[0086] The Conditional Random Field (CRF) layer maps the bidirectional feature vector sequence output by BiLSTM to the label space. The CRF layer then performs global label constraints, outputting an entity label sequence Y conforming to the BIO (Browser-Induced Object) system. Here, O indicates that a word does not belong to any entity; B-XXX represents the starting word of a certain type of entity, such as B-ACC (accident entity), B-LOC (location entity), B-GAS (gas entity), B-FAC (equipment entity), B-MEA (measure entity), etc. Subsequent words belonging to the same entity are labeled I-XXX. Based on the label sequence decoding, a candidate entity set is obtained, enabling accurate identification and boundary delineation of entities in the coal spontaneous combustion domain.

[0087] like Figure 6 As shown, the relation extraction module extracts relations based on a set of candidate entities: first, it constructs candidate entity pairs by combining the identified entities in pairs; for example, it combines location entities... gaseous entities Pairing to form candidate entity pairs ( , ), and select valid entity pairs from the multiple candidate entity pairs according to preset constraints.

[0088] To enable the model to accurately locate the positions of valid entity pairs in the text, entity tagging is performed on the valid entity pairs. Specifically, [E1] and [ / E1] tags are added to the beginning and end of the first entity (such as the location entity "top corner"), and [E2] and [ / E2] tags are added to the beginning and end of the second entity (such as the gas entity "CO"). The special tags [CLS] and [SEP] are still retained at the beginning and end of the sequence, forming a special input sequence (i.e., the tagging sequence) for relationship extraction in the form of [CLS]...location [E1]top corner[ / E1]...gas [E2]CO[ / E2]...[SEP].

[0089] Semantic representations are extracted again using the BERT encoder, and a fused feature vector is constructed. ,in, For sentence vectors, For entities semantic vectors, For entities The semantic vector.

[0090] The fused feature vectors are classified into relationships, and the semantic relationship types between entity pairs are output. Finally, knowledge triples containing entities and relationships are generated, realizing the structured extraction of knowledge in the field of spontaneous combustion of coal.

[0091] Through the above model architecture, this application achieves end-to-end accurate extraction of entities and relationships in the field of spontaneous combustion of coal, solves the problems of inaccurate entity boundary recognition and incomplete semantic relationship extraction in professional texts, and provides high-quality structured knowledge data for subsequent knowledge graph construction.

[0092] In the above embodiments, a relation extraction module is added. It relies on multiple constraints to filter effective entity pairs, and combines entity location marking, BERT encoding, average pooling and feature concatenation to generate fused features. Then, the relation probability prediction and classification are completed through a fully connected layer. This can accurately filter invalid entity pairs, fully integrate the global semantics of sentences and the local semantics of entities, accurately identify various professional relations such as temporal causality and risk propagation, and ensure the effectiveness and accuracy of relation information in knowledge triples.

[0093] Figure 7 This is a schematic diagram of the processing flow of a graph construction layer provided in an embodiment of this application. The graph construction layer takes the initial set of knowledge triples output by the L3 knowledge extraction layer as input, and completes knowledge fusion and graph construction based on the fusion strategy and rule base, realizing the structured storage and associative expression of knowledge in the field of spontaneous combustion of coal. The specific process is as follows: The knowledge graph construction layer, also known as the L4 knowledge fusion and knowledge graph construction layer, is supported by fusion strategies and rule bases. Figure 8As shown, the fusion strategy and rule base includes domain ontology, specification rules, and weighting strategies, providing a standardized basis for each stage. The processing steps include: Confidence filtering: Based on the confidence information output from the extraction stage, invalid triples with low confidence are filtered out, and only high-reliability knowledge triples are retained, thereby reducing the impact of noisy data on the quality of the map.

[0094] Entity alignment: Construct a domain thesaurus to normalize entities and resolve synonyms. For example, "CO" and "carbon monoxide" are uniformly mapped to the normalized entity "CO concentration", and "upper corner" and "return air upper corner" are uniformly mapped to "working surface upper corner", ensuring that different representations of the same entity correspond to a unique node in the graph.

[0095] Relation normalization: Based on the domain ontology, the semantics of relations are standardized and different expressions of the same type of relations are mapped to standard relation types (such as unifying "indicate" and "show" as "indicate", and "cause" and "lead" as "cause_of"), thus eliminating the ambiguity of relation expressions.

[0096] Triple fusion construction: Based on the thesaurus, the entity and relation are normalized at the triple level, and duplicate triples pointing to the same knowledge are merged, while the source information and confidence are retained as attributes of entities and relations.

[0097] Graph Structure Construction: Using normalized entities as the node set V and standardized relations as the edge set E, construct the basic graph structure of the coal spontaneous combustion knowledge graph.

[0098] Figure 9 This example demonstrates a knowledge graph structure, showcasing a portion of the core relationship network of the coal spontaneous combustion knowledge graph within the graph construction layer. Nodes are categorized into four types: indicator parameters, state processes, regional locations, and prevention and control equipment. Nodes are connected through standardized relationships, for example: The indicator parameter nodes "CO concentration" and "temperature" are connected to the state process node "spontaneous combustion risk" through the indicate relationship, indicating that changes in the indicators can indicate the risk of spontaneous combustion; The location node "goaf" and the state process node "increased oxygen supply" are connected by the cause_of relationship, indicating that air leakage in the goaf can lead to increased oxygen supply; The prevention and control measures nodes "nitrogen injection" and "grouting" are connected to the state process node "increased oxygen supply" through the apply_measure relationship, indicating that the above measures can be used to deal with the risk of increased oxygen supply.

[0099] The knowledge graph constructed using Neo4j is ultimately stored in the Neo4j graph database. Nodes store entity and attribute information, including entity type, confidence level, and data source; edges store relation types and attribute information. This storage method supports subsequent graph retrieval, association reasoning, and intelligent question-and-answer applications, providing efficient data support for early warning and prevention decisions regarding coal spontaneous combustion risks.

[0100] Through the above process, this layer achieves standardized fusion and structured storage of multi-source knowledge, solves the problem of inconsistent entity and relation representations in multi-source data, and constructs a structurally standardized and traceable knowledge graph of spontaneous combustion of coal.

[0101] In some embodiments, the application layer further includes a graph query module and an association path analysis module, and the method further includes: Step S1601: Using the graph query module, the knowledge graph is traversed and retrieved based on the current monitoring data to obtain the first graph query result; The application layer, based on the constructed knowledge graph related to coal spontaneous combustion, performs efficient retrieval, path reasoning, and application analysis of structured knowledge, realizing the transformation from knowledge representation to intelligent applications. It provides decision support for coal spontaneous combustion monitoring and early warning, and is the core layer of the system for practical engineering applications. Building upon the graph construction layer, this layer deeply utilizes and semantically mines the graph structure data, mainly including: graph query, intelligent question answering, path analysis, risk warning, and visualization.

[0102] The graph query module, based on the Cypher query language provided by the graph database (Neo4j), enables efficient retrieval and combined queries of entities and semantic relationships. The module utilizes a knowledge graph as its foundation, leveraging graph database query mechanisms to achieve efficient retrieval of entities, relationships, and their attributes. Let the knowledge graph be represented as: ,in, Represents a set of entity nodes. This represents the set of relation edges. For any queried entity, its set of relations can be represented as: ,in, Let i be the i-th entity, for example, "coal". For and For related entities that have a direct relationship, such as "carbon monoxide", 'r' represents the type of relationship between the entities, such as "produce", "cause", or "contain". Representing entities This module provides a set of associated entities. By traversing and filtering the adjacency relationships of nodes, it can retrieve all associated entities and their semantic relationships related to the target entity, thereby enabling rapid retrieval of indicators, statuses, risks, and prevention and control measures related to coal spontaneous combustion. The module supports multi-dimensional combined queries based on entity attributes, relationship types, and conditional constraints, providing high-quality data support for path analysis and risk identification.

[0103] Step S1602: Using the association path analysis module, determine the multi-hop association path of the entity based on the first graph query result, wherein the multi-hop association path of the entity includes causal relationship association path, stage association path and risk propagation path.

[0104] The association path analysis module utilizes the graph structure characteristics of knowledge graphs to analyze and reason about multi-hop relationships between entities based on the query results of the first graph, thereby uncovering potential causal relationship paths, stage-based association paths, and risk propagation paths. The system uses temporal causal relationships in the knowledge graph to perform association path analysis on the risk status of coal spontaneous combustion, achieving dynamic evolution analysis of the risk status across different stages. A path between entities is defined as: The path length is: | k+1, Let k be an intermediate entity node on the path, and k+1 represent the path length. By searching the set of paths, all possible association paths between entities can be obtained. , In the scenario of spontaneous combustion of coal, this module can be used to identify the following risk chain: "air leakage → increased oxygen supply → intensified oxidation → increased CO concentration → risk of spontaneous combustion". This process realizes the expansion from a single relationship to a multi-level causal relationship, providing support for complex risk evolution analysis.

[0105] In the above embodiments, a knowledge graph query module and an association path analysis module are added. The knowledge graph can be retrieved based on the current monitoring data and multi-hop association paths of entities can be mined. The three core links of causality, stage evolution and risk propagation can be accurately sorted out, which makes up for the limitations of single rule identification and provides complete knowledge graph link support for risk level correction, spontaneous combustion stage determination and evolution trend analysis, thereby enhancing the reasoning and analysis capabilities of the method.

[0106] In some embodiments, the application layer further includes an intelligent question-answering module, and the method further includes: Step S171: Use the intelligent question answering module to perform semantic parsing on the natural language question input by the user, and extract the question entity and relational intent; Step S172: Convert the question entity and the relational intent into a structured query statement, execute the query on the knowledge graph, and obtain the second graph query result; Step S173: Generate and output a natural language answer based on the query result of the second graph.

[0107] The intelligent question-answering module, based on knowledge graph and natural language processing technologies, automatically maps user natural language questions to structured queries. For user-input questions... The system first performs semantic parsing to extract key entities and relational intents: ,in, This represents the p-th entity involved in the problem. It represents the potential relationship type. Finally, it converts the query results into natural language for output, achieving a closed-loop process of "knowledge retrieval - semantic understanding - result generation." This module effectively lowers the barrier to entry for knowledge graphs and improves the system's interactivity and intelligence.

[0108] In the above embodiments, an intelligent question-answering module is configured, which can perform semantic parsing, entity and intent extraction on users' natural language questions, convert them into structured statements to query the knowledge graph and generate natural language answers. This enriches the system's interaction methods and makes it easier for staff to quickly query knowledge, risk information and prevention and control content related to coal spontaneous combustion through natural language, thereby improving the usability and service capabilities of the knowledge graph.

[0109] In some embodiments, the application layer further includes a visualization module, and the method further includes: Step S174: Using the visualization module, display the entity node relationship network in the knowledge graph, highlight the causal relationship path, the stage relationship path, and the risk propagation path, and support interactive viewing.

[0110] The visualization module is used to graphically represent the knowledge graph structure and analysis results, enhancing the system's interpretability and interactivity. Within the knowledge graph's graph structure, the visualization of nodes and edges enables the following functions: displaying the entity node relationship network, highlighting multi-hop paths, and dynamically presenting the risk propagation chain. Through interactive operations, users can intuitively observe the relationships between entities and the risk evolution process, thereby aiding in understanding the mechanism of spontaneous combustion in coal and the early warning logic. This module transforms abstract, structured knowledge into intuitive and visual information representation, effectively improving the system's usability and engineering application value.

[0111] The application layer achieves a key leap from knowledge representation to knowledge application. By integrating graph query, association path analysis and risk warning mechanisms, it transforms structured knowledge into intelligent decision-making capabilities for coal spontaneous combustion monitoring. It is the core support layer for the system to realize its engineering application value.

[0112] In the above embodiments, a visualization module is added to intuitively present the entities and relationship networks of the knowledge graph, highlight various related links and support interactive viewing, and graphically display the abstract knowledge structure, causal relationship and risk link, so that staff can intuitively grasp the inherent relationship of coal spontaneous combustion and the risk evolution path, and improve the human-computer interaction experience and on-site application convenience of the system.

[0113] Figure 10 This is a schematic diagram of the functional architecture of an application layer provided in an embodiment of this application. This application layer, also known as the L5 graph retrieval and application layer, provides various application capabilities based on the constructed coal spontaneous combustion knowledge graph, offering decision support for coal spontaneous combustion risk prevention and control. Specific functional modules are as follows: The graph retrieval module (also known as the graph query module) retrieves and returns related entities and their corresponding relationships centered on a specified entity, forming a subgraph of relationships with the target entity as the core. It supports rapid querying of entities related to coal spontaneous combustion indicators, risks, and measures.

[0114] The path analysis and reasoning module (also known as the association path analysis module) is based on the topological structure of the knowledge graph to realize critical path and causal chain reasoning. On the one hand, it can perform shortest path and critical path search and explore the association links between entities. On the other hand, it can reconstruct the formation process of coal spontaneous combustion risk through causal chain reasoning, providing a basis for risk tracing.

[0115] Risk warning module: Taking current monitoring data (such as CO concentration, temperature, wind speed, etc.) as input, and combining the association rules in the knowledge graph, it assesses the risk level of coal spontaneous combustion and outputs warning results of different levels such as low risk, medium risk, and high risk, so as to realize the hierarchical management of risks.

[0116] Intelligent Question Answering Module: Provides users with natural language interaction capabilities: First, it performs semantic analysis on the user's natural language questions to identify entities and relationships in the questions; then, it performs queries and reasoning based on knowledge graphs; finally, it generates and displays the answers, providing users with a convenient channel for knowledge acquisition.

[0117] Visualization module: Provides multi-dimensional visualization methods, including: Subgraph visualization: Displaying the local graph structure of a specific entity and its relationships; Path visualization: Intuitively presents the relationships and causal links between entities; Risk heat map: Displays the risk distribution in different areas in the form of heat, making it easy to quickly identify high-risk areas.

[0118] Example of Path Reasoning (Causal Chain): Taking the reasoning about the risk of spontaneous combustion of coal as an example, this demonstrates the complete causal reasoning process: Physical link: air leakage → increased oxygen supply → intensified oxidation → increased CO concentration → risk of spontaneous combustion; Relationship types: Entities in the link are connected through standard relationships such as cause_of and indicate; Reasoning results: The final output is a complete causal chain of "air leakage → increased oxygen supply → intensified oxidation → increased CO concentration → risk of spontaneous combustion (high risk)," which clarifies the key links and development path of risk formation.

[0119] Through the aforementioned functional modules, this layer realizes the transformation of the coal spontaneous combustion knowledge graph from static data to dynamic applications, providing on-site staff with risk warnings, decision support, and convenient knowledge services, thereby improving the level of intelligence in coal spontaneous combustion prevention and control.

[0120] Figure 11 A diagram illustrating a knowledge graph construction and early warning application mechanism for spontaneous combustion of coal based on BERT-BiLSTM-CRF, as provided in this application embodiment, is shown below. Figure 11 As shown, the coal spontaneous combustion knowledge graph system constructed in this application embodiment is divided into a five-layer architecture, from bottom to top: L1 data input layer, L2 data processing layer, L3 knowledge extraction layer, L4 graph construction layer and L5 application layer. Its core technical path is: multi-source text data input → semantic extraction → triple generation → graph database storage → retrieval question answering and risk assessment, realizing a closed loop of intelligent identification and early warning application for coal spontaneous combustion risk.

[0121] The L1 data input layer provides the system with multi-dimensional and highly reliable data sources, including CNKI literature texts, coal spontaneous combustion accident case reports, and current monitoring data description texts, covering three scenarios: theoretical research, accident review, and engineering site, providing comprehensive corpus support for subsequent knowledge extraction.

[0122] The L2 data processing layer performs standardized preprocessing on the input text data, including cleaning, denoising and deduplication, normalization of technical terms, and segmentation of sentences and conversion into structured data in list[dict] format. This eliminates text noise and format differences, providing a unified format corpus for subsequent model input.

[0123] The L3 knowledge extraction layer employs a BERT-BiLSTM-CRF deep learning model to accurately extract knowledge in the field of spontaneous combustion of coal. First, the preprocessed text is semantically encoded using the BERT model to generate contextual semantic vectors. Then, the BiLSTM model is used for sequence modeling to extract bidirectional sequence features of the text and capture the contextual dependencies. Finally, the CRF model is used for global label constraints to optimize the entity boundary recognition effect, ultimately outputting entity, relation, attribute, and confidence information, achieving a technological breakthrough in entity boundary recognition and semantic relation extraction in professional texts.

[0124] The L4 graph construction layer integrates and stores the extracted knowledge. First, it eliminates ambiguity between synonymous entities through entity disambiguation fusion. Then, it generates triples that conform to the "entity-relationship-entity" structure based on entity and relation information. Finally, it imports the triple data into the Neo4j graph database for storage, constructing the core relation network of the coal spontaneous combustion knowledge graph. For example, it establishes relationships such as "coal spontaneous combustion risk event - indication - CO", "coal spontaneous combustion risk event - occurred in - upper corner", "coal spontaneous combustion risk event - participation in the judgment - O2", and "coal spontaneous combustion risk event - prevention and control - nitrogen injection / grouting", achieving structured and relational storage of knowledge.

[0125] The L5 application layer provides three core applications based on the constructed knowledge graph: graph retrieval, intelligent question answering, and risk warning and assessment. Users can input questions or on-site monitoring indicators and invoke the Cypher query language to perform graph reasoning. The system will return related entities, evidence chains, and risk levels to assist on-site prevention and control decisions. For example, when on-site monitoring detects "continuously rising CO, decreasing O2, and abnormal upper corner," the system can identify the risk of spontaneous combustion of coal and recommend targeted prevention and control measures such as end sealing, inert injection for cooling, and grouting for temperature suppression, forming a complete closed loop of "data input—knowledge extraction—graph construction—early warning application."

[0126] Furthermore, this application establishes a dual closed-loop optimization mechanism to achieve continuous system iteration and updates: The model iteration optimization closed loop includes feeding back samples with low confidence and manually labeled corrections from the extraction results to the BERT-BiLSTM-CRF model for retraining, thereby iteratively optimizing model parameters and improving the accuracy of subsequent knowledge extraction. The on-site feedback and graph update closed loop includes risk assessment results output from the application layer and on-site prevention and control effect feedback. New accident cases, monitoring data, and prevention and control measures are added to the Neo4j knowledge graph, updating entity, relationship, and attribute information to achieve dynamic expansion and improvement of the graph, further enhancing the accuracy of subsequent retrieval, question answering, and early warning decisions.

[0127] This application, through the aforementioned architecture and deep learning, solves the problems of difficult structuring of professional textual knowledge, inaccurate entity boundary recognition, and incomplete semantic relationship extraction in existing coal spontaneous combustion risk early warning systems. It realizes the integrated application of traceable knowledge retrieval, question-and-answer interpretation, and early warning decision-making, providing intelligent and interpretable technical support for coal spontaneous combustion prevention and control.

[0128] Figure 12 This application provides an embodiment of an intelligent early warning method for spontaneous coal combustion based on deep semantic self-extraction and knowledge graph reasoning. The method consists of a five-layer progressive processing flow, from multi-source data input to intelligent application output, achieving automated construction of knowledge about spontaneous coal combustion and intelligent early warning. Details are as follows: L1 multi-source heterogeneous data input layer (i.e., data input layer): This layer provides the data foundation for the entire method. The input data includes heterogeneous data from multiple sources, such as case studies of coal spontaneous combustion accidents, relevant standards and specifications, and academic papers. After integration and processing, the data from different sources is uniformly converted into a unified intermediate data structure (i.e., structured records), achieving data format standardization and providing a consistent data foundation for subsequent processing.

[0129] L2 data processing layer: The input unified intermediate data structure is cleaned, normalized, and structured. The steps include: Field cleaning: Remove invalid, duplicate, or malformed data; Entity field standardization: unifying the format and representation of entity fields; Terminology normalization: Standardizing and mapping professional terms in the field of spontaneous combustion of coal; Text standardization: unifying text format, punctuation, and encoding; Case-specific unique code generation: Assign a unique identifier to each data sample; Structured output construction: Transform the processed data into structured output samples suitable for model input.

[0130] L3 knowledge extraction layer: Knowledge extraction is performed using the BERT-BiLSTM-CRF model, and the steps include: BERT pre-trained encoding: performs bidirectional semantic encoding on structured text to generate a sequence of context semantic vectors; BiLSTM sequence feature extraction: Bidirectional sequence modeling is performed on the vector output by BERT to extract the context-dependent features of the text and obtain a bidirectional feature vector sequence; CRF Tag Constraint Decoding: Applying global constraints to sequence labels using a conditional random field, and outputting a sequence of entity labels; Named entity recognition and relation extraction: Extract entities in the field of spontaneous combustion of coal based on the decoding results, identify semantic relationships between entities, and generate knowledge triples.

[0131] L4 Knowledge Fusion and Knowledge Graph Construction Layer: Based on the domain ontology and rule base, the extracted knowledge triples are fused and graphs are constructed. The steps include: Domain ontology construction: Establishing entity, relation, and attribute specifications for the domain of spontaneous combustion of coal; Entity alignment and disambiguation: Solve the problems of synonymy and homonymy, and achieve entity normalization; Relation normalization: unifying the semantic representation of relations and eliminating ambiguity; Attribute completion: Supplement the confidence level, source, and other attribute information of entities and relationships; Ultimately, a standardized knowledge graph of spontaneous combustion of coal was constructed.

[0132] L5 Graph Retrieval and Application Layer: Based on the completed coal spontaneous combustion knowledge graph, it provides multiple intelligent application capabilities, including: Graph Query: Supports entity-centric association retrieval; Intelligent question answering: Provides semantic parsing and answer generation for users' natural language questions; Path analysis: Supports critical path search and causal chain reasoning; Risk warning: Assess the risk level of spontaneous combustion of coal based on on-site data; Visualization: Provides multi-dimensional visualizations such as sub-maps, paths, and risk heatmaps.

[0133] Through the above five-layer progressive process, this application realizes the automated construction of knowledge in the field of spontaneous combustion of coal from multi-source data to structured graphs, and achieves intelligent early warning and decision support through graph reasoning, thereby improving the level of intelligence in the prevention and control of spontaneous combustion of coal.

[0134] In some embodiments, this application constructs a domain-series causal relationship system for the evolution of coal spontaneous combustion stages and risk propagation, based on the dynamic evolution mechanism of coal spontaneous combustion disasters.

[0135] This application models the dynamic process of "indicator change - state evolution - risk propagation - intervention" in coal spontaneous combustion. By introducing temporal, causal, and risk propagation relationships, it achieves a structured expression of the dynamic evolution of coal spontaneous combustion. In reality, coal spontaneous combustion is not an isolated indicator anomaly, but a dynamic evolutionary process formed by the combined effects of multiple factors. For example, air leakage in the goaf leads to increased oxygen supply, further intensifying coal oxidation, followed by increased temperature, increased carbon monoxide concentration, and the release of characteristic gases such as ethylene, ultimately escalating the risk of coal spontaneous combustion. Therefore, the risk of coal spontaneous combustion inherently possesses distinct stage evolution characteristics, temporal propagation characteristics, and multi-indicator coupling characteristics.

[0136] Based on the aforementioned characteristics of coal spontaneous combustion mechanisms, this application, in the process of relational modeling, not only establishes basic semantic relationships between entities, but also establishes dynamic semantic relationships between: indicator change relationships, stage evolution relationships, risk propagation relationships, intervention measure relationships, and temporal sequence relationships. By constructing a multi-level relational chain of "indicator-state-process-risk-measure," a unified expression of the dynamic evolution mechanism of coal spontaneous combustion is achieved, providing fundamental support for subsequent risk propagation reasoning, multi-hop path analysis, and dynamic early warning.

[0137] This application uses a domain relationship type system to unify and link monitoring indicators, evolutionary states, risk stages, and prevention and control measures in the field of coal spontaneous combustion, realizing the transformation from static knowledge association to dynamic risk evolution reasoning, thereby improving the accuracy and interpretability of coal spontaneous combustion risk identification and early warning analysis.

[0138] Based on the foregoing embodiments, this application provides a coal spontaneous combustion early warning system based on knowledge graph reasoning. The system includes various modules and sub-modules, and each unit of each sub-module can be implemented by a processor in an electronic device; of course, it can also be implemented by specific logic circuits. In the implementation process, the processor can be a central processing unit (CPU), a microprocessor (MPU), a digital signal processor (DSP), or a field programmable gate array (FPGA), etc.

[0139] Figure 13 A schematic diagram of the composition structure of a coal spontaneous combustion early warning system based on knowledge graph reasoning, provided in an embodiment of this application, is shown below. Figure 13 As shown, the system 200 includes: The data input layer 21 is used to acquire multi-source raw data related to spontaneous combustion of coal and convert the raw data into structured records stored in the form of key-value pairs and containing at least title, body, source and metadata fields; Data processing layer 22 is used to perform text standardization processing on the structured records and construct a structured output sample that retains the occurrence sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the risk transmission context information. The knowledge extraction layer 23 is used to perform semantic encoding and sequence modeling on the structured output samples, identify entities in the structured output samples, construct effective entity pairs based on the entities and preset constraints, and determine the semantic relationship type of the effective entity pairs. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship type includes at least temporal causal relationship, risk propagation relationship, and stage evolution relationship. The knowledge extraction layer 23 is also used to generate an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information based on the effective entity pairs and corresponding semantic relationship types. The graph construction layer 24 is used to perform confidence-based filtering, deduplication, and conflict-based optimal fusion processing on the initial knowledge triples, and to perform entity alignment and relation normalization processing to obtain normalized knowledge triples; the normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. Application layer 25 is used to acquire current monitoring data of the coal spontaneous combustion site, determine the initial risk level based on preset risk identification rules and multi-indicator coupling rules; modify the initial risk level based on the causal relationship information of the knowledge graph to obtain the target risk level; determine the current coal spontaneous combustion stage and risk evolution trend based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, and output the corresponding recommended disposal measures.

[0140] In some possible embodiments, the data processing layer 22 is used to sequentially perform data cleaning and format standardization, key domain terminology mapping standardization, professional terminology normalization, text structuring processing, and traceable sample construction processing on the structured records to generate structured output samples that retain the time sequence of coal spontaneous combustion events, coal spontaneous combustion stage attributes, and risk transmission context information.

[0141] In some possible embodiments, the knowledge extraction layer 23 includes a BERT module, a BiLSTM module, and a CRF module. The BERT module is used to sequentially perform multi-dimensional embedding encoding, vector fusion, Transformer self-attention feature encoding, and feature edge transformation on the structured output sample to obtain the context semantic vector sequence corresponding to the structured output sample. The BiLSTM module is used to extract the forward feature vector sequence and the backward feature vector sequence of the context semantic vector sequence respectively, and concatenate the forward feature vector sequence and the backward feature vector sequence according to the time step dimension to obtain a bidirectional feature vector sequence. The linear layer and label transition matrix of the CRF module are used to determine the global total score of each label sequence; the Viterbi algorithm is used to determine the target label sequence based on the global total score of each label sequence; based on the target label sequence, entity extraction is performed on the text sequence corresponding to the structured output sample to obtain a candidate entity set.

[0142] In some possible embodiments, the BiLSTM module is used to convert the structured output sample into word embedding vectors, positional embedding vectors, and segmented embedding vectors, and to fuse the word embedding vectors, positional embedding vectors, and segmented embedding vectors to obtain a fused embedding vector sequence; using a multi-layer Transformer encoder, based on a self-attention mechanism, to calculate the relevance weight between any two words in the fused embedding vector sequence, and to perform feature extraction and updating layer by layer based on the relevance weight, to obtain an intermediate feature vector sequence output by the last encoder layer and encoded by multiple layers; and to perform standardization processing on the intermediate feature vector sequence to obtain a context semantic vector sequence composed of vectors corresponding to each position in the fused embedding vector sequence.

[0143] In some possible embodiments, the CRF module is used to perform a linear mapping on the bidirectional feature vector sequence using the weight matrix and bias of the linear layer to obtain the emission score of the label corresponding to each position of the bidirectional feature vector sequence; based on the emission score of the label corresponding to each position and the transition score from the label corresponding to the previous position to the label corresponding to the current position in the label transition matrix of the CRF module, the global total score of each label sequence is determined; using the Viterbi algorithm, the label sequence with the highest global total score is determined as the target label sequence, and the target label sequence is used to characterize the position and entity type of the entity in the text corresponding to the bidirectional feature vector sequence; based on the target label sequence, entity extraction is performed on the text sequence corresponding to the structured output sample to obtain a candidate entity set.

[0144] In some possible embodiments, the knowledge extraction layer 23 further includes a relation extraction module, used to construct multiple candidate entity pairs based on the candidate entity set, and filter valid entity pairs from the multiple candidate entity pairs according to preset constraints; introduce entity position markers into the valid entity pairs to obtain a marker sequence; input the marker sequence into the BERT encoder to obtain a context vector set for each word in the marker sequence, and extract the word vector set corresponding to the entity from the context vector set; generate the semantic vector of the corresponding entity by average pooling based on the word vector set of each entity; generate the fused feature vector of the corresponding entity pair based on the sentence vector of the marker sequence and the semantic vectors of the two entities in each entity pair; and use a fully connected layer to determine the prediction probability of the corresponding entity pair belonging to each preset relation type based on the fused feature vector of each entity pair, and determine the relation type with the highest prediction probability as the semantic relation type of the corresponding entity pair.

[0145] In some possible embodiments, the application layer 25 further includes a graph query module and an association path analysis module. The graph query module is used to traverse and retrieve the knowledge graph based on the current monitoring data to obtain a first graph query result. The association path analysis module is used to determine multi-hop association paths of entities based on the first graph query result, wherein the multi-hop association paths of entities include causal relationship association paths, stage association paths, and risk propagation paths.

[0146] In some possible embodiments, the application layer 25 further includes an intelligent question answering module, which is used to perform semantic parsing on the natural language question input by the user, extract question entities and relational intents; convert the question entities and relational intents into structured query statements, perform queries on the knowledge graph, obtain second graph query results; and generate and output natural language answers based on the second graph query results.

[0147] In some possible embodiments, the application layer 25 further includes a visualization module, which is used to display the entity node relationship network in the knowledge graph, highlight the causal relationship path, the stage relationship path and the risk propagation path, and support interactive viewing.

[0148] It should be understood that the phrase "one embodiment" or "an embodiment" throughout the specification means that a specific feature, structure, or characteristic related to the embodiment is included in at least one embodiment of this application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. Furthermore, these specific features, structures, or characteristics can be combined in any suitable manner in one or more embodiments. It should be understood that in the various embodiments of this application, the sequence numbers of the above-described processes do not imply a sequential order of execution; the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application. The sequence numbers of the above-described embodiments are merely descriptive and do not represent the superiority or inferiority of the embodiments.

[0149] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element.

[0150] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods, such as: multiple units or components can be combined, or integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the various components shown or discussed can be through some interfaces, and the indirect coupling or communication connection between devices or units can be electrical, mechanical, or other forms.

[0151] The units described above as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units; some or all of the units may be selected to achieve the purpose of the embodiments of this application according to actual needs. In addition, each functional unit in the embodiments of this application may be fully integrated into one processing unit, or each unit may be a separate unit, or two or more units may be integrated into one unit; the integrated unit may be implemented in hardware or in the form of hardware plus software functional units.

[0152] Alternatively, if the integrated units described above are implemented as software functional modules and sold or used as independent products, they can also be stored in a computer-readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, or the parts that contribute to related technologies, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause the device automatic test line to execute all or part of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as mobile storage devices, ROMs, magnetic disks, or optical disks.

[0153] The methods disclosed in the several method embodiments provided in this application can be arbitrarily combined to obtain new method embodiments without conflict. The features disclosed in the several method or device embodiments provided in this application can be arbitrarily combined to obtain new method embodiments or device embodiments without conflict.

[0154] The above description is merely an embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A method for early warning of spontaneous combustion of coal based on knowledge graph reasoning, characterized in that, The method includes: The raw data related to spontaneous combustion of coal is obtained from multiple sources using the data input layer. The raw data is then converted into structured records stored in the form of a key-value dictionary, and at least includes title, body, source and metadata fields. The structured records are processed by a data processing layer to perform text standardization, and a structured output sample is constructed that retains the timing of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the context of risk transmission. The structured output samples are semantically encoded and sequence modeled using a knowledge extraction layer to identify entities in the structured output samples. Valid entity pairs are constructed based on the entities and preset constraints. The semantic relationship type of the valid entity pairs is determined. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship type includes at least temporal causal relationship, risk propagation relationship, and stage evolution relationship. Based on the effective entity pairs and corresponding semantic relationship types, the knowledge extraction layer generates an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information. The initial knowledge triples are subjected to confidence-based filtering, deduplication, and conflict-based optimal fusion using a graph construction layer, followed by entity alignment and relation normalization to obtain normalized knowledge triples. The normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. The system utilizes current monitoring data of the coal spontaneous combustion site obtained at the application layer, and determines an initial risk level based on preset risk identification rules and multi-indicator coupling rules. Based on the causal relationship information of the knowledge graph, the initial risk level is corrected to obtain a target risk level. Based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, the current coal spontaneous combustion stage and risk evolution trend are determined, and corresponding recommended disposal measures are output.

2. The method according to claim 1, characterized in that, The structured records are processed using a data processing layer to perform text standardization, constructing a structured output sample that retains the time sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the contextual information of risk transmission. The data processing layer sequentially performs data cleaning and format standardization, key domain terminology mapping standardization, professional terminology normalization, text structuring processing, and traceable sample construction processing on the structured records to generate structured output samples that retain the time sequence of coal spontaneous combustion events, coal spontaneous combustion stage attributes, and risk transmission context information.

3. The method according to claim 1, characterized in that, The knowledge extraction layer includes a BERT module, a BiLSTM module, and a CRF module. It utilizes this layer to perform semantic encoding and sequence modeling on the structured output samples, identifying entities within the structured output samples, including: The BERT module is used to sequentially perform multi-dimensional embedding encoding, vector fusion, Transformer self-attention feature encoding, and feature edge transformation on the structured output sample to obtain the context semantic vector sequence corresponding to the structured output sample. The BiLSTM module is used to extract the forward feature vector sequence and the backward feature vector sequence of the context semantic vector sequence respectively. The forward feature vector sequence and the backward feature vector sequence are concatenated according to the time step dimension to obtain the bidirectional feature vector sequence. The global total score of each label sequence is determined using the linear layer and label transition matrix of the CRF module; the target label sequence is determined based on the global total score of each label sequence using the Viterbi algorithm; and entity extraction is performed on the text sequence corresponding to the structured output sample based on the target label sequence to obtain a candidate entity set.

4. The method according to claim 3, characterized in that, The BERT module is used to sequentially perform multi-dimensional embedding encoding, vector fusion, Transformer self-attention feature encoding, and feature normalization on the structured output sample to obtain the context semantic vector sequence corresponding to the structured output sample, including: The BERT module is used to convert the structured output sample into word embedding vectors, position embedding vectors and segment embedding vectors. The word embedding vectors, position embedding vectors and segment embedding vectors are then fused to obtain a fused embedding vector sequence. Using the multi-layer Transformer encoder of the BERT module, based on the self-attention mechanism, the relevance weight between any two words in the fused embedding vector sequence is calculated. Based on the relevance weight, feature extraction and updating are completed layer by layer to obtain the intermediate feature vector sequence output by the last encoder layer and encoded by multiple layers. The intermediate feature vector sequence is standardized to obtain a context semantic vector sequence composed of vectors corresponding to each position in the fused embedding vector sequence.

5. The method according to claim 3, characterized in that, The global total score of each label sequence is determined using the linear layer and label transition matrix of the CRF module; the target label sequence is determined based on the global total score of each label sequence using the Viterbi algorithm. Based on the target label sequence, entity extraction is performed on the text sequence corresponding to the structured output sample to obtain a candidate entity set, including: Using the weight matrix and bias of the linear layer of the CRF module, the bidirectional feature vector sequence is linearly mapped to obtain the emission score of the label corresponding to each position of the bidirectional feature vector sequence; Based on the emission score of the tag corresponding to each position and the transfer score from the tag corresponding to the previous position to the tag corresponding to the current position in the tag transfer matrix of the CRF module, the global total score of each tag sequence is determined. Using the Viterbi algorithm, the label sequence with the highest global total score is determined as the target label sequence, which is used to characterize the position and entity type of the entity in the text corresponding to the bidirectional feature vector sequence; Based on the target label sequence, entity extraction is performed on the text sequence corresponding to the structured output sample to obtain a candidate entity set.

6. The method according to claim 3, characterized in that, The knowledge extraction layer also includes a relation extraction module, which constructs effective entity pairs based on the entity and preset constraints; Determining the semantic relation type of the valid entity pair includes: Using the relation extraction module, multiple candidate entity pairs are constructed based on the candidate entity set, and valid entity pairs are selected from the multiple candidate entity pairs according to preset constraints; Entity location markers are introduced into the valid entity pairs to obtain a marker sequence; The labeled sequence is input into the BERT encoder of the relation extraction module to obtain the context vector set of each word in the labeled sequence, and the word vector set corresponding to the entity is extracted from the context vector set; Based on the word vector set of each entity, the semantic vector of the corresponding entity is generated by average pooling; based on the sentence vector of the labeled sequence and the semantic vectors of the two entities in each entity pair, the fused feature vector of the corresponding entity pair is generated. Using the fully connected layer of the relation extraction module, based on the fused feature vector of each entity pair, the predicted probability of the corresponding entity pair belonging to each preset relation type is determined, and the relation type with the highest predicted probability is determined as the semantic relation type of the corresponding entity pair.

7. The method according to claim 1, characterized in that, The application layer also includes a graph query module and a correlation path analysis module, and the method further includes: Using the graph query module, the knowledge graph is traversed and retrieved based on the current monitoring data to obtain the first graph query result; Using the association path analysis module, multi-hop association paths of entities are determined based on the query results of the first graph. The multi-hop association paths of entities include causal relationship association paths, stage association paths, and risk propagation paths.

8. The method according to claim 1, characterized in that, The application layer also includes an intelligent question-answering module, and the method further includes: The intelligent question-answering module is used to perform semantic parsing on the natural language questions input by the user, and to extract question entities and relational intents; The question entity and the relational intent are converted into a structured query statement, and the query is executed on the knowledge graph to obtain the second graph query result; The natural language answer is generated and output based on the query results of the second graph.

9. The method according to claim 7, characterized in that, The application layer also includes a visualization module, and the method further includes: The visualization module displays the entity node relationship network in the knowledge graph, highlights the causal relationship path, the stage relationship path, and the risk propagation path, and supports interactive viewing.

10. A coal spontaneous combustion early warning system based on knowledge graph reasoning, characterized in that, The system includes: The data input layer is used to acquire multi-source raw data related to spontaneous combustion of coal and convert the raw data into structured records stored in the form of key-value pairs and containing at least title, body, source and metadata fields; The data processing layer is used to perform text standardization processing on the structured records and construct structured output samples that retain the occurrence sequence of coal spontaneous combustion events, the attributes of coal spontaneous combustion stages, and the risk transmission context information. The knowledge extraction layer is used to perform semantic encoding and sequence modeling on the structured output samples, identify entities in the structured output samples, construct effective entity pairs based on the entities and preset constraints, and determine the semantic relationship type of the effective entity pairs. The preset constraints include distance constraints, entity type constraints, sentence constraints, and causal relationship constraints. The semantic relationship type includes at least temporal causal relationship, risk propagation relationship, and stage evolution relationship. The knowledge extraction layer is also used to generate an initial knowledge triplet containing temporal causal information, coal spontaneous combustion stage evolution information, and risk propagation information based on the effective entity pairs and corresponding semantic relationship types. The graph construction layer is used to perform confidence-based filtering, deduplication, and conflict-based optimal fusion on the initial knowledge triples, and to perform entity alignment and relation normalization to obtain normalized knowledge triples; the normalized knowledge triples are then used to construct a knowledge graph containing entity nodes and relation edges. The application layer is used to acquire current monitoring data of the coal spontaneous combustion site, determine the initial risk level based on preset risk identification rules and multi-indicator coupling rules; based on the causal relationship information of the knowledge graph, the initial risk level is corrected to obtain the target risk level; based on the target risk level, the current monitoring data, the stage association path and risk propagation path of the knowledge graph, the current coal spontaneous combustion stage and risk evolution trend are determined, and corresponding recommended disposal measures are output.