Fire-fighting alarm message multi-level pushing method and fire-fighting alarm message multi-level pushing system
Through multi-level push methods and systems, using natural language generation models and urban grid maps and other technologies, the problem of insufficient timeliness, accuracy and coverage of fire alarm information push is solved, and high-timed and accurate intelligent push is achieved. , and has high reliability and failover capabilities.
Patent Information
- Application Number
- CN202410537907.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-30
- Publication Date
- 2024-12-06
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The existing fire alarm information push technology has poor timeliness, delayed response time, insufficient precision in push range, limited coverage, lack of personalization and differentiation, and the system lacks emergency backup and switching mechanisms, resulting in failures affecting the entire push process.
Using multi-level push methods and systems, by receiving alarm signals uploaded by firefighting equipment, using natural language generation models to generate personalized push content, combining urban grid maps and GNN models to predict push ranges, using multi-channel push, and using distributed high Real-time monitoring and optimization can be achieved using architectures and attention mechanisms to ensure high reliability and failover.
It realizes intelligent push with high timeliness, high accuracy and high coverage, and can perform differentiated push according to event level and regional characteristics, ensuring that information reaches crowded areas quickly and accurately, and quickly switch and recover in case of failure.
Smart Images

Figure CN119094601A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of fire alarm, and more specifically, to a method and system for multi-level push of fire alarm messages. Background Art
[0002] Existing fire alarm information push technologies mainly include the following methods: mobile phone APP push and SMS push, radio and television scrolling subtitle push, sound and light alarms and geographic information system (GIS) push.
[0003] The above method has the following main shortcomings: poor timeliness, large response time delay, imprecise push range, limited coverage, single push content, lack of personalization and differentiation. At the same time, the existing system lacks emergency backup and switching mechanism, and once a failure occurs, it will affect the entire push process. Summary of the invention
[0004] The present invention provides a multi-level push method and system for fire alarm messages, which solve the technical problems in the related technology such as poor timeliness, large response time delay, inaccurate push range, limited coverage, single push content, lack of personalization and differentiation, and the system lacks emergency backup and switching mechanism, which will affect the entire push process in case of failure.
[0005] The present invention provides a method and system for multi-level push of fire alarm messages, comprising the following steps:
[0006] S100: receiving alarm signals uploaded from fire-fighting equipment, preliminarily classifying the received alarm signals, and determining the event level;
[0007] S200: According to the alarm signal details, a corresponding push content template is searched from the event knowledge base, and a natural language generation model is used to integrate the event details into the template to generate personalized push content;
[0008] S300: Determine the push range, map the event location to the city grid map, mark it as the event center node, input the node characteristics and topology information into the GNN model, the GNN model predicts the event impact range, and determines the push range radius R;
[0009] S400: Determine the push strategy, divide the push range into grids, and obtain a small area set a i , for each a i , calculate the area weight w i , use the attention mechanism to i Normalize to get the final weight α i , according to the final weight α i Determine each a i Push level;
[0010] S500: Multi-channel push, push event information to mobile apps, SMS, broadcasts, emergency broadcast vehicles and multiple channels, give priority to crowded areas, regardless of event level, small area collection a i Receive push information of corresponding level;
[0011] S600: Monitoring feedback and optimization, real-time monitoring of push effect data, periodic analysis and feedback, and continuous fine-tuning of GNN and attention models;
[0012] S700: Utilizes distributed high-availability architecture for continuous fine-tuning, deploys a city-level master control center and several regional control centers, where the master center sends tasks to regional centers in real time and collects feedback;
[0013] If a failure occurs, the regional center can operate independently and switch quickly. Based on the Raft protocol, high-reliability master election of the central node is achieved. Regional centers back up each other to form a ring topology and increase redundancy.
[0014] Furthermore, in step S100, it is necessary to use an NLP model to perform semantic analysis on the alarm information to determine the event level and type. The event level is divided into: highest, higher, and general.
[0015] Further, in step S200, personalized push content is generated based on the event level and type in combination with the template. c Generate model weights for the content to be learned;
[0016] Input representation:
[0017] Event vector e = [e loc , e type , e level , e casualty ], respectively encoding the location, type, level and casualties of the incident:
[0018] Encoder:
[0019] Use bidirectional GRU to obtain context features:
[0020] h t =BiGRU(e t ,h t-1 );
[0021] Get the final context vector c through the attention mechanism:
[0022]
[0023] Decoder:
[0024] Initial state 0 Use projection to obtain: s 0 =tanh(D -1 / 2AD -1 / 2H l Θ l );
[0025] When decoding, predict the probability distribution of each word:
[0026] P(w t |c,w <t )=Softmax(W s h dec,t +b s );
[0027]
[0028] in:
[0029] h t is the hidden state vector of BiGRU;
[0030] c is the context vector obtained through the attention mechanism;
[0031] α t is the attention weight;
[0032] s t is the hidden state of the decoder;
[0033] W c 、b c From the event vector e to the initial state s 0 The projection weights and biases of
[0034] W s is the weight matrix of the decoder output layer.
[0035] Further, in step S300, based on the priority queue Q p Implement hierarchical parallel processing, high-level event priority, asynchronous reliable message queue M q Ensure that push information is not lost even if a failure occurs;
[0036] Based on the priority queue Q p Implement hierarchical parallel processing, assign different priorities to the received events according to their levels, and store them in the priority queue Q p ;
[0037] The order of queue exit is: level 1 > level 2 > level 3. For the same level, the queue is exited in the order of event occurrence;
[0038] Queue element e = (level, time, info), where level is the event level, time is the occurrence time, and info is the event details;
[0039] Asynchronous reliable message queue M q Ensure that no information is lost and use reliable message queue middleware;
[0040] The push message msg generated during the event processing is not sent directly, but persisted to M q , consumers from M q Pull msg, complete the actual push, and automatically retry when an error occurs;
[0041] msg = (content, area, channel...), where content is the push content, area is the push range, and channel is the push channel;
[0042] Among them, M q It is the storage size and reliability parameter of the message queue.
[0043] Furthermore, in step S300, the hierarchical parallel processing flow is as follows:
[0044] Main thread: listen to event alarms, generate event object e and insert it into Q p ;
[0045] Worker thread pool: There are N worker threads, numbered 1→N;
[0046] Thread i executes in a loop: from Q p Take out the highest priority event e, call the GNN model to infer the event center and push range, generate a push message msg, and persist it to M q , e and info are stored in the database for feedback analysis;
[0047] Consumer thread pool: There are M consumer threads;
[0048] Thread j loop execution: from M q In the process of consuming msg, the push interface is called to send msg;
[0049] Where N is the number of working threads;
[0050] M is the number of consumer threads;
[0051] Q p The storage size of the priority queue.
[0052] Furthermore, in step S400, the push range is determined:
[0053] Construct a graph structure G = (V, E) based on the city grid, where V is the node set and E is the edge set;
[0054] Each node v∈V represents a city grid area;
[0055] The node feature vector is x i =f(p i , d i , b i ,...),in:
[0056] p i is the geographical location coordinates of node i;
[0057] d i is the population density of node i;
[0058] b i is the building distribution information of node i;
[0059] ...indicates other possible node attribute information;
[0060] Use the GCN model to capture node features and topological structure:
[0061] h l +1=σ(D -1 / 2AD -1 / 2H l Θ l )
[0062] Where 1 is the number of GCN layers;
[0063] h is the node hidden state vector;
[0064] A is the adjacency matrix, D is the degree matrix;
[0065] Θ l is the training parameter matrix of the lth layer;
[0066] σ is a nonlinear activation function;
[0067] By stacking multiple layers of GCN, the higher layers can learn patterns in a larger neighborhood, and the output h of the last layer is L And the average population density ρ of the region, predict the impact radius R of the event:
[0068] R = g(h L , ρ)
[0069] g is the machine learning model, and the input is the final node representation h L and area ρ, the output is the predicted push range radius R.
[0070] Furthermore, in step S500, the push is performed in different regions and levels, and the push range is divided into regional subsets S 1 , S 2 , ...S n , specifically:
[0071] For each region S i , calculate the weighted sum score:
[0072] w i =∑α j *x j
[0073] where x j As the feature, α j is the regional attention weight;
[0074] Based on wi value to achieve hierarchical push: w i >t 1 The push level is 1, t 2 <w i ≤t 1 Then level 2, w 1 ≤t 2 Then level 3;
[0075] Divide the push range into multiple regional subsets S 1 , S 2 , ...S n , the range can be partitioned based on gridding, administrative divisions, etc. For each regional subset Si, its weighted sum score wi is calculated:
[0076] w i =∑α j *x j
[0077] where x j For region S i The jth feature of j is the attention weight corresponding to the jth feature;
[0078] The weight αj can be learned by the attention mechanism:
[0079] α j =softmax(vT*tanh(W x x j +W q q))
[0080] Where v, W x , W q is the parameter to be learned, q is the query vector;
[0081] Implement hierarchical push based on wi value:
[0082] w i >t 1 , then to S i Push level 1 event information;
[0083] t 2 <w i ≤t 1 , then to S i Push level 2 event information;
[0084] w i ≤t 2 , then to S i Push level 3 event information;
[0085] where t 1 , t 2 is the preset threshold;
[0086] In step S500, it is also necessary to give priority to pushing to special areas, maintain a special area set U, and push U in parallel regardless of level.
[0087] Further, in step S600, feedback collection and optimization are performed to collect push effect data, and online learning is used to optimize R, θ, and W according to the push effect data. c parameter.
[0088] The present invention also proposes a fire alarm message multi-level push system, which pushes information through the aforementioned fire alarm message multi-level push method, including:
[0089] Event classification module: Use natural language processing technology to perform semantic analysis on input event information, combine it with the event knowledge base, determine the event level, and call the corresponding content generation template according to the event level;
[0090] Push time control module: set time thresholds for events at each level, monitor event processing flow, and ensure that push is completed within the specified time;
[0091] Push range determination module: construct a city grid graph structure, node representation features, use the GCN model to capture node features and topological structure, integrate other data, and use the classifier to determine the event impact center. Calculate the push radius R based on the event level, center point, and population density;
[0092] Regional push module: subdivides the push range into small areas and calculates the weight w for each area i , use the attention mechanism to push each area in a hierarchical manner;
[0093] Special area priority push module: maintains a list of key areas such as schools and hospitals. Once an incident occurs, alerts of all levels will be sent to these areas first;
[0094] Multi-channel push module: integrates multiple channels such as mobile network push, broadcast push, and local area network push, and dynamically selects the appropriate push channel combination according to the event level and regional conditions;
[0095] Feedback collection and model optimization module: establish a push effect feedback collection mechanism, analyze feedback data, and optimize push strategies through model fine-tuning / rule correction, etc.;
[0096] High-availability architecture module: Build a distributed cluster, with multiple nodes forming a push service cluster to achieve high-availability capabilities such as automatic transfer of node failures and automatic expansion and contraction.
[0097] The present invention also proposes a storage medium storing non-temporary computer-readable instructions for executing one or more steps in the aforementioned fire alarm message multi-level push method.
[0098] The beneficial effects of the present invention are:
[0099] This push system builds a highly available distributed push system architecture based on artificial intelligence technology. It can use heterogeneous data sources, such as location, population, buildings and other parameters, to accurately predict the impact of events, and perform differentiated push notifications to different areas based on the event level, thereby achieving comprehensive optimization of timeliness, accuracy and coverage. It also continuously optimizes the system through a feedback closed-loop mechanism, ultimately achieving the goal of intelligent push notifications with high timeliness, accuracy and coverage. BRIEF DESCRIPTION OF THE DRAWINGS
[0100] Figure 1 It is a flow chart of a multi-level push method for fire alarm messages proposed by the present invention;
[0101] Figure 2 It is a module structure diagram of a multi-level push system for fire alarm messages proposed by the present invention.
[0102] In the figure: 101, event classification module; 102, push time control module; 103, push scope determination module; 104, regional push module; 105, special area priority push module; 106, multi-channel push module; 107, feedback collection and model optimization module; 108, high availability architecture module. DETAILED DESCRIPTION
[0103] The subject matter described herein will now be discussed with reference to example embodiments. It should be understood that the discussion of these embodiments is only to enable those skilled in the art to better understand and implement the subject matter described herein, and the functions and arrangements of the elements discussed may be changed without departing from the scope of protection of the contents of this specification. Each example may omit, replace or add various processes or components as needed. In addition, the features described relative to some examples may also be combined in other examples.
[0104] See also Figure 1-Figure 2 As shown, a method for multi-level push of fire alarm messages includes the following steps:
[0105] S100: Receive alarm signals uploaded from fire-fighting equipment (smoke detectors, infrared sensors), perform preliminary classification on the received alarm signals, and determine the event level;
[0106] S200: According to the alarm signal details (location, type), the corresponding push content template is searched from the event knowledge base, and the event details are integrated into the template using the natural language generation model to generate personalized push content;
[0107] S300: Determine the push range (using the GNN model), map the event location to the city grid map, mark it as the event center node, input the node characteristics (location, population, building) and topology information to the GNN model, and the GNN model predicts the event impact range and determines the push range radius R;
[0108] S400: Determine the push strategy, divide the push range into grids, and obtain a small area set a i , for each a i , calculate the area weight w i (building density, population density), use the attention mechanism to w i Normalize to get the final weight α i , according to the final weight α i Determine each a i Push level (level 1 / 2 / 3 event information);
[0109] S500: Multi-channel push, push event information to multiple channels such as mobile apps, SMS, broadcasts, emergency broadcast vehicles, etc., give priority to crowded areas (schools, hospitals, etc.), regardless of the event level, small area collection a i Receive push information of corresponding level;
[0110] S600: Monitoring feedback and optimization, real-time monitoring of push effect data (reach rate, open rate), periodic analysis feedback, and continuous fine-tuning of GNN, attention model, etc.;
[0111] S700: Utilizes distributed high-availability architecture for continuous fine-tuning, deploys a city-level master control center and several regional control centers, where the master center sends tasks to regional centers in real time and collects feedback;
[0112] If a failure occurs, the regional center can operate independently and switch quickly. Based on the Raft protocol, high-reliability master election of the central node is achieved. Regional centers back up each other to form a ring topology and increase redundancy.
[0113] In step S100, the NLP model is used to perform semantic analysis on the alarm information to determine the event level and type. The event levels are divided into: highest, higher and general. Specifically:
[0114] Event Detection
[0115] Use named entity recognition (NER) models to extract key entities from alarm text, such as location, event type, etc.
[0116] Define rules or use sequence labeling models (such as BiLSTM-CRF) to identify the alarm sentence structure;
[0117] Input entities and sentence structures into a classifier (such as a BERT pre-trained language model) to determine whether it constitutes a fire incident;
[0118] Event Classification
[0119] For confirmed fire incidents, input the classifier to obtain the incident level and type;
[0120] The classifier uses a model such as a multi-layer perceptron (MLP) or BERT;
[0121] The levels are 1 (highest), 2 (higher), and 3 (average);
[0122] The classification criteria include: keywords (such as "major", "explosion", etc.), casualties, and description of the incident;
[0123] Among them, the main parameters include:
[0124] NER model parameters: dictionary size V, word vector dimension d, BiLSTM hidden layer dimension h, etc.; sentence rule or sequence labeling model parameters: labeling system, transition probability, etc.;
[0125] Classifier parameters:
[0126] MLP: number of layers L, weight of each layer W, bias b, activation function σ, etc.
[0127] BERT: number of encoder layers N, number of attention heads H, vocabulary size V, etc.
[0128] Other parameters: palabra extraction feature weight λ, event level determination threshold τ, etc. The input of the model is the alarm information text x, mainly as follows:
[0129] NER: x→y (NER annotation sequence);
[0130] Sentence analysis: (x, y) → z (sentence annotation);
[0131] Event detection: (x, y, z) → p (event or not);
[0132] Event classification: (x, y, z, p=1)→q(event level);
[0133] Through the end-to-end pipeline processing model, the event level and type can be extracted from the alarm information efficiently and accurately, laying the foundation for subsequent content generation, push scope determination and other work.
[0134] In step S200, according to the event level / type, the personalized push content is generated in combination with the template. c Generate model weights for the content to be learned;
[0135] Specifically, the Seq2Seq+Attention architecture can be used, with event details (location, type, level, casualties, etc.) as input, semantic information captured by the Encoder, and the Decoder generating corresponding push content based on the input.
[0136] Input representation:
[0137] Event vector e = [e loc , e type , e level, e casualty ], respectively coding the location, type, level and casualties of the incident:
[0138] Encoder:
[0139] Use bidirectional GRU to obtain context features:
[0140] h t =BiGRU(e t ,h t-1 )
[0141] Get the final context vector c through the attention mechanism:
[0142]
[0143] Decoder:
[0144] Initial state 0 Use projection to obtain: s 0 =tanh(D -1 / 2AD -1 / 2H l Θ l )
[0145] When decoding, predict the probability distribution of each word:
[0146] P(w t |c,w <t )=Softmax(W s h dec,t +b s )
[0147] h dec,t =GRU(E[w t-1 ],h dec,t-1 , c)
[0148] Where e is the event information vector, including e loc 、e type 、e level 、e casualty wait;
[0149] h t is the hidden state vector of BiGRU;
[0150] c is the context vector obtained through the attention mechanism;
[0151] α t is the attention weight;
[0152] s t is the hidden state of the decoder;
[0153] W c 、b c From the event vector e to the initial state s 0 The projection weights and biases of
[0154] W s is the weight matrix of the decoder output layer;
[0155] V o is the output vocabulary size.
[0156] The model will generate natural language push content that conforms to semantics and grammar based on the input event information, which can be used to replace or supplement the original fixed templates to improve the personalization and targeting of the content.
[0157] During the model training phase, the existing alarm text can be used as supervision data to minimize the loss between the generated content and the standard answer, such as the cross entropy loss:
[0158]
[0159] Through repeated training, the content generation model can continuously improve the generation quality. At the same time, the model can also be combined with the GNN model introduced earlier to directly generate push content from event data end-to-end.
[0160] In step S300, based on the priority queue Q p Implement hierarchical parallel processing, high-level event priority, asynchronous reliable message queue M q Ensure that push information is not lost even if a failure occurs;
[0161] Specifically, based on the priority queue Q p Implement hierarchical parallel processing, assign different priorities to the received events according to their levels, and store them in the priority queue Q p ;
[0162] The order of queue exit is: level 1 > level 2 > level 3. For the same level, the queue is exited in the order of event occurrence;
[0163] Queue element e = (level, time, info), where level is the event level, time is the occurrence time, and info is the event details;
[0164] Asynchronous reliable message queue M q Ensure that no information is lost and use reliable message queue middleware, such as RabbitMQ, Kafka, etc.
[0165] The push message msg generated during the event processing is not sent directly, but persisted to M q , consumers from M q Pull msg, complete the actual push, and automatically retry when an error occurs;
[0166] msg = (content, area, channel...), where content is the push content, area is the push range, and channel is the push channel;
[0167] Hierarchical parallel processing flow
[0168] Main thread: listen to event alarms, generate event object e and insert it into Q p ;
[0169] Worker thread pool: There are N worker threads, numbered 1→N;
[0170] Thread i executes in a loop: from Q p Take out the highest priority event e, call the GNN model to infer the event center and push range, generate a push message msg, and persist M q, e and info are stored in the database for feedback analysis;
[0171] Consumer thread pool: There are M consumer threads;
[0172] Thread j loop execution: from M q In the process of consuming msg, the push interface is called to send msg;
[0173] Among them, the key parameters include:
[0174] N is the number of working threads;
[0175] M is the number of consumer threads;
[0176] Q p is the storage size of the priority queue;
[0177] M q The storage size and reliability parameters (such as replication factor) of the message queue;
[0178] In step S400, the push range is determined, and a graph G=(V, E) based on the city grid is constructed, where V is the node set, E is the edge set, and the node feature vector is x i =f(p i , d i , b i , ...);
[0179] p i is the position, d i is the population density, b i For building information, etc.
[0180] GNN layer: h l +1=σ(D -1 / 2AD -1 / 2H l Θ l ), fully capture the node neighborhood information;
[0181] where Θ l is the training parameter, D is the degree matrix, and A is the adjacency matrix;
[0182] Event impact radius R = g(h L ,ρ),h L is the output of the last layer, ρ is the average population density of the region;
[0183] Specific:
[0184] Construct a graph structure G = (V, E) based on the city grid, where V is the node set and E is the edge set;
[0185] Each node v∈V represents a city grid area;
[0186] The node feature vector is x i =f(p i , d i , b i ,...),in:
[0187] pi is the geographical location coordinate of node i;
[0188] di is the population density of node i;
[0189] bi is the building distribution information of node i (building density, building type, etc.);
[0190] ...indicates other possible node attribute information (such as firefighting facilities, geographical environment, etc.);
[0191] Use the GCN model to capture node features and topological structure:
[0192] h l +1=σ(D -1 / 2AD -1 / 2H l Θ l )
[0193] Where 1 is the number of GCN layers;
[0194] h is the node hidden state vector;
[0195] A is the adjacency matrix, D is the degree matrix;
[0196] Θ l is the training parameter matrix of the first layer;
[0197] σ is a nonlinear activation function (such as ReLU);
[0198] By stacking multiple layers of GCN, the higher layers can learn patterns in a larger neighborhood, and the output h of the last layer is L L and the average population density ρ of the region, predict the impact radius R of the event:
[0199] R = g(h L , ρ)
[0200] g is a machine learning model (such as a feedforward network, etc.), and the input is the final node representation h L and area ρ, the output is the predicted push range radius R;
[0201] In step S500, push is performed in different regions and levels, and the push range is divided into regional subsets S 1 , S 2 , ...S n , specifically:
[0202] For each region Si , calculate the weighted sum score:
[0203] w i =∑α j *x j
[0204] where x j As the feature, α j is the regional attention weight;
[0205] Based on w i Value to achieve hierarchical push: w i >t 1 The push level is 1, t 2 <w i ≤t 1 Then level 2, w i ≤t 2 Then level 3;
[0206] Specifically, the push range is divided into multiple regional subsets S 1 , S 2 , ...S n , the range can be partitioned based on gridding, administrative divisions, etc. For each regional subset Si, calculate its weighted sum score w i :
[0207] w i =∑α j *x j
[0208] where x j For region S i The jth feature of , such as population density, building distribution, etc., α j is the attention weight corresponding to the jth feature;
[0209] The weight α j It can be learned by the attention mechanism:
[0210] α j =softmax(vT*tanh(W x x j +W q q))
[0211] Where v, W x , W q is the parameter to be learned, q is the query vector, which can be the event level, etc.;
[0212] According to w i Values are pushed in different levels:
[0213] w i >t 1, then to S i Push level 1 (highest level) event information;
[0214] t 2 <w i ≤t 1 , then to S i Push level 2 event information;
[0215] w i ≤t 2 , then to S i Push level 3 (lowest level) event information;
[0216] where t 1 , t 2 is the preset threshold;
[0217] In step S500, it is also necessary to give priority to special areas, maintain a special area set U (schools, hospitals, etc.), and push U in parallel regardless of level;
[0218] Special area collection U and parallel push:
[0219] Maintain a special area set U, including schools, hospitals, subway stations and other key areas with dense population;
[0220] For each region u in U i , start a push sub-process separately;
[0221] The pushed content directly uses the emergency template of level 1, regardless of the event level;
[0222] Can be executed in parallel to shorten the push delay;
[0223] The specific mathematical expression is:
[0224] The event location is (x, y), u i The center point is (x i ,y i );
[0225] Define the distance function: d(u i , (x, y)) = sqrt((x i -x) 2 +(y i -y) 2 );
[0226] For u i , if d(u i , (x, y)) <R i (R i for u i The push radius, preset parameters), then iPush level 1 content;
[0227] GNN input features
[0228] In the previous GNN model, the node feature needs to add a binary label f i :
[0229] f i =1, indicating that the node is a special area;
[0230] f i =0, indicating that the node is a normal area;
[0231] GNN can learn f during training. i The weight of , thus automatically identifying special areas;
[0232] Parallel push
[0233] The main push process follows the steps of level division and scope determination as described above:
[0234] For each u in U i , derive a subprocess and directly execute level 1 push;
[0235] Sub-processes can be run in parallel with the main process to improve timeliness;
[0236] Subprocess to u i Push to all users in the process, not limited by the scope of the main process;
[0237] The parameters are:
[0238] U: special area collection;
[0239] R i : The i-th special area u i Push radius;
[0240] In GNN, the input feature dimension is d, where f is the special region label.
[0241] In step S600, feedback collection and optimization are performed to collect push effect data, such as arrival rate, opening rate, etc., and online learning is used to optimize R, θ, and W according to the push effect data. c And other parameters;
[0242] Collect indicators such as the arrival rate d and opening rate o of each push;
[0243] Based on the feedback, key parameters are optimized online:
[0244] Push range radius R;
[0245] Push content template parameters Θ (via policy gradient methods such as REINFORCE);
[0246] Attention model parameters W a ;
[0247] Graph SAGE model parameters
[0248] Among them, R is the push range radius, Θ is the push content generation model parameter, and W a are the attention model parameters, are the Graph SAGE model parameters.
[0249] In step S700, continuous fine-tuning is performed using a distributed high-availability architecture, specifically:
[0250] Deploy a city-level master control center C and several regional control centers R 1 , R 2 , ..., where the general center C sends tasks to regional centers in real time and collects feedback;
[0251] If C fails, the regional center can operate independently and switch quickly. Based on the Raft protocol, the central node can be highly reliable to select the leader. The regional centers back up each other to form a ring topology and increase redundancy.
[0252] The Raft protocol builds a distributed high-availability cluster. Raft is a protocol for achieving distributed consistency. It ensures that there is only one leader in the entire cluster. All nodes in the cluster elect a leader through election. The leader is responsible for processing all write requests. Other nodes, as followers, are only responsible for responding to read requests and updating their own status after the new leader is elected.
[0253] Control Center C
[0254] Responsible for receiving, processing and pushing alarm information throughout the city;
[0255] Send the processed push tasks to the corresponding regional control center;
[0256] Collect feedback data from each regional center for system optimization;
[0257] Regional Control Center 1 , R 2 ,...
[0258] Each regional control center is responsible for push execution in its jurisdiction;
[0259] Receive task instructions from the main control center C;
[0260] Perform actual push operations, including region scope determination, content generation, etc.;
[0261] Feedback the push results to the master control center C;
[0262] High availability architecture
[0263] Based on the Raft protocol, a ring topology is built between regional control centers;
[0264] Based on the principle of minimum backup cost, a master control center is dynamically selected as the coordinator;
[0265] Other regional centers serve as replicas and back up data to each other to ensure data consistency;
[0266] Once the main control center C fails, it can quickly switch to one of the regional centers to serve as a new temporary main control center to take over the system.
[0267] In this architecture, the master control center C is responsible for overall scheduling, while specific push execution and download are processed in parallel by distributed regional control centers, improving the overall system throughput. The ring topology based on Raft ensures highly reliable leader selection and data backup capabilities. In case of a failure, it can quickly switch to ensure that key push services are not interrupted.
[0268] The architecture has good scalability and new regional control centers can be added as needed. Through the combination of distributed deployment and intelligent scheduling, the system architecture can achieve high-performance, high-reliability, and high-availability fire alarm push, ensuring the timeliness and comprehensive coverage of push at critical moments.
[0269] In this embodiment, a multi-level push system for fire alarm messages is also proposed, including:
[0270] Event classification module 101: uses natural language processing technology to perform semantic analysis on input event information, combines with event knowledge base, determines event level (level 1 / 2 / 3), and calls corresponding content generation template according to event level;
[0271] Push time control module 102: sets time thresholds for events at each level (e.g., 15 seconds / 30 seconds / 2 minutes), monitors the event processing flow, and ensures that push is completed within the specified time;
[0272] Push range determination module (based on GNN) 103: construct a city grid graph structure, nodes represent features (location, population, buildings, etc.), use the GCN model to capture node features and topological structure, integrate other data (weather, flow of people, etc.), classifier to determine the center of event impact, and calculate the push radius R according to the event level, center point and population density;
[0273] Regional push module (using attention) 104: subdivide the push range into small areas and calculate the weight w for each areai , use the attention mechanism to push each area in a hierarchical manner;
[0274] Special area priority push module 105: maintains a list of key areas such as schools and hospitals, and once an incident occurs, priority is given to sending alerts regardless of level to these areas;
[0275] Multi-channel push module 106: integrates multiple channels such as mobile network push, broadcast push, and local area network push, and dynamically selects a suitable push channel combination according to the event level and regional conditions;
[0276] Feedback collection and model optimization module 107: establish a push effect feedback collection mechanism (reach rate, open rate, etc.), analyze feedback data, and optimize push strategies through model fine-tuning / rule correction, etc.;
[0277] High availability architecture module 108: Build a distributed cluster, with multiple nodes forming a push service cluster to achieve high availability capabilities such as automatic transfer of node failures and automatic expansion and contraction.
[0278] Through the coordinated cooperation of these modules, the system can comprehensively leverage the advantages of models such as GNN to achieve high-efficiency, high-precision, and personalized intelligent push, and has the ability of fault tolerance and continuous optimization to meet the needs in complex environments.
[0279] At least one embodiment of the present disclosure provides a storage medium storing non-transitory computer-readable instructions for executing one or more steps in the aforementioned method for multi-level push of fire alarm messages.
[0280] The computer program may be stored / distributed on a suitable medium, such as an optical storage medium or a solid-state medium supplied together with or as part of other hardware, but may also be distributed in other forms, such as via the Internet or other wired or wireless telecommunication systems. Any reference signs in the claims should not be construed as limiting the scope.
[0281] The above describes an embodiment of the present embodiment, but the present embodiment is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present embodiment, ordinary technicians in this field can also make many forms, all of which are within the protection of the present embodiment.
Claims
1. A method and system for multi-level push of fire alarm messages, characterized in that: The following steps are involved: S100: receiving alarm signals uploaded from fire-fighting equipment, preliminarily classifying the received alarm signals, and determining the event level; S2 00: According to the alarm signal details, the corresponding push content template is queried from the event knowledge base, and the natural language generation model is used to integrate the event details into the template to generate personalized push content; S300: Determine the push range. Map the event location to the city grid map, mark it as the event center node, input the node characteristics and topology information into the GNN model, and the GNN model predicts the event impact range and determines the push range radius. ; S400: Determine the push strategy, divide the push range into grids, and obtain a set of small areas , for each , calculate the regional weight , using the attention mechanism Normalize to get the final weight , according to the final weight Determine each Push level; S5 00: Multi-channel push, push event information to mobile apps, SMS, broadcasts, emergency broadcast vehicles and multiple channels, give priority to crowded areas, regardless of event level, small area collection Receive push information of corresponding level; S600: Monitoring feedback and optimization, real-time monitoring of push effect data, periodic analysis and feedback, and continuous fine-tuning of GNN and attention models; S700: Utilizes distributed high-availability architecture for continuous fine-tuning, deploys a city-level master control center and several regional control centers, where the master center sends tasks to regional centers in real time and collects feedback; If a failure occurs, the regional center can operate independently and switch quickly. Based on the Raft protocol, high-reliability master election of the central node is achieved. Regional centers back up each other to form a ring topology and increase redundancy.
2. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S100, an NLP model is needed to perform semantic analysis on the alarm information to determine the event level and type. The event level is divided into: highest, higher, and general.
3. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S200, personalized push content is generated based on the event level and type in combination with the template. Generate model weights for the content to be learned; Input representation: Event Vector , respectively, to encode the location, type, level and casualties of the incident: Encoder: Use bidirectional GRU to obtain context features: ; Get the final context vector Through the attention mechanism: ; Decoder: Initial state Use projection to obtain: s0 = tanh(D -1 / 2AD -1 / 2H l θ l ); When decoding, predict the probability distribution of each word: ; ; in: for The hidden state vector of is the context vector obtained through the attention mechanism; is the attention weight; is the hidden state of the decoder; , is the event vector To the initial state The projection weights and biases of is the weight matrix of the decoder output layer.
4. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S300, based on the priority queue Implement hierarchical parallel processing, high-level event priority, and asynchronous reliable message queue Ensure that push information is not lost even if a failure occurs; Priority queue based Implement hierarchical parallel processing, assign different priorities to received events according to their levels, and store them in priority queues ; The order of queue exit is: level 1 > level 2 > level 3. For the same level, exit is based on the time when the event occurred; Queue Elements ,in is the event level, is the occurrence time, Details of the event; Asynchronous reliable message queue Ensure that no information is lost and use reliable message queue middleware; Push messages generated during event processing Not sent directly, but persisted to , consumers from Pull , complete the actual push, and automatically retry when an error occurs; ,in To push content, For the push range, For push channels; in, It is the storage size and reliability parameter of the message queue.
5. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S300, the hierarchical parallel processing flow is as follows: Main thread: listen to event alarms and generate event objects and insert ; Worker thread pool: There are N worker threads, numbered 1→N; Threads Loop execution: From Get the highest priority event , call the GNN model to infer the event center point and push range, and generate a push message , persisted to ,Will and Stored in database for feedback analysis; Consumer thread pool: There are M consumer threads; Threads Loop execution: From Medium consumption , call the push interface to send ; Where N is the number of working threads; M is the number of consumer threads; The storage size of the priority queue.
6. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S400, the push scope is determined: Building a city grid-based graph structure ,in is a node set, is the edge set; Each node ∈ Represents a city grid area; The node feature vector is ,in: For Node The geographic location coordinates of For Node population density; For Node Building distribution information; Indicates other possible node attribute information; Use the GCN model to capture node features and topological structure: ;; in is the number of GCN layers; is the node hidden state vector; is the adjacency matrix, is the degree matrix; is the training parameter matrix of the lth layer; is a nonlinear activation function; By stacking multiple layers of GCN, the higher layers can learn patterns in a larger neighborhood, and the output of the last layer is L and regional average population density , predict the impact radius of the event : ; is a machine learning model, and the input is the final node representation and Region , the output is the predicted push range radius .
7. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S500, push is performed in different regions and levels, and the push range is divided into regional subsets. , specifically: For each area , calculate the weighted sum score: ; in Characterized by is the regional attention weight; based on Values are pushed in different levels: The push level is 1. Then level 2, Then level 3; Divide the push range into multiple regional subsets , the range can be partitioned based on gridding, administrative divisions, etc., and for each regional subset , calculate its weighted sum score : ; in For Region The jth feature of is the attention weight corresponding to the jth feature; The weight It can be learned by the attention mechanism: ; in , , are the parameters to be learned, is the query vector; according to Values are pushed in different levels: , then to Push level 1 event information; , then to Push level 2 event information; , then to Push level 3 event information; in , is the preset threshold; In step S500, it is also necessary to give priority to the special area and maintain the special area collection. , There is no level of parallel push.
8. A method and system for multi-level push of fire alarm messages according to claim 1, characterized in that: In step S600, feedback collection and optimization are performed to collect push effect data and optimize the push effect data using online learning. , , parameter.
9. A multi-level push system for fire alarm messages, characterized in that: Information is pushed by the multi-level push method for fire alarm messages as described in any one of claims 1 to 8, including: Event classification module: Use natural language processing technology to perform semantic analysis on input event information, combine it with the event knowledge base, determine the event level, and call the corresponding content generation template according to the event level; Push time control module: set time thresholds for events at each level, monitor event processing flow, and ensure that push is completed within the specified time; Push range determination module: construct a city grid structure, node representation features, use the GCN model to capture node features and topological structure, integrate other data, classify the event impact center, and calculate the push radius based on the event level, center point and population density ; Regional push module: subdivide the push range into small areas and calculate the weight for each area , use the attention mechanism to push each area in a hierarchical manner; Special area priority push module: maintains a list of key areas such as schools and hospitals. Once an incident occurs, alerts of all levels will be sent to these areas first; Multi-channel push module: integrates multiple channels such as mobile network push, broadcast push, and local area network push, and dynamically selects the appropriate push channel combination according to the event level and regional conditions; Feedback collection and model optimization module: establish a push effect feedback collection mechanism, analyze feedback data, and optimize push strategies through model fine-tuning / rule correction, etc.; High-availability architecture module: Build a distributed cluster, with multiple nodes forming a push service cluster to achieve high-availability capabilities such as automatic transfer of node failures and automatic expansion and contraction.
10. A storage medium storing non-transitory computer-readable instructions for executing one or more steps in the multi-level push method for fire alarm messages as described in any one of claims 1 to 8.
