Intelligent generation method of safety pre-shift meeting based on job scene knowledge graph
Patent Information
- Application Number
- CN202611078417.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-20
- Publication Date
- 2026-10-13
AI Technical Summary
[0006]现有技术尚无法实现面向施工场景的结构化和场景化以及可方言播报的班前会讲稿智能生成
[0018]本发明提供了一种基于作业场景知识图谱的安全班前会智能生成方法,将班前会讲稿的生成过程自动化,大幅节省了人工撰写讲稿的时间。通过工序链驱动的因果推理和动态修正机制,使生成的讲稿内容与当班实际工序高度匹配,显著改善了安全交底的针对性。将分散的安全知识转化为可计算的三维结构的安全知识图谱,降低了对安全员个人经验的依赖,实现了安全知识的结构化沉淀与复用。
Smart Images

Figure CN122904857A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the intersection of artificial intelligence and construction safety management, and in particular to a method for intelligently generating pre-shift safety meetings based on a knowledge graph of work scenarios. Background Technology
[0002] Pre-shift meetings are a fundamental safety management system in the construction engineering field. Before each shift begins, the team leader must organize a pre-shift meeting for all workers to conduct safety and technical briefings. The standard procedure typically includes six steps: scanning QR codes for roll call, pre-shift briefing, work arrangement, briefing and training, situation exchange, and safety oath.
[0003] Safety briefing training is the core component of the pre-shift meeting, and the quality of its presentation directly determines the actual effectiveness of the safety briefing. Currently, the writing of pre-shift meeting presentations mainly relies on manual drafting by safety officers, resulting in serious content homogenization. Safety officers often use fixed templates, only changing basic information such as the date and personnel, and the presentations lack sufficient description of the risk points and preventive measures for the specific procedures during the shift.
[0004] Writing presentation scripts is too time-consuming. Safety officers need to manually write them after reviewing technical plans, construction drawings, and safety regulations, which takes up time that would otherwise be spent on on-site safety inspections. In addition, the existing manual scripting method lacks a systematic causal risk reasoning ability, and there are instances where risk warnings in pre-shift meetings deviate from the actual work content of the shift.
[0005] Frontline workers rely heavily on dialects, making the delivery of information in Mandarin speeches inefficient. Existing technical solutions primarily focus on meeting minutes and attendance management, failing to achieve automatic generation of speech content; some construction safety knowledge graph construction methods do not address how knowledge is applied to speech generation; and general-purpose language models generate safety speeches directly without domain constraints, lacking professionalism and accuracy.
[0006] Current technology is not yet able to achieve the intelligent generation of pre-shift meeting scripts that are structured and scenario-based for construction scenarios and can be broadcast in local dialects. Summary of the Invention
[0007] The main objective of this invention is to provide an intelligent method for generating safety pre-shift meetings based on a knowledge graph of work scenarios. The technical problem solved by this application is to provide an intelligent method that can automatically associate and reason with a standardized safety knowledge system and the specific work conditions of the shift, and generate structured, scenario-based, and dialect-enabled safety pre-shift meeting scripts.
[0008] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is: a method for intelligently generating safety pre-shift meetings based on a work scenario knowledge graph, the method comprising: S1. Construct a three-dimensional security knowledge graph in a graph database, storing entity node data and semantic relationship edge data between nodes; S2. Obtain work order text data through the data access interface, extract process entity data using natural language processing technology, and establish a process chain data structure with dependencies. S3. Input the process chain data structure into the causal reasoning engine, perform subgraph activation and multi-hop graph traversal in the safety knowledge graph, calculate the correction coefficient and dynamically adjust the risk level parameters to generate structured reasoning result data. S4. Map the structured reasoning result data to the segmented prompt template, call the cloud-based large language model to generate paragraph text data, and assemble and generate the pre-shift meeting speech text data through the process engine. S5. Call the speech synthesis engine to convert the pre-shift meeting speech text data into dialect digital audio files and output them to the terminal device.
[0009] In the preferred scheme, the safety knowledge graph constructed in S1 establishes a three-dimensional semantic space with operation type data as the first dimension, risk category data as the second dimension, and control measure data as the third dimension. The first dimension is divided according to the construction process hierarchy, including civil engineering, piping, electromechanical, and special process nodes; The second dimension is divided according to the safety risk classification standard, including categories such as collapse, poisoning and asphyxiation, fall from height, falling object, mechanical injury, electric shock, and fire and explosion. The third dimension is divided into four progressive levels, including technical measures, management measures, personal protective equipment, and emergency response nodes. Entity node data includes process entities, risk entities, control measure entities, regulatory and standard entities, and accident case entities; Semantic relation edge data includes triggering relationships that represent risks arising from processes, control relationships that represent measures to prevent and control risks, requirement relationships that represent necessary measures for processes, compliance relationships that represent the legal basis for measures, and similarity relationships that represent the similarity between cases and processes.
[0010] In the preferred embodiment, the process chain data structure with dependencies established in S2 includes: The named entity recognition algorithm is called to scan the work order text data and extract the process entity nodes that represent the construction process. The temporal sequence and logical precedence relationships between process entity nodes are extracted using a dependency parsing algorithm. Based on the temporal sequence and logical precedence relationships, a directed acyclic graph (DAG) data structure is generated in memory, and this DAG data structure is stored and distributed as a process chain data structure.
[0011] In the preferred embodiment, the causal reasoning engine in S3 is a computational program encapsulated based on graph traversal algorithms and rule engines; Performing subgraph activation and multi-hop graph traversal in the security knowledge graph includes: Configure trigger condition thresholds on the trigger relationship edge data between process entities and risk entities; Traverse each process node in the process chain data structure and query candidate risk entities that have triggering relationship edges with the current process node; The actual environmental parameters in the work order text data are parsed and compared with the trigger condition threshold. If the actual environmental parameters reach the trigger condition threshold, the corresponding risk entity and its associated control measure entity node are marked as active and extracted into a subgraph structure. Otherwise, the corresponding risk entity is removed from the candidate set.
[0012] In the preferred scheme, S3 also includes a historical case joint feature retrieval and matching step: Extract the features of the current process node and the activation risk features to construct a multi-dimensional joint feature vector; The vector distance calculation formula is used to obtain the cosine similarity value between the multidimensional joint feature vector and the feature vectors of each node in the accident case entity database; The case data with the highest cosine similarity scores are selected, converted into structured text, and output to the structured reasoning results data.
[0013] In the preferred scheme, the steps in S3 for calculating the correction coefficient and dynamically adjusting the risk level parameters include: Extract the weather conditions, geological conditions and surrounding environmental conditions features from the work order text data, calculate the environmental correction coefficient by multiplying the basic risk weight by the weather coefficient, geological coefficient and surrounding environmental coefficient, and then use the environmental correction coefficient to perform numerical scaling calculations on the risk level parameters of the active risk entities. Extract the proportion of newly arrived personnel from the work order text data. When the proportion of newly arrived personnel is greater than the preset alarm threshold, calculate the personnel correction coefficient and add the parameter requirement of safety education and training intensity to the corresponding control measures data through system instructions. Extract the characteristic data of construction period and continuous operation duration, calculate the time series correction coefficient, and add nighttime lighting and fatigue operation control instructions to the risk warning text by string concatenation.
[0014] In the preferred scheme, the segmented prompt template in S4 includes four independent data bodies: risk notification template, measure requirement template, emergency key point template, and case warning template. The paragraph text data generated by calling the cloud-based large language model includes: The cloud-based large language model adopts a hybrid large language model based on the Transformer architecture; The structured reasoning result data is decomposed into four independent data subsets and passed into the context of the corresponding prompt template; Using the application programming interface, text generation requests are sent to the Hunyuan Big Language Model in parallel to obtain the corresponding risk notification paragraph text, measure requirement paragraph text, emergency key point paragraph text, and case warning paragraph text. An independent verification algorithm is executed on each generated paragraph of text data. When text information is lost or parameters do not match, a retry command is triggered to resend the request.
[0015] In the preferred embodiment, the steps in S4 for assembling and generating the pre-shift meeting speech text data through the workflow engine include: The four paragraphs of text data that pass the independent verification algorithm are loaded into the memory buffer and defined as the core data block for the briefing and training. The process engine retrieves standardized text strings stored in the underlying relational database of the system, including QR code roll call, pre-shift briefing, work arrangements, situation communication, and safety oath. Following the preset process array index order, the core data blocks of the briefing and training are concatenated with standardized text strings in memory to generate a continuous and complete lecture text data stream; A comprehensive quality assessment algorithm is executed on the complete lecture text data stream. The comprehensive quality assessment algorithm includes reading the process node identifier to compare the process coverage and using regular expressions to extract key control parameters for numerical matching and verification.
[0016] In the preferred embodiment, the method runs entirely on a cloud server and includes the following steps: The graph database software and PostgreSQL relational database are packaged using Docker containerization technology and deployed on a cloud server for persistent storage of knowledge graph and system configuration data; Deploy an Nginx reverse proxy server to provide load balancing and secure access forwarding for data access interfaces; The causal reasoning engine is encapsulated as an independent microservice process and runs inside a cloud server; The terminal device transmits the check-in record and the text of the finished lecture to the server via a network transmission protocol. The system converts the transmitted data into reverse weight correction parameters and writes them into the graph database. This triggers the program to automatically update the numerical weights of the semantic relationship edges in the graph database to complete the continuous evolution loop of the model parameters.
[0017] A smart safety pre-shift meeting generation system based on a knowledge graph of work scenarios, implemented through software encapsulation and modular deployment, includes: The Docker container environment deployed on the cloud server runs a graph database instance to store a three-dimensional security knowledge graph, while a PostgreSQL database engine runs to manage user check-in and system configuration data. The Nginx reverse proxy software module, deployed at the network access layer, is used to receive job ticket text data sent by terminal devices and provide data routing and forwarding. The natural language processing module and causal reasoning engine process are encapsulated as executable programs to parse and generate process chain data structures, perform subgraph activation and calculate correction coefficients in graph databases, and output structured reasoning result data. Workflow orchestration engine software is used to map structured reasoning result data to prompt templates, call the Hunyuan Big Language Model through cloud interface to generate text, and perform string concatenation in memory to assemble a complete speech text data stream; A speech synthesis service package deployed on a media server is used to read the speech text data stream and output dialect digital audio files.
[0018] This invention provides an intelligent method for generating safety pre-shift meetings based on a work scenario knowledge graph. It automates the process of generating pre-shift meeting scripts, significantly reducing the time spent on manual script writing. Through process chain-driven causal reasoning and dynamic correction mechanisms, the generated script content is highly matched with the actual work processes of the shift, significantly improving the relevance of safety briefings. By transforming scattered safety knowledge into a computable three-dimensional safety knowledge graph, it reduces reliance on the individual experience of safety officers and achieves the structured accumulation and reuse of safety knowledge.
[0019] The system possesses dynamic adaptive capabilities, automatically calculating correction coefficients and dynamically adjusting risk level parameters based on characteristic parameters such as weather conditions, geological conditions, surrounding environmental conditions, personnel composition, and continuous working duration. This ensures the generated presentation script has a high degree of real-time adaptability. A speech synthesis engine is used to convert the pre-shift meeting presentation text into digital audio files in dialects familiar to frontline workers, effectively eliminating language barriers and improving the transmission and understanding of safety information.
[0020] By transmitting the attendance records and the text data of the lecture after the presentation to the terminal device, the system converts them into reverse weight correction parameters and writes them into the graph database. This triggers the program to automatically update the numerical weights of the semantic relationship edge data in the graph database, thus completing the continuous evolution loop of the model parameters and the continuous self-learning of the knowledge graph. Attached Figure Description
[0021] The present invention will be further described below with reference to the accompanying drawings and embodiments: Figure 1 This is the overall flowchart of the intelligent generation method of the present invention; Figure 2 This is a flowchart of the security knowledge graph construction process of this invention; Figure 3 This is a flowchart of the work order parsing and process chain construction of the present invention; Figure 4 This is the flowchart of subgraph activation and causal reasoning of the present invention; Figure 5 This is a flowchart of the dynamic risk correction and historical case matching process of this invention; Figure 6 This is a flowchart of the text generation, speech assembly, and feedback update process of this invention. Detailed Implementation
[0022] Example 1 like Figure 1 As shown, a method for intelligently generating safety pre-shift meetings based on a work scenario knowledge graph is proposed. This method includes: S1. Construct a three-dimensional security knowledge graph in a graph database, storing entity node data and semantic relationship edge data between nodes; S2. Obtain work order text data through the data access interface, extract process entity data using natural language processing technology, and establish a process chain data structure with dependencies. S3. Input the process chain data structure into the causal reasoning engine, perform subgraph activation and multi-hop graph traversal in the safety knowledge graph, calculate the correction coefficient and dynamically adjust the risk level parameters to generate structured reasoning result data. S4. Map the structured reasoning result data to the segmented prompt template, call the cloud-based large language model to generate paragraph text data, and assemble and generate the pre-shift meeting speech text data through the process engine. S5. Call the speech synthesis engine to convert the pre-shift meeting speech text data into dialect digital audio files and output them to the terminal device.
[0023] In the preferred scheme, the safety knowledge graph constructed in S1 establishes a three-dimensional semantic space with operation type data as the first dimension, risk category data as the second dimension, and control measure data as the third dimension. The first dimension is divided according to the construction process hierarchy, including civil engineering, piping, electromechanical, and special process nodes; The second dimension is divided according to the safety risk classification standard, including categories such as collapse, poisoning and asphyxiation, fall from height, falling object, mechanical injury, electric shock, and fire and explosion. The third dimension is divided into four progressive levels, including technical measures, management measures, personal protective equipment, and emergency response nodes. Entity node data includes process entities, risk entities, control measure entities, regulatory and standard entities, and accident case entities; Semantic relation edge data includes triggering relationships that represent risks arising from processes, control relationships that represent measures to prevent and control risks, requirement relationships that represent necessary measures for processes, compliance relationships that represent the legal basis for measures, and similarity relationships that represent the similarity between cases and processes.
[0024] In the preferred embodiment, the process chain data structure with dependencies established in S2 includes: The named entity recognition algorithm is called to scan the work order text data and extract the process entity nodes that represent the construction process. The temporal sequence and logical precedence relationships between process entity nodes are extracted using a dependency parsing algorithm. Based on the temporal sequence and logical precedence relationships, a directed acyclic graph (DAG) data structure is generated in memory, and this DAG data structure is stored and distributed as a process chain data structure.
[0025] In the preferred embodiment, the causal reasoning engine in S3 is a computational program encapsulated based on graph traversal algorithms and rule engines; Performing subgraph activation and multi-hop graph traversal in the security knowledge graph includes: Configure trigger condition thresholds on the trigger relationship edge data between process entities and risk entities; Traverse each process node in the process chain data structure and query candidate risk entities that have triggering relationship edges with the current process node; The actual environmental parameters in the work order text data are parsed and compared with the trigger condition threshold. If the actual environmental parameters reach the trigger condition threshold, the corresponding risk entity and its associated control measure entity node are marked as active and extracted into a subgraph structure. Otherwise, the corresponding risk entity is removed from the candidate set.
[0026] In the preferred scheme, S3 also includes a historical case joint feature retrieval and matching step: Extract the features of the current process node and the activation risk features to construct a multi-dimensional joint feature vector; The vector distance calculation formula is used to obtain the cosine similarity value between the multidimensional joint feature vector and the feature vectors of each node in the accident case entity database; The case data with the highest cosine similarity scores are selected, converted into structured text, and output to the structured reasoning results data.
[0027] In the preferred scheme, the steps in S3 for calculating the correction coefficient and dynamically adjusting the risk level parameters include: Extract the weather conditions, geological conditions and surrounding environmental conditions features from the work order text data, calculate the environmental correction coefficient by multiplying the basic risk weight by the weather coefficient, geological coefficient and surrounding environmental coefficient, and then use the environmental correction coefficient to perform numerical scaling calculations on the risk level parameters of the active risk entities. Extract the proportion of newly arrived personnel from the work order text data. When the proportion of newly arrived personnel is greater than the preset alarm threshold, calculate the personnel correction coefficient and add the parameter requirement of safety education and training intensity to the corresponding control measures data through system instructions. Extract the characteristic data of construction period and continuous operation duration, calculate the time series correction coefficient, and add nighttime lighting and fatigue operation control instructions to the risk warning text by string concatenation.
[0028] In the preferred scheme, the segmented prompt template in S4 includes four independent data bodies: risk notification template, measure requirement template, emergency key point template, and case warning template. The paragraph text data generated by calling the cloud-based large language model includes: The cloud-based large language model adopts a hybrid large language model based on the Transformer architecture; The structured reasoning result data is decomposed into four independent data subsets and passed into the context of the corresponding prompt template; Using the application programming interface, text generation requests are sent to the Hunyuan Big Language Model in parallel to obtain the corresponding risk notification paragraph text, measure requirement paragraph text, emergency key point paragraph text, and case warning paragraph text. An independent verification algorithm is executed on each generated paragraph of text data. When text information is lost or parameters do not match, a retry command is triggered to resend the request.
[0029] In the preferred embodiment, the steps in S4 for assembling and generating the pre-shift meeting speech text data through the workflow engine include: The four paragraphs of text data that pass the independent verification algorithm are loaded into the memory buffer and defined as the core data block for the briefing and training. The process engine retrieves standardized text strings stored in the underlying relational database of the system, including QR code roll call, pre-shift briefing, work arrangements, situation communication, and safety oath. Following the preset process array index order, the core data blocks of the briefing and training are concatenated with standardized text strings in memory to generate a continuous and complete lecture text data stream; A comprehensive quality assessment algorithm is executed on the complete lecture text data stream. The comprehensive quality assessment algorithm includes reading the process node identifier to compare the process coverage and using regular expressions to extract key control parameters for numerical matching and verification.
[0030] In the preferred embodiment, the method runs entirely on a cloud server and includes the following steps: The graph database software and PostgreSQL relational database are packaged using Docker containerization technology and deployed on a cloud server for persistent storage of knowledge graph and system configuration data; Deploy an Nginx reverse proxy server to provide load balancing and secure access forwarding for data access interfaces; The causal reasoning engine is encapsulated as an independent microservice process and runs inside a cloud server; The terminal device transmits the check-in record and the text of the finished lecture to the server via a network transmission protocol. The system converts the transmitted data into reverse weight correction parameters and writes them into the graph database. This triggers the program to automatically update the numerical weights of the semantic relationship edges in the graph database to complete the continuous evolution loop of the model parameters.
[0031] A smart safety pre-shift meeting generation system based on a knowledge graph of work scenarios, implemented through software encapsulation and modular deployment, includes: The Docker container environment deployed on the cloud server runs a graph database instance to store a three-dimensional security knowledge graph, while a PostgreSQL database engine runs to manage user check-in and system configuration data. The Nginx reverse proxy software module, deployed at the network access layer, is used to receive job ticket text data sent by terminal devices and provide data routing and forwarding. The natural language processing module and causal reasoning engine process are encapsulated as executable programs to parse and generate process chain data structures, perform subgraph activation and calculate correction coefficients in graph databases, and output structured reasoning result data. Workflow orchestration engine software is used to map structured reasoning result data to prompt templates, call the Hunyuan Big Language Model through cloud interface to generate text, and perform string concatenation in memory to assemble a complete speech text data stream; A speech synthesis service package deployed on a media server is used to read the speech text data stream and output dialect digital audio files.
[0032] Example 2 Further explanation in conjunction with Example 1, such as Figure 1 As shown, this method is applied to a software system consisting of a data access interface, a cloud server, a graph database, a causal reasoning engine, a text generation service, a process engine, a speech synthesis engine, and terminal devices. The data access interface is used to receive the work order text data corresponding to the current shift; the cloud server is used to complete data parsing, knowledge graph query, risk calculation, text generation, audio conversion, and result transmission; and the terminal devices are used to receive the pre-shift meeting speech text data or dialect digital audio files and display or play them.
[0033] In S1, the graph database is used to construct a three-dimensional safety knowledge graph. This safety knowledge graph does not simply store textual data; instead, it consists of a computable graph data structure composed of entity node data and semantic relationship edge data. Entity node data records information about objects such as construction procedures, safety risks, control measures, regulations and standards, and accident cases. Semantic relationship edge data records causal relationships, control relationships, dependency relationships, compliance relationships, and similarity relationships between different objects. Upon receiving a query request from the causal inference engine, the graph database can quickly return related node and path data based on node identifiers and relationship edge types, providing a machine-readable data foundation for risk identification and measure matching.
[0034] In S2, the data access interface receives work order text data. This work order text data may include fields such as construction area, construction content, work time, weather conditions, geological conditions, surrounding environmental conditions, number of workers, number of newly arrived workers, and continuous work duration. The natural language processing module performs word segmentation, part-of-speech tagging, named entity recognition, and dependency parsing on the work order text data to extract process entity data. After node mapping, process entity data generates process node identifiers. The system then constructs a process chain data structure based on the temporal sequence and logical preconditions between processes, enabling multiple construction processes to be input into the causal reasoning engine according to the actual construction order.
[0035] In S3, the causal reasoning engine reads the process chain data structure and performs subgraph activation and multi-hop graph traversal in the safety knowledge graph. Subgraph activation is used to filter risk nodes that meet the actual operating conditions from multiple candidate risk nodes associated with the current process. Multi-hop graph traversal is used to continue querying the corresponding consequence nodes, control measure nodes, regulatory standard nodes, and accident case nodes from the activated risk nodes. The causal reasoning engine calculates risk correction parameters based on weather conditions, geological conditions, surrounding environmental conditions, personnel composition data, and time series data, dynamically updates the risk level parameters, and outputs structured reasoning result data. The structured reasoning result data includes at least the process node identifier, risk node identifier, risk level parameter, risk triggering condition, control measure parameter, emergency response parameter, regulatory standard identifier, historical case identifier, and playback priority parameter.
[0036] In S4, the process engine maps structured reasoning results data to segmented prompt templates. These templates assign risk data, measure data, emergency data, and case data to different text generation tasks. The cloud-based large language model generates risk notification paragraphs, measure requirement paragraphs, emergency point paragraphs, and case warning paragraphs based on the corresponding templates and input data. The process engine then arranges and concatenates the validated paragraphs according to the standard pre-shift meeting process, forming continuous pre-shift meeting script text data. Therefore, the pre-shift meeting script text data is not directly and freely generated by a general text model, but rather uses structured reasoning results data output from a graph database as constrained input, thus maintaining the data correspondence between procedures, risks, measures, and parameters.
[0037] In S5, the speech synthesis engine reads the pre-shift meeting script text data and preset dialect type parameters, converting the text content into a dialect digital audio file. The dialect type parameters determine pronunciation rules, intonation rules, word substitution rules, and audio encoding rules. The generated dialect digital audio file is transmitted to the terminal device via the network, and the terminal device outputs the corresponding speech according to playback control commands. The terminal device can also return playback status data to the cloud server to record whether the script has finished playing, the playback duration, and any playback errors.
[0038] The three-dimensional semantic structure and entity relationship structure of the safety knowledge graph are further defined. The first dimension is operation type data, used to represent the category of construction activity. The second dimension is risk category data, used to represent the safety risks that construction activities may cause. The third dimension is control measure data, used to represent the prevention, control, and disposal measures taken to address risks. The three-dimensional semantic structure enables the establishment of stable data mapping relationships between process nodes, risk nodes, and control measure nodes. This allows the system, upon receiving a process node, to query the risk node along the trigger relationship, and then query the corresponding control measure node along the control and requirement relationships.
[0039] The work type data is hierarchically categorized into civil engineering, piping, electromechanical, and special work process nodes. Civil engineering work process nodes correspond to construction stages such as earthwork excavation, foundation pit support, formwork erection, and concrete pouring. Piping work process nodes correspond to construction stages such as pipe laying, joint connection, water tightness testing, and corrosion protection and repair. Electromechanical work process nodes correspond to construction stages such as equipment installation, equipment inspection, temporary power supply, and ventilation testing. Special work process nodes correspond to construction stages such as confined space operations, hot work, work at heights, and nighttime operations. Work process nodes at different levels can be stored using parent and child nodes to support top-down work process category retrieval.
[0040] Risk category data includes nodes for collapse, poisoning and asphyxiation, falls from height, falling objects, mechanical injuries, electric shock, and fire and explosion. Each risk category node corresponds to a risk description field, a risk consequence field, a triggering condition field, a basic risk weight field, and a risk level field. Control measure data includes nodes for technical measures, management measures, personal protective equipment (PPE), and emergency response. Technical measures nodes record engineering control information such as ventilation, support, detection, isolation, and monitoring. Management measures nodes record management control information such as work approval, personnel training, dedicated personnel supervision, and equipment inspection. PPE nodes record protection requirements such as respiratory protection, safety ropes, safety helmets, and insulating protective equipment. Emergency response nodes record response requirements such as evacuation, alarms, rescue, and on-site isolation.
[0041] Triggering relationships are used to represent processes that trigger risk entities. Control relationships are used to represent the control effect of control measures on risk entities. Requirement relationships are used to represent control measures that must be configured when a process entity is executed. Compliance relationships are used to represent the regulatory standards corresponding to control measures. Similarity relationships are used to represent the degree of association between incident / case entities and process entities. Through these relationship edges, the graph database can query risk nodes, measure nodes, regulatory nodes, and case nodes starting from process nodes, forming graph path data that can be used for computer reasoning.
[0042] This further defines the construction process of the work sequence data structure. The natural language processing module first cleans the work order text data, removing invalid symbols, duplicate spaces, and fields unrelated to the construction content. The cleaned work order text data then enters the named entity recognition algorithm. The named entity recognition algorithm identifies text fragments representing construction steps based on a trained work sequence dictionary, work sequence name features, and contextual semantic features, and outputs the recognition results as a candidate set of work sequence entity nodes.
[0043] For each candidate object in the candidate set of process entity nodes, the system matches the candidate object with the process node name, alias, and synonyms in the safety knowledge graph. Upon successful matching, the corresponding node identifier in the graph database is written as the process node identifier into the process chain data structure. If multiple candidate nodes match the same text fragment, the system can determine the target process node based on semantic matching score, contextual relevance, and the position of the work order field.
[0044] Dependency parsing algorithms are used to analyze the syntactic dependencies and temporal relationships between multiple process entity nodes in work order text data. Temporal sequence relationships can be identified by temporal connectors such as "before," "after," "after completion," "following," and "simultaneously." Logical prerequisite relationships can be identified by work constraint statements such as "detect before operation," "excavation after support completion," and "entry after ventilation approval." The system treats process entity nodes as vertices in a directed acyclic graph (DAG), and temporal sequence relationships or logical prerequisite relationships as directed edges. When process node A needs to be completed before process node B, a directed edge is established from process node A to process node B. The resulting DAG data structure reflects the execution order and dependency constraints of each process in the current shift.
[0045] The directed acyclic graph (DAG) data structure is stored in memory or a cached database and then serialized before being sent to the causal inference engine. The causal inference engine processes each process node sequentially according to the topological sorting result, ensuring that the relevant risks, measures, and environmental conditions of preceding processes are passed to subsequent process nodes. This avoids the risk omission or incorrect ordering caused by simply processing multiple unrelated processes in parallel.
[0046] The process of subgraph activation and multi-hop graph traversal in the causal inference engine is further defined. The causal inference engine consists of a graph traversal algorithm module, a rule matching module, a parameter calculation module, and a result encapsulation module. The graph traversal algorithm module queries nodes and relation edges in the graph database. The rule matching module compares the actual environmental parameters parsed from the work order text data with the trigger condition thresholds. The parameter calculation module updates the risk level parameters and control measure parameters. The result encapsulation module writes the inference path and calculation results into structured inference result data.
[0047] Each triggering relationship edge can record one or more triggering condition thresholds. These thresholds may include workspace depth thresholds, oxygen concentration thresholds, hazardous gas concentration thresholds, rainfall level thresholds, slope height thresholds, edge distance thresholds, personnel ratio thresholds, and continuous work duration thresholds. Actual environmental parameters are obtained from work order text data, on-site monitoring data, or manually entered data. The causal reasoning engine reads the triggering relationship edge corresponding to the current process node, obtains the triggering condition thresholds, and then performs numerical analysis and unit standardization on the actual environmental parameters.
[0048] When the actual environmental parameters meet the trigger threshold, the causal inference engine sets the activation status field of the corresponding risk entity node to valid and reads the associated control measure entity nodes, regulatory standard entity nodes, and accident case entity nodes. The system extracts the activated nodes and their associated edges into a subgraph structure. The subgraph structure reduces the number of visits to irrelevant nodes in subsequent inference processes, focusing risk inference calculations on the graph data range corresponding to the current operational scenario.
[0049] When the actual environmental parameters do not reach the trigger threshold, the causal inference engine removes the corresponding risk entity node from the candidate risk set and no longer writes the corresponding measure data into the structured inference result data. By comparing trigger conditions, the system can avoid outputting untargeted prompts for risk categories that do not meet the conditions and ensure that the risk prompts are consistent with the current operational status.
[0050] The system further defines the historical case joint feature retrieval and matching process. It extracts joint feature data for the current process node and activated risk nodes. Joint feature data can include process category features, risk category features, workspace features, environmental condition features, personnel composition features, and accident consequence features. The joint feature data corresponding to the current process node and activated risk nodes are arranged into a multi-dimensional joint feature vector. The first in the accident case entity database The feature data corresponding to each accident case node are arranged into an accident case feature vector. .
[0051] The joint feature vector corresponding to the current process node and the activation risk node It can be represented as .in, This represents the first element in the joint feature vector corresponding to the current process node and the activated risk node. Each feature component Indicates the characteristic component index, This represents the total number of feature components in the joint eigenvector. Feature vectors corresponding to each accident case node It can be represented as .in, Indicates the first The feature vector corresponding to the nth accident case node is the first one. Each feature component This indicates the node number of the accident case.
[0052] The system uses cosine similarity to calculate the joint feature vector of the current process node and the activated risk node. and the Feature vector of each accident case node The degree of matching between them, the cosine similarity is .in, This represents the joint feature vector of the current process node and the activated risk node, and the first... The cosine similarity values between the feature vectors corresponding to each accident case node. The larger the value, the more similar the current work scenario is to the first... The closer the historical scenarios corresponding to each accident case node, the better.
[0053] The system will assign cosine similarity values to the nodes of each accident case. The case data is arranged in descending order of importance, and the top-ranked cases are selected. The selected case data must include at least the accident type, accident details, accident consequences, direct cause, main lessons learned, and key handling points. The case data is converted into structured text data and written into the structured reasoning result data as input for the case warning template. This ensures that the case warning paragraph is relevant to the current process node and the currently activated risk node.
[0054] The system further defines the dynamic adjustment process for risk level parameters. First, it extracts weather, geological, and surrounding environmental features from the work permit text data. Weather features can include sunny weather, rainfall, strong winds, high temperatures, low temperatures, and visibility. Geological features can include soft soil geology, loose fill, rock strata, and the impact of groundwater. Surrounding environmental features can include proximity to roads, buildings, rivers, high-voltage lines, and densely populated areas. The system converts these features into corresponding coefficients and calculates environmental correction coefficients based on the basic risk weights.
[0055] Environmental correction factor according to calculate. This represents the weather coefficient, which reflects the impact of weather conditions on the level of risk. This represents a geological coefficient, used to reflect the impact of geological stability on the degree of risk. This represents the surrounding environment coefficient, used to reflect the impact of the surrounding environment on the level of risk in the construction area. The weather coefficient meets [the following criteria]. The geological coefficients meet the requirements. The surrounding environment coefficient meets the requirements. The initial value of each coefficient can be set to $1.0$. When the corresponding environmental conditions increase the safety risk, the value of the corresponding coefficient will be increased according to the rule base.
[0056] No. Dynamic risk level parameters of each activated risk entity according to calculate. Indicates the first The basic risk level parameters for each activated risk entity. Indicates the first The dynamic risk level parameters of an activated risk entity are corrected based on environmental conditions, personnel composition data, and time series data. This represents the personnel adjustment factor, used to reflect the impact of personnel composition on the level of risk. This represents the time-series correction factor, used to reflect the impact of construction period and continuous operation duration on the level of risk. This indicates that the risk entity serial number has been activated.
[0057] When the proportion of newly arrived personnel exceeds the preset alarm threshold, the system increases the personnel correction coefficient. The safety education and training intensity parameter is then written into the corresponding control measures data. This parameter can include the number of training sessions, the number of briefings, the assessment status, and the status of designated personnel on duty. This process ensures that insufficient personnel experience not only affects the risk level parameter but also simultaneously influences the generated control measures text.
[0058] When the construction period is at night or the continuous operation time exceeds the preset duration threshold, the system increases the timing correction coefficient. Furthermore, nighttime lighting control instructions and fatigue work control instructions are added to the corresponding risk warning text. Nighttime lighting control instructions may include lighting equipment inspection, lighting range confirmation, and emergency lighting preparation. Fatigue work control instructions may include work rotation, interval rest, and status confirmation of key personnel. In this way, the risk level parameters and control measure parameters can change synchronously with the actual environmental conditions of the current shift.
[0059] The process of generating paragraph text data using segmented prompt templates and cloud-based large language models is further defined. The risk notification template receives process node identifiers, risk categories, risk level parameters, risk triggering conditions, and risk consequence data, and generates paragraph text describing the risks of the current operation. The action requirement template receives control measure parameters, key control parameters, regulatory standard identifiers, and work sequence data, and generates paragraph text corresponding to operational and control requirements. The emergency response key point template receives emergency response parameters, evacuation route data, alarm requirement data, and rescue restriction data, and generates paragraph text for emergency response. The case warning template receives historical case data, accident consequence data, key lessons learned data, and key response point data, and generates warning paragraph text.
[0060] Each segmented prompt template includes input field definitions, field order constraints, text format constraints, parameter retention rules, and output prohibition rules. Input field definitions limit the data range read by the cloud-based large language model. Field order constraints limit the generation order of risk descriptions, action requirements, emergency response points, and case warnings. Text format constraints limit the paragraph structure and sentence length of the output text. Parameter retention rules ensure that oxygen concentration, operation depth, ventilation duration, testing requirements, and other key control parameters are completely written into the corresponding paragraph text. Output prohibition rules restrict the cloud-based large language model from outputting content irrelevant to the current operational scenario.
[0061] The cloud-based large language model adopts the Hunyuan large language model based on the Transformer architecture. The workflow orchestration engine decomposes the structured inference result data into four independent data subsets and writes each data subset into the context of the corresponding prompt template. Subsequently, the workflow orchestration engine sends a text generation request to the Hunyuan large language model through the application programming interface to obtain the risk notification paragraph text, the measure requirement paragraph text, the emergency key point paragraph text, and the case warning paragraph text.
[0062] An independent verification algorithm is used to verify each of the four paragraph text data. The independent verification algorithm includes at least four checks: text information loss detection, key parameter matching detection, process node matching detection, and format consistency detection. Text information loss detection determines whether the risk category, control measures, and emergency information in the structured inference result data have been written into the paragraph text. Key parameter matching detection determines whether the numerical parameters in the paragraph text are consistent with the parameter values in the structured inference result data. Process node matching detection determines whether the paragraph text corresponds to a process node in the current process chain. Format consistency detection determines whether the paragraph text meets the preset format constraints of the prompt template. When any check fails, the system generates a retry instruction and resends the request to the cloud-based large language model.
[0063] The process of assembling the pre-shift meeting script text data by the workflow engine was further defined. Risk notification paragraphs, measure requirement paragraphs, emergency response point paragraphs, and case warning paragraphs, verified by an independent algorithm, were loaded into a memory buffer and formed into a core data block for the briefing and training according to a preset field order. This core data block carries the dynamic risk information and dynamic control measures information corresponding to the current shift.
[0064] The workflow engine reads standardized text strings corresponding to QR code roll call, pre-shift briefing, work assignment, situation communication, and safety oath from the relational database. These standardized text strings can be modified based on the construction project, work team, date, work area, and personnel attendance status. Following a preset workflow array index order, the workflow engine sequentially writes the QR code roll call text string, pre-shift briefing text string, work assignment text string, core data block for briefing and training, situation communication text string, and safety oath text string into the memory buffer, and then concatenates these strings to generate a continuous and complete stream of presentation text data.
[0065] After the complete presentation script text data stream is generated, the system executes a comprehensive quality assessment algorithm. This algorithm reads the process node identifiers from the process chain data structure and retrieves the corresponding process names, risk descriptions, and measure descriptions from the complete presentation script text data stream to confirm that each process in the process chain has the corresponding content. The algorithm also uses regular expressions to extract key control parameters from the complete presentation script text data stream and performs numerical matching with these parameters in the structured inference result data. Key control parameters may include gas concentration, ventilation duration, work depth, training requirements, and protective equipment requirements. If process coverage or parameter matching does not meet preset conditions, the process engine sends the corresponding anomaly information to the segmented prompt template or data parsing module for reprocessing.
[0066] This further defines the cloud deployment method and feedback update process. Both the graph database software and the PostgreSQL relational database are packaged and deployed on cloud servers using Docker containerization technology. Docker containers provide isolated software runtime environments, enabling the graph database service, relational database service, causal reasoning microservice, workflow orchestration service, and speech synthesis service to start, stop, update, and scale independently. The graph database is used to persistently store node data, relation edge data, trigger condition thresholds, and relation edge numerical weights in the security knowledge graph. The PostgreSQL relational database is used to store user information, check-in records, system configuration data, standardized text strings, terminal device information, and playback status data.
[0067] The Nginx reverse proxy server is deployed at the network access layer. It receives job order text data, attendance records, playback status data, and other request data from terminal devices and forwards these requests to the corresponding cloud services based on the access path. The Nginx reverse proxy server can also perform load balancing for concurrent requests, control access to unauthorized requests, and return service processing results to the terminal devices.
[0068] The causal reasoning engine is encapsulated as an independent microservice process. This independent microservice process reads process nodes, risk nodes, control measure nodes, regulatory standard nodes, and accident case nodes through a graph database interface, and completes subgraph activation, risk level parameter calculation, and structured reasoning result data generation according to trigger conditions. Through this microservice deployment approach, the causal reasoning engine can run decoupled from the text generation service, speech synthesis service, and terminal interaction service to avoid a single module's malfunction affecting the data processing of other modules.
[0069] After completing check-in and audio playback, the terminal device transmits the check-in record and playback completion status back to the cloud server via network transmission protocol. The system converts the transmitted data into reverse weight correction parameters. These parameters reflect the call frequency, playback completion status, and manual confirmation status of different process nodes, risk nodes, control measure nodes, and accident case nodes during actual shifts. Based on these reverse weight correction parameters, the system updates the numerical weights corresponding to triggering relationships, control relationships, and similarity relationships in the graph database. This allows subsequent causal reasoning processes to adjust the query priority and case matching priority of relationship edges based on historical usage data, forming a continuously evolving data loop.
[0070] This paper further defines an intelligent generation system for safety pre-shift meetings based on a knowledge graph of work scenarios. The system consists of a cloud server, a network access layer software module, a natural language processing module, a causal inference engine process, a workflow orchestration engine software, a speech synthesis service package, and terminal devices. Each module transmits work order text data, process chain data structure, structured inference result data, pre-shift meeting script text data, dialect digital audio files, attendance records, and playback status data through network interfaces and internal service interfaces.
[0071] The Docker container environment is deployed on a cloud server. The graph database instance runs within this Docker container environment to store a three-dimensional security knowledge graph. The PostgreSQL database engine also runs within a Docker container environment to store user check-in data, system configuration data, standardized process text, and terminal interaction data. The graph database instance and the PostgreSQL database engine communicate via a service interface, transmitting node identifiers, user identifiers, shift identifiers, and configuration parameters, enabling graph data processing and relational data processing to run collaboratively.
[0072] The Nginx reverse proxy software module is deployed at the network access layer. It receives work order text data from terminal devices and forwards it to the natural language processing module according to the interface path. The natural language processing module parses the work order text data and generates a process chain data structure. The causal reasoning engine process reads the process chain data structure, performs subgraph activation, multi-hop graph traversal, and risk correction coefficient calculation in the graph database, and outputs structured reasoning result data.
[0073] The workflow orchestration engine software reads the structured inference result data, maps different fields to risk notification templates, measure requirement templates, emergency response templates, and case warning templates, and generates paragraph text data by calling the Hunyuan Big Language Model through a cloud interface. The workflow orchestration engine software performs independent validation and sequential concatenation on the paragraph text data to generate a complete speech script text data stream. The speech synthesis service package reads the complete speech script text data stream and dialect type parameters to generate a dialect digital audio file. The dialect digital audio file is sent to the terminal device via the terminal interaction service for playback.
[0074] Through the above system architecture, work order text data can be converted into a process chain data structure. This process chain data structure then drives risk calculation and measure matching in the safety knowledge graph, subsequently outputting pre-shift meeting speech text data and dialect digital audio files. The various software modules interact according to a unified data structure, forming a continuous data processing chain from construction site work data, risk reasoning data, text generation data, audio output data, and feedback update data.
[0075] Example 3 Further explanation is provided in conjunction with Examples 1-2. The following examples are based on... Figure 1-6 Based on the process and the confined space operation scenario of the integrated utility tunnel in the original manual, the implementation process of cloud deployment, data flow, graph reasoning, risk correction, text generation, dialect playback and feedback update has been further supplemented.
[0076] This embodiment uses the confined space operation of an integrated utility tunnel in Zone E of a municipal waterworks construction company as an example to illustrate the intelligent generation method of safety pre-shift meetings based on a knowledge graph of the work scenario. The construction area is the section between G13 and G15 of the integrated utility tunnel. The work content for the shift includes inspection of equipment inside the tunnel, anti-corrosion repair of pipelines, and testing of the ventilation system. The personnel on duty include one team leader, one grid manager, and four workers, including one newly arrived worker. The environmental information recorded in the work order includes cloudy weather, soft soil geology, tunnel depth of 8m, and historical gas detection records showing that the oxygen concentration had dropped to 19.2%. The system follows... Figure 1 The overall method flow shown includes the generation of the safety pre-shift meeting script and the output of dialect voice.
[0077] The system is deployed on a cloud server. The cloud server uses a Docker container environment to deploy the Neo4j graph database, PostgreSQL relational database, causal inference engine microservice, natural language processing service, workflow orchestration service, and speech synthesis service. The Neo4j graph database stores a three-dimensional security knowledge graph. The PostgreSQL relational database stores work order text data, user attendance records, standardized pre-shift meeting text strings, terminal device information, dialect type parameters, and playback status data. The Nginx reverse proxy module is deployed at the network access layer to receive work order text data and attendance requests uploaded by terminal devices and routes the data to the corresponding microservices based on the interface path. The terminal devices are mobile devices with WeChat mini-programs installed. These mobile devices are used to submit work orders, display pre-shift meeting scripts, play dialect digital audio files, and send back attendance records and playback status data.
[0078] like Figure 2 As shown, during the system initialization phase, construction plans, safety management systems, safety technical briefing materials, accident case data, and regulatory standards are first collected. A three-dimensional semantic space is then established based on work type data, risk category data, and control measure data. Work type data serves as the first dimension, including civil engineering, piping, electromechanical, and special work process nodes. Risk category data serves as the second dimension, including nodes for collapse, poisoning / asphyxiation, falls from height, falling objects, mechanical injuries, electric shock, and fire / explosion categories. Control measure data serves as the third dimension, including nodes for technical measures, management measures, personal protective equipment, and emergency response.
[0079] In this embodiment, the graph database includes at least the following entities: process entities, risk entities, control measure entities, regulatory and standard entities, and accident case entities. For confined space operations in integrated utility tunnels, process entities include ventilation system inspection, equipment inspection, and pipeline corrosion repair. Risk entities include risks of poisoning and asphyxiation, tunnel structural deformation, falling objects, and organic solvent hazards. Control measure entities include forced ventilation, gas detection, work approval, self-contained breathing apparatus, safety ropes, tripods, dedicated monitoring, continuous ventilation, and safety education and training. Regulatory and standard entities are used to store corresponding safety regulations, confined space operation requirements, and protection parameters. Accident case entities include accident types, consequences, direct causes, and key handling points related to sewage pipelines, integrated utility tunnels, and confined space operations.
[0080] Trigger relationships are established between process entities and risk entities to indicate that a specific process may trigger a risk when certain conditions are met. Control relationships are established between control measure entities and risk entities to indicate the mitigating effect of control measures on risks. Requirement relationships are established between process entities and control measure entities to indicate the requirements that must be met before a process is executed. Compliance relationships are established between control measure entities and regulatory standards entities to indicate the regulatory source of the measure parameters. Similarity relationships are established between accident case entities and process entities to indicate the degree of correlation between historical accident cases and the current process. After each entity node and semantic relationship edge is written into the Neo4j graph database, a three-dimensional safety knowledge graph for municipal waterworks construction scenarios is formed.
[0081] like Figure 3 As shown, after the data access interface receives the work order text data for the current shift, the natural language processing module first performs text cleaning on the work order text data, removing invalid symbols, duplicate fields, and irrelevant descriptions. Then, it calls the named entity recognition algorithm to extract the corresponding process entity nodes from the construction content, namely equipment inspection, pipeline corrosion repair, and ventilation system detection. The system then performs name matching, synonym matching, and semantic matching between the identified process entity nodes and the process nodes in the safety knowledge graph, obtaining the corresponding process node identifier.
[0082] Furthermore, the dependency parsing algorithm analyzes the process descriptions in the work order text, extracting temporal sequences and logical prerequisites. In this embodiment, ventilation system detection is a prerequisite for equipment inspection and pipeline corrosion repair. Therefore, the system establishes directed edges from ventilation system detection to equipment inspection, and also from ventilation system detection to pipeline corrosion repair. Equipment inspection and pipeline corrosion repair are written as subsequent process nodes into a directed acyclic graph data structure. This directed acyclic graph data structure is topologically sorted to form a process chain data structure and sent to the causal inference engine.
[0083] like Figure 4 As shown, after reading the process chain data structure, the causal reasoning engine sequentially traverses the process nodes corresponding to ventilation system inspection, equipment inspection, and pipeline corrosion repair. The engine queries the trigger relationship edges connecting each process node and reads the configured trigger condition thresholds within these edges. For confined space operations in integrated utility tunnels, the trigger relationship edges between the process entity and the entity at risk of poisoning or asphyxiation are configured with confined space conditions, work space depth conditions, and historical gas detection anomaly conditions. When the work order text data reveals a tunnel depth of 8m and a historical oxygen concentration of 19.2%, the system determines that the current environmental parameters have reached the trigger condition threshold corresponding to the risk of poisoning or asphyxiation.
[0084] The causal reasoning engine marks the poisoning and asphyxiation risk entity as active, and also marks the associated control measures entities such as forced ventilation, gas detection, work approval, self-contained breathing apparatus, safety ropes, tripods, and dedicated monitoring as active. The system extracts subgraph structures from the activated process entities, risk entities, and control measure entities, and performs multi-hop graph traversal along control relationships, requirement relationships, and compliance relationships to obtain a causal reasoning path consisting of process entities, risk entities, risk consequences, control measures, and regulatory standard entities.
[0085] In this embodiment, the main causal reasoning path corresponding to the risk of poisoning and asphyxiation is as follows: Confined space operations in the integrated utility tunnel trigger the risk of poisoning and asphyxiation, which may lead to oxygen deficiency, coma, and suffocation. To address this risk, a control process of ventilation first, then inspection, and finally work should be implemented. Ventilation time should be no less than 30 minutes. Oxygen concentration should be no less than 19.5%. Hydrogen sulfide concentration should be no less than 10 ppm. Personnel entering the utility tunnel should be equipped with self-contained breathing apparatus, safety ropes, and tripods. Monitoring personnel and rescue facilities should be set up at the entrance of the utility tunnel. For the pipeline corrosion repair process, the causal reasoning engine also activates the organic solvent hazard risk entity and matches it with control measures entities such as continuous ventilation and the wearing of protective equipment. For soft soil geological conditions, the system activates the utility tunnel structural deformation risk entity and writes structural deformation monitoring and work area inspection into the control measures data.
[0086] like Figure 5 As shown, the causal reasoning engine calculates environmental correction coefficients based on weather conditions, geological conditions, and surrounding environmental conditions. The environmental correction coefficients are calculated using the formula... Calculation. Among them, This is the environmental correction factor. The basic risk weight corresponding to the current risk entity. For weather coefficients, Geological coefficient, This refers to the surrounding environment coefficient. In this embodiment, the weather coefficient corresponds to cloudy weather. Take 1.0 as the geological coefficient corresponding to soft soil. Take 1.2, which is the environmental coefficient corresponding to the surrounding environment being in a normal state. The environmental correction result for the poisoning and asphyxiation risk entity and the pipe gallery structure deformation risk entity is determined by the basic risk weight and the corresponding environmental coefficient, with a value of 1.0. For the pipe gallery structure deformation risk, the system adds a 10% risk weight to the original risk weight to highlight the structural safety risk under soft soil geological conditions.
[0087] The system continues to read personnel composition data from the work order text. The proportion of newly arrived personnel is 25%, exceeding the preset alarm threshold of 20%. Therefore, the system generates a corresponding personnel correction result and adds a 20% training requirement to the safety education and training intensity parameter. This training requirement is written into the structured reasoning result data to ensure that the subsequently generated measure requirement paragraph includes information on briefings for newly arrived personnel, examination confirmation, and designated personnel for on-site supervision.
[0088] The system reads construction period and continuous operation duration characteristic data. When the work order text records nighttime operation status or continuous operation duration reaches a preset duration threshold, the system generates a time-series correction result and writes control instructions such as nighttime lighting inspection, emergency lighting preparation, work rotation, interval rest, and key personnel status confirmation into the risk warning data. In this embodiment, the time-series correction result, along with the environmental correction result and the personnel correction result, are used to dynamically adjust the risk level parameters and control measure intensity parameters of each risk entity.
[0089] During the historical case matching phase, the system extracts features of the current process node and features of activated risk entities to construct a multi-dimensional joint feature vector. The multi-dimensional joint feature vector of the current work scenario is denoted as... , No. The feature vector corresponding to each accident case entity is denoted as . The current work scenario is in its [number]th phase. Each feature component is denoted as , No. The first accident case entity Each feature component is denoted as The total number of eigencomponents of the joint eigenvector is denoted as . The system is based on the cosine similarity formula. Calculate the current job scenario and the first The similarity between entities in each accident case. For the current work scenario and the first The cosine similarity value between entities in each accident case. This refers to the entity number of the accident case. The characteristic component index, This represents the total number of characteristic components.
[0090] The system selects case data in descending order of cosine similarity scores. In this embodiment, the system selects a hydrogen sulfide poisoning accident case that is highly similar to confined space operations in sewage pipelines. This case record includes the accident cause of poisoning due to insufficient ventilation and gas detection, as well as the consequence of personnel blindly attempting rescue, leading to further harm. The system converts the accident type, consequences, key lessons learned, and handling points into structured text and writes it into the structured reasoning result data.
[0091] like Figure 6 As shown, the workflow orchestration engine reads the structured inference results data and splits it into four independent data subsets according to the risk notification template, the action requirement template, the emergency response template, and the case warning template. The risk notification template receives the current process, risk category, risk level parameters, and risk consequences data. The action requirement template receives control measure parameters, key control parameters, personnel training requirements, and regulatory and standard identifiers. The emergency response template receives evacuation requirements, alarm requirements, rescue restrictions, and emergency equipment requirements. The case warning template receives historical accident cases, accident consequences, key lessons learned, and key handling points.
[0092] The workflow orchestration engine sends text generation requests in parallel to the Hunyuan Large Language Model based on the Transformer architecture via an application programming interface (API). The Hunyuan Large Language Model generates risk notification paragraphs, measure requirement paragraphs, emergency response point paragraphs, and case warning paragraphs based on the input fields, output format constraints, parameter retention rules, and prohibition lists of each template. The risk notification paragraphs highlight the risks of poisoning and asphyxiation, structural deformation, and organic solvent hazards associated with equipment inspections, pipeline corrosion repairs, and ventilation system checks within the integrated utility tunnel. The measure requirement paragraphs specify control parameters such as mandatory ventilation for at least 30 minutes, entry only after passing gas detection, oxygen concentration not lower than 19.5%, hydrogen sulfide concentration not lower than 10 ppm, wearing self-contained breathing apparatus, safety ropes, and tripods. The emergency response point paragraphs include instructions for immediate evacuation in case of gas detector alarms, dizziness, or difficulty breathing, and prohibition of blind rescue operations by personnel without protective equipment. The case warning paragraphs highlight lessons learned from accidents where undetected or poorly ventilated confined spaces could lead to serious poisoning injuries.
[0093] After each paragraph's text is generated, the system calls an independent verification algorithm to perform field integrity checks, key parameter matching checks, process node coverage checks, and text format checks. Field integrity checks determine whether risk categories, control measures, emergency requirements, and accident case information are all written into the corresponding paragraph's text. Key parameter matching checks determine whether parameters such as 30 minutes, 19.5%, 10ppm, and 20% training intensity are consistent with the structured inference results. Process node coverage checks determine whether equipment inspections, pipeline corrosion repair, and ventilation system testing all have corresponding risk warnings and response requirements. If any check fails, the system generates a retry instruction, returns the reason for the failure to the corresponding prompt template, and then re-invokes the Hunyuan Big Language Model.
[0094] After all four paragraphs of text have passed independent validation, the workflow orchestration engine writes them into a memory buffer, forming the core data block for the pre-shift briefing and training. Subsequently, the workflow engine reads the standardized text strings corresponding to the QR code roll call, pre-shift briefing, work arrangement, situation exchange, and safety oath from the PostgreSQL relational database and concatenates them according to the array index order of the pre-shift meeting process. The concatenation order is as follows: QR code roll call, pre-shift briefing, work arrangement, core data block for pre-shift briefing and training, situation exchange, and safety oath. The system thus generates a complete pre-shift meeting script text data stream.
[0095] After the complete lecture script data stream is generated, the system executes a comprehensive quality assessment algorithm. This algorithm compares the process coverage of the lecture script data stream based on the process node identifiers in the process chain data structure. It also extracts key control parameters from the lecture script, such as ventilation duration, oxygen concentration, hydrogen sulfide concentration, training requirements, and protective equipment requirements, using regular expressions, and then performs numerical matching with the structured inference results. Once the comprehensive quality assessment is passed, the system sends the pre-shift meeting lecture script data stream to the speech synthesis service.
[0096] The speech synthesis service reads the pre-shift meeting script text data stream and the project's preset dialect type parameters. In this embodiment, the dialect type parameters are set to the Jiangsu-Zhejiang dialect mode. Based on dialect pronunciation rules, intonation rules, and audio encoding rules, the speech synthesis service converts the pre-shift meeting script text data stream into a dialect digital audio file and sends the dialect digital audio file to a WeChat mini-program terminal. The team leader can play the dialect digital audio file through the terminal device, enabling on-site workers to receive safety risk warnings, action requirements, emergency response points, and case alerts corresponding to the current work status.
[0097] After the terminal device completes the QR code check-in and plays the dialect digital audio file, it sends the check-in record, playback completion status, and corresponding script text data back to the cloud server. The cloud server generates reverse weight correction parameters based on the returned data and writes these parameters into the Neo4j graph database. The graph database updates the numerical weights corresponding to trigger relationships, control relationships, and similarity relationships based on the reverse weight correction parameters. This allows subsequent process node queries, risk node activation, control measure matching, and accident case sorting to be adjusted based on actual usage data from historical shifts. This forms a closed-loop processing procedure encompassing work order text data input, process chain construction, risk reasoning, script generation, dialect playback, and graph weight updates.
[0098] The above embodiments are merely preferred technical solutions of the present invention and should not be considered as limitations on the present invention. The scope of protection of the present invention should be limited to the technical solutions described in the claims, including equivalent substitutions of the technical features described in the claims. That is, equivalent substitutions and improvements within this scope are also within the scope of protection of the present invention.
Claims
1. A method for intelligently generating safety pre-shift meetings based on a knowledge graph of work scenarios, characterized by: The method includes: S1. Construct a three-dimensional security knowledge graph in a graph database, storing entity node data and semantic relationship edge data between nodes; S2. Obtain work order text data through the data access interface, extract process entity data using natural language processing technology, and establish a process chain data structure with dependencies. S3. Input the process chain data structure into the causal reasoning engine, perform subgraph activation and multi-hop graph traversal in the safety knowledge graph, calculate the correction coefficient and dynamically adjust the risk level parameters to generate structured reasoning result data. S4. Map the structured reasoning result data to the segmented prompt template, call the cloud-based large language model to generate paragraph text data, and assemble and generate the pre-shift meeting speech text data through the process engine. S5. Call the speech synthesis engine to convert the pre-shift meeting speech text data into dialect digital audio files and output them to the terminal device.
2. The method according to claim 1, characterized in that: The safety knowledge graph constructed in S1 establishes a three-dimensional semantic space with operation type data as the first dimension, risk category data as the second dimension, and control measure data as the third dimension. The first dimension is divided according to the construction process hierarchy, including civil engineering, piping, electromechanical, and special process nodes; The second dimension is divided according to the safety risk classification standard, including categories such as collapse, poisoning and asphyxiation, fall from height, falling object, mechanical injury, electric shock, and fire and explosion. The third dimension is divided into four progressive levels, including technical measures, management measures, personal protective equipment, and emergency response nodes. Entity node data includes process entities, risk entities, control measure entities, regulatory and standard entities, and accident case entities; Semantic relation edge data includes triggering relationships that represent risks arising from processes, control relationships that represent measures to prevent and control risks, requirement relationships that represent necessary measures for processes, compliance relationships that represent the legal basis for measures, and similarity relationships that represent the similarity between cases and processes.
3. The method according to claim 1, characterized in that: S2 Establishing a process chain data structure with dependencies includes: The named entity recognition algorithm is called to scan the work order text data and extract the process entity nodes that represent the construction process. The temporal sequence and logical precedence relationships between process entity nodes are extracted using a dependency parsing algorithm. Based on the temporal sequence and logical precedence relationships, a directed acyclic graph (DAG) data structure is generated in memory, and this DAG data structure is stored and distributed as a process chain data structure.
4. The method according to claim 1, characterized in that: S3 The causal reasoning engine is a computational program based on graph traversal algorithms and a rule engine. Performing subgraph activation and multi-hop graph traversal in the security knowledge graph includes: Configure trigger condition thresholds on the trigger relationship edge data between process entities and risk entities; Traverse each process node in the process chain data structure and query candidate risk entities that have triggering relationship edges with the current process node; The actual environmental parameters in the work order text data are parsed and compared with the trigger condition threshold. If the actual environmental parameters reach the trigger condition threshold, the corresponding risk entity and its associated control measure entity node are marked as active and extracted into a subgraph structure. Otherwise, the corresponding risk entity is removed from the candidate set.
5. The method according to claim 1, characterized in that: S3 also includes a historical case joint feature retrieval and matching step: Extract the features of the current process node and the activation risk features to construct a multi-dimensional joint feature vector; The vector distance calculation formula is used to obtain the cosine similarity value between the multidimensional joint feature vector and the feature vectors of each node in the accident case entity database; The case data with the highest cosine similarity scores are selected, converted into structured text, and output to the structured reasoning results data.
6. The method according to claim 1, characterized in that: S3 The steps for calculating correction factors and dynamically adjusting risk level parameters include: Extract the weather conditions, geological conditions and surrounding environmental conditions features from the work order text data, calculate the environmental correction coefficient by multiplying the basic risk weight by the weather coefficient, geological coefficient and surrounding environmental coefficient, and then use the environmental correction coefficient to perform numerical scaling calculations on the risk level parameters of the active risk entities. Extract the proportion of newly arrived personnel from the work order text data. When the proportion of newly arrived personnel is greater than the preset alarm threshold, calculate the personnel correction coefficient and add the parameter requirement of safety education and training intensity to the corresponding control measures data through system instructions. Extract the characteristic data of construction period and continuous operation duration, calculate the time series correction coefficient, and add nighttime lighting and fatigue operation control instructions to the risk warning text by string concatenation.
7. The method according to claim 1, characterized in that: The segmented prompt templates in S4 include four independent data units: risk notification template, measure requirement template, emergency response key point template, and case warning template. The paragraph text data generated by calling the cloud-based large language model includes: The cloud-based large language model adopts a hybrid large language model based on the Transformer architecture; The structured reasoning result data is decomposed into four independent data subsets and passed into the context of the corresponding prompt template; Using the application programming interface, text generation requests are sent to the Hunyuan Big Language Model in parallel to obtain the corresponding risk notification paragraph text, measure requirement paragraph text, emergency key point paragraph text, and case warning paragraph text. An independent verification algorithm is executed on each generated paragraph of text data. When text information is lost or parameters do not match, a retry command is triggered to resend the request.
8. The method according to claim 1, characterized in that: The steps in S4 to assemble and generate pre-shift meeting speech text data using the workflow engine include: The four paragraphs of text data that pass the independent verification algorithm are loaded into the memory buffer and defined as the core data block for the briefing and training. The process engine retrieves standardized text strings stored in the underlying relational database of the system, including QR code roll call, pre-shift briefing, work arrangements, situation communication, and safety oath. Following the preset process array index order, the core data blocks of the briefing and training are concatenated with standardized text strings in memory to generate a continuous and complete lecture text data stream; A comprehensive quality assessment algorithm is executed on the complete lecture text data stream. The comprehensive quality assessment algorithm includes reading the process node identifier to compare the process coverage and using regular expressions to extract key control parameters for numerical matching and verification.
9. The method according to claim 1, characterized in that: the method The entire process of running on a cloud server includes the following steps: The graph database software and PostgreSQL relational database are packaged using Docker containerization technology and deployed on a cloud server for persistent storage of knowledge graph and system configuration data; Deploy an Nginx reverse proxy server to provide load balancing and secure access forwarding for data access interfaces; The causal reasoning engine is encapsulated as an independent microservice process and runs inside a cloud server; The terminal device transmits the check-in record and the text of the finished lecture to the server via a network transmission protocol. The system converts the transmitted data into reverse weight correction parameters and writes them into the graph database. This triggers the program to automatically update the numerical weights of the semantic relationship edges in the graph database to complete the continuous evolution loop of the model parameters.
10. A safety pre-shift meeting intelligent generation system based on a work scenario knowledge graph, applied to the method described in any one of claims 1-9 above, characterized in that: This is achieved through software encapsulation and modular deployment, including: The Docker container environment deployed on the cloud server runs a graph database instance to store a three-dimensional security knowledge graph, while a PostgreSQL database engine runs to manage user check-in and system configuration data. The Nginx reverse proxy software module, deployed at the network access layer, is used to receive job ticket text data sent by terminal devices and provide data routing and forwarding. The natural language processing module and causal reasoning engine process are encapsulated as executable programs to parse and generate process chain data structures, perform subgraph activation and calculate correction coefficients in graph databases, and output structured reasoning result data. Workflow orchestration engine software is used to map structured reasoning result data to prompt templates, call the Hunyuan Big Language Model through cloud interface to generate text, and perform string concatenation in memory to assemble a complete speech text data stream; A speech synthesis service package deployed on a media server is used to read the speech text data stream and output dialect digital audio files.