Emergency event pre-judgment method and device based on big data model

By combining social network user emotional data and government data for feature extraction and sentiment analysis, the problem of ignoring user emotional tendencies in the existing technology is solved, the accuracy and comprehensiveness of predicting critical events is improved, and the effectiveness of government rapid response and crisis management is ensured.

CN120045916AInactive Publication Date: 2025-05-27深圳腾信百纳科技有限公司
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510133685.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-06
Publication Date
2025-05-27
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The prior art ignores the important dimension of user emotional tendency in the prediction of critical events, resulting in the limitation of the accuracy and comprehensiveness of the prediction method.

Method used

By obtaining user authorized data on social networks and data published by government agencies, perform feature extraction and sentiment analysis, combining emotional tendencies and other data to determine the probability of a critical event, and sending alerts or prompt information to government departments.

Benefits of technology

It improves the accuracy and comprehensiveness of critical incident prediction, ensures that government departments can respond quickly, and reduces the possibility and degree of harm of critical incidents.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120045916A_ABST
    Figure CN120045916A_ABST
Patent Text Reader

Abstract

The invention discloses an emergency event pre-judgment method, system and device based on a big data model and a storage medium, and relates to the field of big data processing. The method comprises the following steps: acquiring first data of a social network and second data of a government agency; inputting the first data into a preset sentiment analysis model to obtain a sentiment tendency and a sentiment change, and determining a first probability of a current emergency event according to the sentiment tendency and the sentiment change in combination with the second data; when the first probability is greater than a first threshold value, determining a first type and a first geographic position of the critical event, and sending alarm information to a government corresponding department; when the first probability is smaller than or equal to a first threshold value, obtaining a second probability of occurrence of the critical event in future preset time through a preset prediction model; and when the second probability is greater than a second threshold value, predicting a second type and a second geographic position of the critical event, and sending prompt information to a corresponding government department. By implementing the technical scheme provided by the invention, the accuracy of pre-judgment of the emergency event is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of big data processing, and specifically to a method, system, electronic device and storage medium for pre-judging critical events based on a big data model. Background Art

[0002] With the continuous development and popularization of big data technology, it has become possible to use big data models to predict critical events. This prediction method usually involves the integration and analysis of multiple data sources to achieve timely detection and response to potential critical events.

[0003] Existing technologies analyze social network data primarily based on user behavior statistics and topic trend predictions, rarely integrating this data with government data, such as meteorological and geological data, to predict critical events. Furthermore, existing technologies often overlook the crucial dimension of user sentiment when processing this data, limiting the accuracy and comprehensiveness of these prediction methods.

[0004] Therefore, how to effectively combine user emotional tendencies to improve the accuracy of critical event prejudgment has become a technical problem that needs to be solved urgently. Summary of the Invention

[0005] The present application provides a method, system, electronic device and storage medium for pre-judging critical events based on a big data model, which improves the accuracy of pre-judging critical events by combining user emotional tendencies.

[0006] In a first aspect of the present application, a method for prejudging critical events based on a big data model is provided, which is applied to an event prejudgment platform. The method comprises: Obtaining first data authorized by multiple users on social networks and second data published by multiple departments in government agencies, wherein the first data includes posts, reposts, comments, likes, and geographic location data, and the second data includes meteorological data, geological data, and infectious disease data; Extracting a first feature from the first data, inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media, and determining a first probability of a current critical event occurring based on the sentiment tendencies and mood changes in combination with the second data; When the first probability is greater than a first threshold, determining a first type and a first geographical location of the critical event, and sending an alarm message to a corresponding government department based on the first type and the first geographical location; When the first probability is less than or equal to a first threshold, extracting a second feature from the second data, and inputting the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset future time; When the second probability is greater than a second threshold, a second type and a second geographical location of the emergency event are predicted, and prompt information is sent to a corresponding government department according to the second type and the second geographical location.

[0007] By employing the above technical solution, feature extraction is performed on the first data and input into a sentiment analysis model to determine the emotional tendencies and mood changes of multiple users on social media. This helps to timely understand the public's attitudes and reactions to a particular event or topic, providing important evidence for assessing the potential and urgency of critical incidents. When the first probability, determined based on the emotional tendencies and mood changes combined with the second data, exceeds a first threshold, the first type and first geographic location of the critical incident can be quickly determined, and an alert message is sent to the relevant government department. This real-time early warning mechanism helps government departments respond quickly and take effective measures to address critical incidents. Even if the first probability is less than or equal to the first threshold, a second feature is extracted from the second data and input into a preset prediction model to determine a second probability of the critical incident occurring within a preset timeframe. When the second probability exceeds the second threshold, a second type and second geographic location of the critical incident are predicted, and a warning message is sent to the relevant government department. This predictive analysis and preventive alerts help government departments take preventive measures and prepare in advance, reducing the likelihood and severity of critical incidents. Pre-judging critical incidents using big data models provides government departments with scientific and accurate decision-making. This helps improve government decision-making efficiency, enabling them to respond more quickly and accurately to various critical incidents. Because this method utilizes user-authorized data and data published by government agencies, its legitimacy and credibility are guaranteed. Furthermore, by providing timely and accurate warnings and alerts, it helps enhance public trust and satisfaction with government agencies.

[0008] Optionally, extracting a first feature from the first data includes: Cleaning and segmenting the text data in the first data, and counting all non-repeated words in the text data to form a vocabulary; Calculating the term frequency and inverse document frequency of each word, and calculating the product of the term frequency and the inverse document frequency to obtain the median value of each word; A first intermediate vector is constructed according to the intermediate value, a final vector is constructed according to the first intermediate vector and the word embedding vector, and the final vector is used as the first feature.

[0009] By employing the above technical solution, noise, irrelevant information, and erroneous data are removed from the text, ensuring the accuracy and reliability of subsequent analysis. Word segmentation, which breaks down continuous text into individual words or phrases, is a fundamental step in natural language processing and facilitates subsequent word frequency statistics and feature extraction. By counting all non-repeating words in the text data, a vocabulary is formed, providing a standardized vocabulary set for subsequent word frequency calculation and feature extraction. The vocabulary helps capture key information in the text and excludes irrelevant words, improving the relevance and effectiveness of feature extraction. By calculating the term frequency (TF) of each word in the document and the inverse document frequency (IDF) of the entire document collection, the importance of a word in the document can be assessed. The intermediate value obtained by multiplying the two effectively represents the weight of the word and helps distinguish between keywords and non-keywords. The first intermediate vector is constructed based on the intermediate value of TF-IDF, converting the text data into a numerical vector for easier computer processing and analysis. By combining the first intermediate vector with the word embedding vector to construct the final vector, both statistical and semantic characteristics of the word are considered, improving the expressiveness and accuracy of the feature vector.

[0010] Optionally, constructing a final vector according to the first intermediate vector and the word embedding vector includes: Matching the vocabulary vector of the target word from the preset word embedding model as the word embedding vector of the target word, and aggregating the word embedding vector and the first intermediate vector into a second intermediate vector using weighted average; The second intermediate vector and the first intermediate vector are concatenated into a final vector.

[0011] By employing the above technical solution, combining a first intermediate vector based on term frequency-inverse document frequency (TF-IDF) with a word embedding vector based on a word embedding model, the final vector captures both the statistical and semantic characteristics of the text data. This helps represent text information more comprehensively and accurately, improving the performance of subsequent tasks. The word embedding vector and the first intermediate vector are aggregated into a second intermediate vector using a weighted average method. The weights of words in the final representation are adjusted based on their importance in the text. This aggregation method more accurately reflects the overall content of the text. Concatenating the second intermediate vector with the first intermediate vector to form the final vector is intuitive and easy to implement. This concatenation method also preserves all the information in the original vectors, facilitating subsequent analysis and processing. Furthermore, if further feature representation expansion is required, this can be achieved by concatenating vectors with more dimensions. By combining statistical and semantic features, the final vector more accurately represents the content and meaning of the text data. This highly expressive feature vector helps achieve better performance in subsequent tasks such as sentiment analysis and event classification. Because the final vector incorporates both statistical and semantic information, models based on it are better able to process text data from diverse domains and genres. This helps enhance the generalization ability of the model, enabling it to be applied to a wider range of scenarios and tasks.

[0012] Optionally, inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media includes: Matching the emotion label corresponding to each time point according to the first feature using the preset emotion analysis model, wherein the emotion label includes positive emotion, negative emotion, and neutral emotion, and the preset emotion analysis model includes the first feature, the emotion label, and the corresponding relationship between the first feature and the emotion label; The emotional tendency of the target user at the current moment is determined according to the emotional tag, and the emotional tags of the target user at multiple time points are integrated to form the emotional trend of the target user.

[0013] By employing the above technical solution, the preset sentiment analysis model can efficiently and accurately match the emotion label corresponding to each time point based on the first feature. This automated sentiment recognition process not only improves processing efficiency but also ensures the accuracy of sentiment classification. The sentiment labels included in the preset sentiment analysis model cover positive, negative, and neutral emotions. This detailed classification enables the event prediction platform to comprehensively capture the various emotional changes of social media users. This classification is essential and valuable for understanding and analyzing user emotional states on social media. The event prediction platform can determine the target user's current emotional tendencies based on the emotion labels, which enables real-time tracking of user emotions. In the social media environment, users' emotional states may change over time and as events unfold. Real-time tracking of these changes facilitates timely response and resolution of user needs and issues. By integrating the target user's emotion labels at multiple time points, the event prediction platform can identify user emotional trends. This trend analysis not only helps understand long-term changes in user emotions but also predicts future emotional states, supporting the development of more effective social media strategies. Based on each user's emotional tendencies and trends, the event prediction platform can develop personalized analysis and strategies for each user. This personalized approach can more accurately meet user needs and expectations, improving the relevance and effectiveness of social media services. By understanding and analyzing users' emotional tendencies and trends, social media platforms can more precisely deliver content that aligns with their interests and emotional state, thereby enhancing user interaction experience and satisfaction. Furthermore, platforms can adjust interaction strategies based on changes in user emotional states to avoid sparking dissatisfaction or negative emotions.

[0014] Optionally, determining the first probability of a current critical event occurring based on the emotional tendency and the emotional change in combination with the second data includes: Determine the first percentage of each sentiment tendency in the preset topic at the current moment, and determine the second percentage of each sentiment trend; Determining a mainstream emotional tendency based on a first emotional tendency, and determining a mainstream emotional change based on a first emotional trend, wherein the first emotional tendency and the second emotional tendency are any two emotional tendencies, a first proportion of the first emotional tendency is greater than a first proportion of the second emotional tendency, and the first emotional trend and the second emotional trend are any two emotional trends, a second proportion of the first emotional trend is greater than a second proportion of the second emotional trend; When the mainstream emotional tendency is the preset emotional tendency and the mainstream emotional change is the preset emotional change, the target geographical location is determined according to the first data, and the first probability is determined according to the data of the target geographical location in the second data.

[0015] By employing the above technical solution, the event pre-judgment platform can more accurately identify emotional changes related to critical events by determining the current proportion of each emotional tendency and trend, and identifying the prevailing emotional tendency and emotional changes. This approach takes into account the diversity and dynamic nature of user emotions on social media, improving the accuracy of critical event identification. When the prevailing emotional tendency and emotional changes meet the pre-set critical event conditions (i.e., the pre-set emotional tendency and emotional changes), the event pre-judgment platform can immediately determine the target geographic location based on primary data (such as text data) and quickly calculate the initial probability of a critical event. This rapid response capability is crucial for timely handling and responding to critical events. By combining sentiment analysis and geographic location data, the event pre-judgment platform can build a more effective early warning system. The event pre-judgment platform can issue timely warnings when a critical event occurs and provide relevant geographic location information and probability assessments, enabling relevant departments to take swift action. When a critical event occurs, the event pre-judgment platform can optimize resource allocation based on the results of the initial probability assessment. For example, during a natural disaster, the event pre-judgment platform can predict the extent of the damage based on the emotional tendencies and emotional changes in the affected area, thereby rationally allocating relief supplies and personnel. For social media users, this critical event identification method based on sentiment analysis and geolocation data can provide more personalized services and alerts. For example, when the event prediction platform identifies a possible critical event in a user's area, it can send a timely warning message to the user to help them prepare for the event.

[0016] Optionally, determining the first probability according to the data of the target geographic location in the second data includes: determining first sub-data of the target geographic location at a current moment and second sub-data at a historical moment, calculating average data of a second target sub-item in the second sub-data, and comparing the first target sub-item data in the first sub-data with the average data to determine an abnormal sub-item; The abnormal sub-items are weighted and summed to obtain the first probability.

[0017] By employing the above technical solution to determine the first sub-data (i.e., current data) and second sub-data (i.e., historical data) of the target geographic location, the event pre-judgment platform can perform precise analysis for specific regions. This approach accounts for the unique circumstances of different geographic locations, improving the accuracy and specificity of the analysis. The event pre-judgment platform calculates the average data of the second target sub-item in historical data and compares the current first target sub-item data with the average data to identify anomalous sub-items. This anomaly detection method effectively identifies anomalous data related to critical events, providing strong support for subsequent probability calculations. Weighted summation of anomalous sub-items to determine the first probability means that the event pre-judgment platform considers the contribution of different anomalous sub-items to the probability of a critical event. This weighting method allows for appropriate adjustments based on the importance and impact of anomalous sub-items, making the final calculated first probability more accurate and reliable. By analyzing the current data of the target geographic location in real time and comparing it with historical data, the event pre-judgment platform can promptly detect anomalies and calculate the first probability. This rapid response capability enables the event pre-judgment platform to quickly issue warnings when critical events occur, providing timely decision-making support for relevant departments. Based on the calculated first probability, relevant departments can optimize resource allocation according to the probability of critical events in different regions.

[0018] Optionally, inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media includes: Construct a social network graph, using users as nodes in the graph and interactions between users as edges in the graph, and calculate the sentiment weight of each edge based on the content and sentiment of the interactions between users; The propagation path is determined based on the relationship between nodes, and the trend of sentiment propagation and evolution is determined based on the sentiment weight and propagation path of the edge.

[0019] By employing the above technical solution, a social network graph is constructed that captures user interactions and calculates the sentiment weight of each edge based on the content and sentiment of these interactions. This approach enables the system to gain a deeper understanding of user emotions, rather than simply analyzing individual user expressions. By determining the propagation paths based on the relationships between nodes and combining them with the sentiment weights of the edges, the event prediction platform can analyze the paths and trends of sentiment propagation within social networks. A social network graph is a dynamic model that updates as user interactions and sentiment evolve. Therefore, the event prediction platform can track changes in user sentiment on social media in real time and promptly identify new sentiment trends and changes. By combining the social network graph with a sentiment analysis model, the event prediction platform comprehensively considers multiple factors, including user interactions, sentiment weights, and propagation paths, thereby improving the accuracy of sentiment analysis. This helps more accurately identify sentiment trends and changes related to critical incidents. By analyzing the trends of sentiment propagation and evolution, relevant departments can understand the public's emotional attitudes towards a particular event or topic and optimize crisis response strategies. For example, if public sentiment is generally negative, relevant departments can strengthen information dissemination and public opinion guidance to alleviate public sentiment and prevent further escalation. For social media users, this sentiment analysis method based on social network graphs can provide more personalized and accurate sentiment analysis and recommendation services.

[0020] In a second aspect of the present application, a critical event pre-judgment system based on a big data model is provided, comprising a collection module, an emotion module, an alarm module, a prediction module, and a prompt module, wherein: a collection module configured to obtain first data authorized by multiple users on social networks and second data published by multiple departments of government agencies, wherein the first data includes posts, reposts, comments, likes, and geographic location data, and the second data includes meteorological data, geological data, and infectious disease data; an emotion module configured to extract a first feature from the first data, input the extracted first feature into a preset emotion analysis model to obtain emotional tendencies and emotional changes of multiple users on social media, and determine a first probability of a current critical event occurring based on the emotional tendencies and emotional changes in combination with the second data; an alarm module configured to, when the first probability is greater than a first threshold, determine a first type and a first geographical location of the emergency event, and send an alarm message to a corresponding government department based on the first type and the first geographical location; a prediction module configured to, when the first probability is less than or equal to a first threshold, extract a second feature from the second data, and input the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset future time; The prompt module is configured to predict a second type and a second geographical location of the emergency event when the second probability is greater than a second threshold, and send prompt information to a corresponding government department according to the second type and the second geographical location.

[0021] In the third aspect of the present application, an electronic device is provided, including a processor, a memory, a user interface and a network interface, the memory is used to store instructions, the user interface and the network interface are both used to communicate with other devices, and the processor is used to execute the instructions stored in the memory so that the electronic device performs any of the methods described above.

[0022] In a fourth aspect of the present application, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores instructions. When the instructions are executed, any one of the methods described above is executed.

[0023] In summary, one or more technical solutions provided in the embodiments of the present application have at least the following technical effects or advantages: 1. Combining user data on social networks (posts, reposts, comments, likes, and geographic location data) with authoritative data published by multiple government departments (meteorological data, geological data, and infectious disease data), this multi-source data integration can more comprehensively and accurately reflect the current social and natural environment, thereby improving the accuracy of critical event predictions; 2. By using a pre-set sentiment analysis model to analyze the emotional tendencies and mood changes of users on social networks in real time, we can promptly detect and identify the public's concerns and worries about potential critical events. This sentiment analysis not only helps to quickly identify potential critical events, but also provides important emotional guidance for subsequent crisis response. 3. Based on the first data, determine whether there are signs of a critical incident (using the first probability judgment). If so, immediately determine the type and location of the incident and send an alert to the relevant departments. If there are no obvious signs, further use the second data to predict the possibility of a critical incident in the future (using the second probability judgment) and send a warning to the relevant departments in advance. This layered warning mechanism ensures a rapid response when a critical incident occurs, while also providing sufficient warning time before an incident occurs. 4. The entire pre-judgment process is based on big data models and preset algorithms, realizing automated decision support. This not only reduces the burden of manual data analysis, but also enables quick and accurate decision-making when critical incidents occur, thereby improving the efficiency and effectiveness of crisis response. It can identify and predict various types of critical incidents, including but not limited to natural disasters, social security incidents, public health incidents, etc. Through preset sentiment analysis models and prediction models, it can flexibly adapt to the characteristics and needs of different crisis types, providing strong support for government departments' crisis response.

[0024] 5. By predicting the types and locations of future emergencies, governments can optimize resource allocation and develop response plans in advance. This helps ensure a rapid response, minimize losses, and protect public life and property when emergencies occur. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 This is a flow chart of a method for pre-judging critical events based on a big data model disclosed in an embodiment of the present application; Figure 2 This is a module diagram of a critical event pre-judgment system based on a big data model disclosed in an embodiment of the present application; Figure 3 This is a structural diagram of an electronic device disclosed in an embodiment of the present application.

[0026] Explanation of the accompanying drawings: 201, acquisition module; 202, emotion module; 203, alarm module; 204, prediction module; 205, prompt module; 301, processor; 302, communication bus; 303, user interface; 304, network interface; 305, memory. DETAILED DESCRIPTION

[0027] In order to enable those skilled in the art to better understand the technical solutions in this specification, the technical solutions in the embodiments of this specification will be clearly and completely described below in conjunction with the drawings in the embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this application, not all of the embodiments.

[0028] In the description of the embodiments of this application, words such as "for example" or "for instance" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "for example" or "for instance" in the embodiments of this application should not be construed as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "for example" or "for instance" is intended to present the relevant concepts in a concrete manner.

[0029] In the description of the embodiments of the present application, the term "multiple" means two or more. For example, multiple systems refer to two or more systems, and multiple screen terminals refer to two or more screen terminals. In addition, the terms "first" and "second" are used for descriptive purposes only and are not to be understood as indicating or implying relative importance or implicitly indicating the indicated technical features. Thus, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized.

[0030] This embodiment discloses a critical event pre-judgment method based on a big data model, which is applied to an event pre-judgment platform. Figure 1 This is a flow chart of a method for pre-judging a critical event based on a big data model disclosed in an embodiment of the present application. Figure 1 As shown, the method includes: S110, obtaining first data authorized by multiple users on a social network and second data published by multiple government departments, wherein the first data includes postings, forwardings, comments, likes, and geographic location data, and the second data includes meteorological data, geological data, and infectious disease data; Posting is the act of users publishing original content on social networks. These posts may contain text, images, videos, and other formats, covering daily life, shared opinions, and news and current events. For emergency preparedness, posts often provide first-hand, real-time information, such as descriptions of the disaster site and eyewitness accounts of the incident. Retweeting is the act of users sharing other users' posts on their own profiles. Through reposting, information can spread rapidly on social networks, creating a wide-ranging impact. The number of reposts reflects the attention and popularity of a topic or event. During emergencies, related posts often receive a large number of reposts, becoming a key indicator of the severity and scope of the incident. Comments are user responses and discussions on posts. Through comments, users can express their opinions, emotions, and questions. During emergencies, comments often contain a wide range of emotions and mood swings, such as panic, worry, and anger. These emotional tendencies and mood swings are crucial for assessing the urgency and impact of an incident. Liking is a way for users to express their approval and support for a post. While likes themselves don't directly contain specific text or sentiment, the number of likes can reflect the popularity and attention a post or topic receives. During emergencies, the number of likes on related posts often increases rapidly, becoming a crucial indicator of the event's impact and public attention. Geolocation data refers to the geographic location information (such as latitude and longitude, city name, etc.) that users include with their posts. This data can precisely pinpoint a user's location, providing crucial spatial information for predicting emergencies. For example, during natural disasters, analyzing the geolocation data of affected areas can more accurately assess the severity and scope of the disaster.

[0031] Meteorological data refers to data on weather conditions collected, compiled, and released by meteorological departments. This data includes meteorological elements such as temperature, humidity, wind speed, and rainfall, as well as weather forecasts and meteorological disaster warnings. Meteorological data is of great value in predicting and assessing the occurrence of natural disasters such as typhoons, rainstorms, and droughts. Geological data refers to data on geophysics, geochemistry, and geological structure collected, compiled, and released by geological departments. This data, including earthquake monitoring data and geological hazard assessment data, is of great value in predicting and assessing the occurrence of geological disasters such as earthquakes, landslides, and mudslides. Infectious disease data refers to data on infectious disease outbreaks collected, compiled, and released by health departments. This data includes information such as the number of cases, epidemic distribution, and transmission routes, and is of great value in predicting and assessing the development trend and severity of infectious disease outbreaks. During public health events, infectious disease data is a crucial basis for assessing the severity of the outbreak and formulating prevention and control measures.

[0032] S120: Extract a first feature from the first data, input the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on the social media, and determine a first probability of a current critical event occurring based on the sentiment tendencies and mood changes in combination with the second data; On social networks, user-generated primary data (such as posts, reposts, comments, and likes) typically contains large amounts of text, images, and metadata. To extract features useful for critical incident assessment from this data, primary feature extraction is necessary. Both text feature extraction and metadata feature extraction can be performed.

[0033] Text feature extraction: Keyword extraction: Natural language processing technology is used to extract keywords or phrases from the text. These keywords are often related to the topic of the critical incident.

[0034] Sentiment analysis features: Sentiment analysis algorithms, such as machine learning-based sentiment classifiers or deep learning models, are used to extract the emotional tendency (such as positive, negative, and neutral) and emotional intensity (such as strong, average, and weak) in text.

[0035] Topic modeling: Using topic models such as LDA (Latent Dirichlet Allocation) to identify different topics or themes from the text. These topics may be related to different critical incidents.

[0036] Metadata feature extraction: Geographic location features: Extract geographic location information from user posts, such as latitude and longitude, city name, etc. This geographic location information can help determine the specific area where the critical incident occurred.

[0037] Time features: Extract the time information of the post, such as date, timestamp, etc. Time features can help analyze the development trend and evolution of critical events.

[0038] User behavior characteristics: such as the number of reposts, comments, likes, etc. These user behavior characteristics can reflect the user's attention and participation in a topic or event.

[0039] The extracted primary features are input into a pre-set sentiment analysis model. This model is typically built using machine learning or deep learning, and has been trained and optimized using a large amount of labeled data. The model's function is to analyze and predict the sentiment tendencies and emotional changes of multiple users on social media based on the input features. The sentiment analysis model outputs the sentiment tendencies (e.g., positive, negative, neutral) and emotional changes (e.g., anger, worry, calm, etc.) for each user or post. These sentiment tendencies and emotional changes reflect the user's overall attitude and emotional state towards a topic or event. After obtaining the user's sentiment tendencies and emotional changes, the system combines this information with secondary data released by government agencies (e.g., meteorological data, geological data, and infectious disease data). By analyzing the correlation and consistency between user sentiment and this authoritative data, the event pre-judgment platform can determine whether a critical event has occurred and calculate the primary probability of a critical event occurring. For example, if users' sentiment tendencies generally indicate worry and panic, and these emotional changes align with meteorological disaster warnings or infectious disease epidemic data released by government agencies, the event pre-judgment platform can determine the possibility of a critical situation related to these events and assign a corresponding primary probability value. This probability value can help the government and relevant departments quickly understand the severity and urgency of the current situation and take appropriate countermeasures. It can also be used to weight the sum of sentiment, emotional changes, and secondary data to address the problem of delayed data updates from relevant government departments.

[0040] Optionally, extracting a first feature from the first data includes: Cleaning and segmenting the text data in the first data, and counting all non-repeated words in the text data to form a vocabulary; Calculating the term frequency and inverse document frequency of each word, and calculating the product of the term frequency and the inverse document frequency to obtain the median value of each word; A first intermediate vector is constructed according to the intermediate value, a final vector is constructed according to the first intermediate vector and the word embedding vector, and the final vector is used as the first feature.

[0041] Clean the text data collected from social networks to remove noisy data such as HTML tags, URL links, special characters, stop words (such as commonly used but meaningless words like "de", "le", etc.), and duplicate or irrelevant text content. The purpose of this step is to improve the efficiency and accuracy of subsequent text processing. Perform word segmentation on the cleaned text. Word segmentation is the process of splitting continuous text into individual word units. In Chinese text, there are no obvious delimiters (such as spaces) between words, so word segmentation algorithms (such as rule-based word segmentation, statistic-based word segmentation, or a combination of both) need to be used to identify the boundaries of words. After word segmentation, count all the non-repeated words in the text data and combine them into a vocabulary. This vocabulary contains all the individual word units that appear in the text data.

[0042] Term Frequency (TF): Term Frequency refers to the frequency of a word appearing in a given document. Usually, Term Frequency is obtained by calculating the number of times a word appears in the document and dividing it by the total number of words in the document. Term Frequency reflects the importance of a word in the document. The more times a word appears in the document, the higher its importance. Inverse Document Frequency (IDF): Inverse Document Frequency is a measure of the importance of a word in the entire document set. It is obtained by calculating the ratio of the number of documents containing the word in the document set to the total number of documents and taking the logarithm of its reciprocal. Inverse Document Frequency reflects the universality or rarity of a word in the entire document set. The fewer documents a word appears in, the higher its Inverse Document Frequency, indicating that the word is more representative or unique. Calculate the TF-IDF value: Multiply the Term Frequency and the Inverse Document Frequency to obtain the TF-IDF value for each word. The TF-IDF value comprehensively considers the importance of a word in the document and its representativeness in the entire document set, and is a commonly used feature extraction method in text processing.

[0043] Based on the calculated TF-IDF value, a first intermediate vector can be constructed for each document. The dimensionality of the first intermediate vector is the same as the vocabulary size, with each dimension corresponding to a word in the vocabulary. The value of the first intermediate vector is the TF-IDF value of that word in the document. This allows each document to be represented by a high-dimensional vector, whose elements reflect the importance of each word in the document. To improve the richness and accuracy of the feature representation, the first intermediate vector can be combined with pre-trained word embedding vectors (such as Word2Vec and GloVe). Word embedding vectors are obtained by training on large amounts of text data. Each word is mapped into a low-dimensional real vector space, and the distance between vectors reflects the semantic similarity between words. By weighting or concatenating the first intermediate vector with the word embedding vector, a final vector containing both TF-IDF and semantic information can be obtained as the first feature. This final vector can better capture the key information and semantic structure in the text data, providing an effective feature representation for subsequent tasks such as sentiment analysis and topic identification.

[0044] Text data cleaning effectively removes noise and irrelevant information, improving data quality and accuracy. Word segmentation breaks continuous text into independent word units, providing a foundation for subsequent feature extraction and text analysis. All unique words in the text data are counted to form a vocabulary. This vocabulary provides a unified index and reference for subsequent vectorization and feature extraction, ensuring consistency and comparability of text data. By calculating the term frequency (TF) and inverse document frequency (IDF) of each word, and then calculating the TF-IDF value, we can effectively assess the importance of each word in a specific document and its uniqueness within the entire document collection. This method helps highlight key information and downplay the weight of common words, thereby more accurately reflecting the document's topic and content. The first intermediate vector constructed based on the TF-IDF value represents the document in a mathematical manner, making previously unstructured text data computable and comparable. This vectorized representation facilitates subsequent data analysis and machine learning algorithms. Word embedding vectors, derived through extensive text training, capture the semantic relationships between words. Combining the first intermediate vector with the word embedding vector further enriches the text's feature representation, ensuring that the final vector not only includes word statistical information (such as TF-IDF values) but also incorporates word semantics. This combination makes text features more comprehensive and in-depth, helping to improve the accuracy and performance of subsequent tasks such as sentiment analysis and text classification.

[0045] Optionally, constructing a final vector according to the first intermediate vector and the word embedding vector includes: Matching the vocabulary vector of the target word from the preset word embedding model as the word embedding vector of the target word, and aggregating the word embedding vector and the first intermediate vector into a second intermediate vector using weighted average; The second intermediate vector and the first intermediate vector are concatenated into a final vector.

[0046] Pre-defined word embedding models (such as Word2Vec and GloVe) have been trained using large amounts of text data and store word vectors (also called word embeddings) for each word. These embeddings capture the semantic relationships between words and map each word to a point in a high-dimensional space. For each word in the first data, the corresponding embedding vector must be found in the pre-defined word embedding model. If a word does not exist in the embedding model (i.e., Out-Of-Vocabulary), it can be ignored or represented using a default vector (such as a zero vector or a random vector). After obtaining the word embedding vectors for each word, they need to be aggregated with the first intermediate vector. Since the first intermediate vector is based on the TF-IDF value, it reflects the importance and uniqueness of the word in the document. Therefore, a simple and effective method is to use a weighted average to aggregate the word embedding vectors. After obtaining the weighted average word embedding vector (the second intermediate vector), it is concatenated with the first intermediate vector to form the final vector. The concatenation operation involves joining the two vectors end to end to form a longer vector. The final vector is the sum of the dimensions of the first and second intermediate vectors. It contains both statistical information based on TF-IDF values and semantic information based on word embeddings, providing a richer feature representation for subsequent text analysis or machine learning tasks.

[0047] By combining TF-IDF values with word embeddings, the final vector contains both document frequency statistics (TF-IDF) and word semantic information (word embeddings). This combination enriches and comprehensively represents text features. TF-IDF values reflect the importance and uniqueness of a word in a document, while word embeddings capture the semantic relationships between words. Combining the two complements each other, improving the accuracy and effectiveness of text feature representation. Because the final vector incorporates word embeddings, the model can better understand the semantic meaning of words when processing text, thereby improving performance in tasks such as text classification, sentiment analysis, and topic identification. TF-IDF values place a lower weight on common but meaningless words (such as stop words), while word embeddings capture the semantic information of these words. Combining the two reduces the impact of noise on model performance. Because word embedding models are trained on large amounts of text data, they are adaptable to text data from diverse domains. Combining TF-IDF values with word embeddings allows for convenient application to text processing tasks in diverse domains. As new text data becomes available, word embedding models can be continuously updated and expanded to capture more semantic information. This flexibility makes the text feature representation method based on TF-IDF and word embedding vectors more scalable. The weighted averaging and concatenation operations are both efficient computational procedures that can quickly combine TF-IDF values and word embedding vectors into the final vector. This efficiency enables this method to handle large amounts of text data and meet the needs of real-time processing.

[0048] Optionally, inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media includes: Matching the emotion label corresponding to each time point according to the first feature using the preset emotion analysis model, wherein the emotion label includes positive emotion, negative emotion, and neutral emotion, and the preset emotion analysis model includes the first feature, the emotion label, and the corresponding relationship between the first feature and the emotion label; The emotional tendency of the target user at the current moment is determined according to the emotional tag, and the emotional tags of the target user at multiple time points are integrated to form the emotional trend of the target user.

[0049] A pre-trained sentiment analysis model is a pre-trained machine learning or deep learning model that accepts text features as input and outputs corresponding sentiment labels. In this scenario, the model has already learned the correspondence between first features (such as words, phrases, or sentences in the text) and sentiment labels (such as positive, negative, and neutral). The extracted first features (such as the content of a social media post, comment, or message) are input into the pre-trained sentiment analysis model. Based on the input first features, the pre-trained sentiment analysis model uses internally learned weights and parameters to calculate the corresponding sentiment label for each time point. These sentiment labels typically include positive emotions (such as happiness and satisfaction), negative emotions (such as anger and sadness), and neutral emotions (such as indifference and no emotion). For each target user, the pre-trained sentiment analysis model outputs one or more sentiment labels based on the input features at the current time point. These labels represent the user's emotional inclination at that moment. In addition to the sentiment labels, the model may also provide a confidence score for each label, indicating the model's confidence in the predicted label. This helps determine the reliability of the sentiment in subsequent analysis. To understand the target user's emotional trends, the user's sentiment labels at different time points are aggregated. This typically involves arranging sentiment tags in chronological order to form a time series. By observing this time series, patterns in user sentiment can be identified. For example, a user might display consistently positive sentiment for a period of time and then suddenly shift to negative, or their sentiment might fluctuate between positive and negative. To better understand and demonstrate user sentiment trends, time series data can be presented using charts, graphs, or other visualization tools. The accuracy of a sentiment analysis model is crucial to the credibility of the results. Therefore, before using a model, ensure that it has been thoroughly trained and validated and demonstrates good performance in real-world applications. The first feature input into a pre-set sentiment analysis model typically undergoes preprocessing steps, such as text cleaning, tokenization, and stop word removal, to improve the model's recognition accuracy. When processing social media data, special attention must be paid to protecting user privacy. Ensure compliance with relevant privacy policies and regulatory requirements when collecting, storing, and analyzing data.

[0050] Through learning and training, the pre-set sentiment analysis model can accurately match the user's primary characteristics (such as text content and posting time) to corresponding sentiment labels, such as positive, negative, and neutral sentiment. This accuracy enables a more precise understanding of user emotional tendencies. By integrating sentiment labels from multiple time points, we can monitor the emotional changes of target users in real time. This time sensitivity allows us to promptly capture fluctuations in user emotions, providing strong support for subsequent decision-making and response. By integrating sentiment labels from multiple time points for target users, we can generate sentiment trend analysis. This trend analysis helps us understand users' long-term emotional states and their emotional reactions to specific events or topics.

[0051] Optionally, determining the first probability of a current critical event occurring based on the emotional tendency and the emotional change in combination with the second data includes: Determine the first percentage of each sentiment tendency in the preset topic at the current moment, and determine the second percentage of each sentiment trend; Determining a mainstream emotional tendency based on a first emotional tendency, and determining a mainstream emotional change based on a first emotional trend, wherein the first emotional tendency and the second emotional tendency are any two emotional tendencies, a first proportion of the first emotional tendency is greater than a first proportion of the second emotional tendency, and the first emotional trend and the second emotional trend are any two emotional trends, a second proportion of the first emotional trend is greater than a second proportion of the second emotional trend; When the mainstream emotional tendency is the preset emotional tendency and the mainstream emotional change is the preset emotional change, the target geographical location is determined according to the first data, and the first probability is determined according to the data of the target geographical location in the second data.

[0052] All comments and posts by users within the current time window are collected from social media platforms as the first data. This data is preprocessed, including text cleaning, word segmentation, and stop word removal, to facilitate subsequent sentiment analysis. A preset sentiment analysis model is used to perform sentiment analysis on the preprocessed text, assigning each text a sentiment label (positive, negative, or neutral). The first percentage of each sentiment tendency within each preset topic within the current time window is calculated, for example, 30% for positive sentiment, 60% for negative sentiment, and 10% for neutral sentiment. Preset topics might be "earthquake," "flood," "epidemic," and so on. For each user, based on their sentiment labels at different points in time, their sentiment trends are analyzed and determined. For example, user A's sentiment trend might gradually shift from positive to negative. The second percentage of each sentiment trend within the current user group is calculated to identify the dominant sentiment trend. For example, the negative sentiment trend might account for 55%, the positive sentiment trend for 30%, and other sentiment trends for 15%. The dominant sentiment tendency is determined based on the first percentage. In this example, negative sentiment has the highest percentage (60%), so the dominant sentiment tendency is negative. The dominant sentiment change is determined based on the second percentage. In this example, the negative sentiment trend accounts for the highest proportion (55%), so the prevailing sentiment change is negative. Assume that the pre-set sentiment trend associated with a critical event is negative, and the associated sentiment change is a persistent or intensifying negative trend. When the prevailing sentiment trend is negative and the prevailing sentiment change is a persistent or intensifying negative trend, it is considered that a critical event has occurred. Based on the first data (e.g., text content on social media), the target geographic location associated with the critical event (e.g., the location mentioned, the area where the event occurred, etc.) can be determined. The second data is then searched for critical event data related to the target geographic location, such as the incidence rate and impact range of similar past events. Combining historical data with current sentiment analysis results, an appropriate algorithm (e.g., Bayesian networks, logistic regression, etc.) is used to determine the first probability of a critical event occurring. For example, suppose a large number of comments about "flooding in Region X" suddenly appear on social media, with the majority expressing negative sentiment, and the sentiment trend of these comments showing a persistent and intensifying negative trend. In this case, the prevailing sentiment trend is negative, and the prevailing sentiment change is an intensifying negative trend. By combining the historical flood event data about region X in the second data and the current meteorological data of region X, the first probability of flood occurring in region X can be determined, and corresponding response measures can be taken accordingly.

[0053] By analyzing sentiment trends and emotional fluctuations on social media, potential critical incidents can be quickly identified. This approach can issue early warnings compared to traditional methods, providing valuable response time for relevant departments. By setting preset sentiment trends and emotional fluctuations as trigger conditions, the likelihood of false alarms can be reduced, ensuring the accuracy and reliability of warnings. Combined with primary data (such as social media text content), the target geographic location associated with the critical incident can be accurately determined, providing clear direction for subsequent rescue and response efforts. By leveraging historical critical incident data related to the target geographic location in secondary data, more precise response measures can be developed based on data analysis, improving response efficiency. By analyzing user sentiment trends, the development of critical incidents can be monitored in real time, providing decision-makers with real-time dynamic information. By calculating the proportion of each sentiment trend, the public's general views and attitudes towards the incident can be understood, providing a reference for public opinion analysis and response. Combining sentiment data and geographic location data on social media enables information sharing between different departments and promotes cross-departmental collaboration. Based on the accurate target geographic location and incident dynamics, various resources, such as rescue teams and material reserves, can be more effectively integrated to improve the efficiency of critical incident response. By analyzing historical data and warning results, we can continuously optimize sentiment analysis models and warning algorithms, improving the accuracy and reliability of warnings. Based on the results of data analysis, we can identify problems and shortcomings in the warning and response processes, providing directions for future improvements.

[0054] Optionally, determining the first probability according to the data of the target geographic location in the second data includes: determining first sub-data of the target geographic location at a current moment and second sub-data at a historical moment, calculating average data of a second target sub-item in the second sub-data, and comparing the first target sub-item data in the first sub-data with the average data to determine an abnormal sub-item; The abnormal sub-items are weighted and summed to obtain the first probability.

[0055] Data related to the target location is retrieved from the second data. This data may include historical records of similar events, real-time weather data, traffic conditions, and so on. From the second data, extract the current first sub-data for the target location (such as real-time weather readings, real-time reports on social media), and the historical second sub-data (such as average weather readings over the past week or month, historical event records, etc.). For each second target sub-item in the second sub-data (such as historical weather readings, historical event frequencies), calculate the mean or other statistical value (such as the median or mode). Compare the first target sub-item data in the first sub-data with the corresponding average data. If a first target sub-item data exceeds a preset threshold (such as ±2 standard deviations of the historical mean), it is considered an outlier. Each outlier is assigned a weight based on its impact on the risk of the critical event. The weighted values of all outliers are summed to obtain a comprehensive risk score, which is the desired first probability. Suppose that a large number of posts about the "Y City Flood" appear on social media, with a high proportion of posts with negative sentiment and intensified negative sentiment trends. By analyzing these posts, the target location was identified as City Y. Retrieving both current and historical weather data for City Y revealed that current rainfall far exceeded the historical average rainfall threshold. Real-time reports on social media also indicated signs of flooding in multiple areas. Therefore, rainfall was considered an anomaly sub-item and assigned a higher weight. This weighted value for rainfall was then summed with the weighted values of other possible anomaly sub-items (such as wind speed and water level) to produce a comprehensive risk score, the first probability. This probability reflects the current flood risk level in City Y.

[0056] By analyzing the current data (first sub-data) and historical data (second sub-data) of a target location, a more comprehensive and accurate assessment of the risk profile of that location can be achieved. Historical data provides context and benchmarks, while real-time data reflects the current situation. By comparing current data with the average of historical data, outliers—those indicators that significantly deviate from the normal range—can be quickly identified. These outliers are often a direct indicator of increased risk. Once identified, the system can quickly determine that the location presents a high risk and trigger the appropriate early warning mechanism. This rapid response capability is crucial for minimizing losses and ensuring public safety. The first probability derived from the weighted summation is not only a quantitative risk indicator but also provides decision-makers with concrete and actionable evidence. Based on this probability, decision-makers can formulate response measures and allocate resources. Compared to traditional early warning methods based on experience and intuition, this method relies on extensive analysis of both historical and real-time data, making it more accurate and reliable. Because it relies on data analysis, its predictions can be verified and revised through subsequent actual events, continuously improving the accuracy and reliability of the early warning system. This approach not only works for a specific geographic location but can be expanded to other locations as needed by collecting the corresponding data and performing similar analyses. Whether it’s a natural disaster, a public health incident, or another type of emergency, as long as the relevant data can be collected, this approach can be used to assess risk and predict the probability of an event.

[0057] Optionally, inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media includes: Construct a social network graph, using users as nodes in the graph and interactions between users as edges in the graph, and calculate the sentiment weight of each edge based on the content and sentiment of the interactions between users; The propagation path is determined based on the relationship between nodes, and the trend of sentiment propagation and evolution is determined based on the sentiment weight and propagation path of the edge.

[0058] User data is collected from social media platforms, including user profiles, posts, comments, likes, and reposts. A social network graph can be constructed, where each user is considered a node and interactions between users (such as comments, likes, and reposts) are considered edges. Consider the following user interaction data: User A comments on User B's post and expresses positive sentiment; User B reposts User C's post with a neutral comment; and User C likes User A's comment. Based on this data, a social network graph can be constructed, where A, B, and C are nodes and their interactions are edges. The sentiment weight of each edge is calculated based on the content and sentiment of the user interactions. This typically requires the use of natural language processing (NLP) techniques and sentiment analysis models. For example, if User A comments on User B's post, a sentiment analysis model can be used to analyze A's comment and generate a sentiment score (e.g., 1 for positive, -1 for negative, and 0 for neutral). This sentiment score can be used as the sentiment weight for the edge from A to B. In social networks, the spread of information, opinions, and sentiment often follows specific paths. These paths can be identified by analyzing the relationships between nodes. For example, in the example above, user A's comment is first seen by user B, and then user B's forwarding may be seen by user C. Therefore, a possible propagation path is A→B→C. Finally, the sentiment weights and propagation paths of edges can be used to determine the trend of sentiment propagation and evolution. By analyzing the sentiment weights and propagation paths of edges, we can understand how sentiment propagates within a social network. For example, if the sentiment weights of most edges are positive, we can assume that positive sentiment is spreading within the network. Over time, users' sentiment tendencies may change. By comparing social network graphs and sentiment weights at different time points, we can observe and analyze the trend of this sentiment evolution.

[0059] By constructing a social network graph, we can capture the complex interactions between users, thereby providing a more comprehensive understanding of their emotional tendencies. This goes beyond analyzing the emotions of individual users to provide a holistic understanding of the emotional state of the entire social network. Edge sentiment weights are calculated based on the content of user interactions and their emotional tendencies, further refining the measurement of user sentiment and making the analysis more accurate and specific. By identifying the relationships between nodes in the social network graph, we can determine the paths along which emotions propagate within the social network. This helps predict the direction and speed of sentiment spread on social media. Combining edge sentiment weights with propagation paths allows us to predict trends in the spread and evolution of emotions. This allows businesses, governments, and other organizations to timely grasp changes in public sentiment and formulate appropriate strategies. Understanding user emotional tendencies and emotional fluctuations allows businesses to develop more precise marketing strategies and improve marketing effectiveness. For example, launching new products or campaigns when sentiment is positive is more likely to elicit user response. Fluctuations in public sentiment on social media can often foreshadow the occurrence of certain events. By monitoring and analyzing user emotional fluctuations in real time, potential crises can be identified and appropriate responses formulated. By continuously collecting and analyzing actual data, we can continuously optimize and improve the sentiment analysis model and enhance its accuracy and generalization ability.

[0060] S130: When the first probability is greater than a first threshold, determine a first type and a first geographical location of the emergency event, and send an alarm message to a corresponding government department based on the first type and the first geographical location; Based on existing data analysis models and algorithms, combined with current contextual information, a preliminary classification of critical events is performed. These classifications may include, but are not limited to, natural disasters (such as earthquakes, floods, and hurricanes), public health events (such as infectious disease outbreaks), and social security events (such as terrorist attacks and large-scale riots). This classification may be based on user discussions on social media, such as keywords and hashtags; cluster analysis of geolocation data to determine whether the events are concentrated in a particular area; and comparative analysis with historical events to identify similarities and patterns. After determining the type of critical event, user geolocation data and the information dissemination paths within social networks are further utilized to pinpoint the specific location of the event. Methods for determining the location may include analyzing social media posts with location information, such as user-posted photos and videos; tracing the information dissemination paths within social networks to identify the information source or the area of concentrated outbreak; and further narrowing down the location by integrating relevant data published by government agencies, such as meteorological and geological data. Once the primary type and location of the critical event are determined, an alert is immediately generated and sent to the relevant government departments through appropriate means. The content of the alert should be as detailed and accurate as possible, including: the type and level of the emergency, the geographic location and time of the incident, a description of the current situation and preliminary assessment, and any necessary recommendations or action plans. Depending on the severity of the emergency, the methods for disseminating the alert may include: directly contacting the relevant department heads via email, text message, or phone; utilizing internal government information systems or platforms, such as emergency management platforms and government service platforms, to push information; and publicly posting the alert on social media to attract public attention and assist in the response. After the alert is sent, the incident should continue to be tracked and analyzed, and updated information and recommendations should be provided to the relevant government departments in a timely manner. Feedback and evaluation results from government departments should also be collected to continuously refine and optimize the early warning models and algorithms.

[0061] S140: When the first probability is less than or equal to a first threshold, extract a second feature from the second data, and input the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset future time. Secondary data, typically including meteorological, geological, and infectious disease data, is collected and published from various government agencies. This data is typically highly specialized and accurate, providing crucial insights for predicting future critical events. After collecting this secondary data, it undergoes feature extraction. Feature extraction is a crucial step in data preprocessing, aiming to extract information from the raw data that is useful for predictive models. Different feature extraction methods may be required for different data types (e.g., meteorological, geological, and infectious disease data). For example, for meteorological data, potential features include temperature, humidity, wind speed, and rainfall; for geological data, potential features include earthquake frequency and tectonic stability; and for infectious disease data, potential features include the number of cases, transmission rate, and scope of infection. After extracting these secondary features, they are fed into a pre-defined predictive model. This predictive model is typically built using machine learning or deep learning algorithms, trained and validated using historical data. Based on the input features, it can predict the probability of a critical event occurring within a specific future timeframe. The predictive model works by analyzing and learning from historical data to identify patterns and correlations within the data, and then using these patterns and correlations to predict future events. During this process, the prediction model comprehensively considers the influence of multiple features and generates a comprehensive probability value. After receiving the second feature, the prediction model calculates and outputs a second probability value, which represents the likelihood of a critical event occurring within a preset time in the future.

[0062] S150: When the second probability is greater than a second threshold, predict a second type and a second geographical location of the emergency event, and send a prompt message to a corresponding government department based on the second type and the second geographical location.

[0063] The second probability is evaluated to determine whether it exceeds a set second threshold. If the second probability value exceeds the second threshold, a high risk of a future critical event is considered, requiring further attention and action. If the second probability value is less than or equal to the second threshold, the risk of a future critical event is considered low and no action is required. Appropriate action will be taken based on the second probability assessment results. If the second probability value exceeds the second threshold, a notification message may be sent to relevant government departments, reminding them to pay attention to the potential future critical event and take appropriate preventive measures. Relevant information may also be posted on social networks to alert the public to take precautions. If the second probability value does not exceed the second threshold, data changes may continue to be monitored and forecast results will be regularly updated. Furthermore, the forecast model may be fine-tuned and optimized based on new data input to improve forecast accuracy and reliability.

[0064] This embodiment also discloses a critical event pre-judgment system based on a big data model. Figure 2 This is a module diagram of the critical event pre-judgment system based on the big data model disclosed in the embodiment of the present application, such as Figure 2 As shown, the system includes a collection module 201, an emotion module 202, an alarm module 203, a prediction module 204, and a prompt module 205, wherein: Collection module 201 is configured to obtain first data authorized by multiple users on social networks and second data published by multiple departments of government agencies, wherein the first data includes posts, reposts, comments, likes, and geographic location data, and the second data includes meteorological data, geological data, and infectious disease data; The emotion module 202 is configured to extract a first feature from the first data, input the extracted first feature into a preset emotion analysis model to obtain the emotional tendencies and emotional changes of multiple users on the social media, and determine a first probability of a critical event occurring based on the emotional tendencies and emotional changes in combination with the second data; an alarm module 203 configured to, when the first probability is greater than a first threshold, determine a first type and a first geographical location of the emergency event, and send an alarm message to a corresponding government department based on the first type and the first geographical location; The prediction module 204 is configured to extract a second feature from the second data when the first probability is less than or equal to a first threshold, and input the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset time in the future; The prompt module 205 is configured to predict a second type and a second geographical location of the emergency event when the second probability is greater than a second threshold, and send a prompt message to a corresponding government department according to the second type and the second geographical location.

[0065] Optionally, the emotion module 202 is configured to: Cleaning and segmenting the text data in the first data, and counting all non-repeated words in the text data to form a vocabulary; Calculating the term frequency and inverse document frequency of each word, and calculating the product of the term frequency and the inverse document frequency to obtain the median value of each word; A first intermediate vector is constructed according to the intermediate value, a final vector is constructed according to the first intermediate vector and the word embedding vector, and the final vector is used as the first feature.

[0066] Optionally, the emotion module 202 is configured to: Matching the vocabulary vector of the target word from the preset word embedding model as the word embedding vector of the target word, and aggregating the word embedding vector and the first intermediate vector into a second intermediate vector using weighted average; The second intermediate vector and the first intermediate vector are concatenated into a final vector.

[0067] Optionally, the emotion module 202 is configured to: Matching the emotion label corresponding to each time point according to the first feature using the preset emotion analysis model, wherein the emotion label includes positive emotion, negative emotion, and neutral emotion, and the preset emotion analysis model includes the first feature, the emotion label, and the corresponding relationship between the first feature and the emotion label; The emotional tendency of the target user at the current moment is determined according to the emotional tag, and the emotional tags of the target user at multiple time points are integrated to form the emotional trend of the target user.

[0068] Optionally, the emotion module 202 is configured to: Determine a first percentage of each emotional tendency at the current moment, and determine a second percentage of each emotional trend; Determining a mainstream emotional tendency based on a first emotional tendency, and determining a mainstream emotional change based on a first emotional trend, wherein the first emotional tendency and the second emotional tendency are any two emotional tendencies, a first proportion of the first emotional tendency is greater than a first proportion of the second emotional tendency, and the first emotional trend and the second emotional trend are any two emotional trends, a second proportion of the first emotional trend is greater than a second proportion of the second emotional trend; When the mainstream emotional tendency is the preset emotional tendency and the mainstream emotional change is the preset emotional change, the target geographical location is determined according to the first data, and the first probability is determined according to the data of the target geographical location in the second data.

[0069] Optionally, the emotion module 202 is configured to: determining first sub-data of the target geographic location at a current moment and second sub-data at a historical moment, calculating average data of a second target sub-item in the second sub-data, and comparing the first target sub-item data in the first sub-data with the average data to determine an abnormal sub-item; The abnormal sub-items are weighted and summed to obtain the first probability.

[0070] Optionally, the emotion module 202 is configured to: Construct a social network graph, using users as nodes in the graph and interactions between users as edges in the graph, and calculate the sentiment weight of each edge based on the content and sentiment of the interactions between users; The propagation path is determined based on the relationship between nodes, and the trend of sentiment propagation and evolution is determined based on the sentiment weight and propagation path of the edge.

[0071] It should be noted that the above embodiments provide devices that implement their functions using only the division of the above functional modules as examples. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the device and method embodiments provided in the above embodiments are based on the same concept. The specific implementation process is detailed in the method embodiment and will not be repeated here.

[0072] This embodiment also discloses an electronic device, referring to Figure 3 The electronic device may include: at least one processor 301 , at least one communication bus 302 , a user interface 303 , a network interface 304 , and at least one memory 305 .

[0073] The communication bus 302 is used to implement the connection and communication between these components.

[0074] The user interface 303 may include a display screen (Display) and a camera (Camera). Optionally, the user interface 303 may also include a standard wired interface and a wireless interface.

[0075] The network interface 304 may optionally include a standard wired interface or a wireless interface (such as a WI-FI interface).

[0076] The processor 301 may include one or more processing cores. Using various interfaces and circuits, the processor 301 connects to various components within the server. It executes instructions, programs, code sets, or instruction sets stored in the memory 305, as well as accesses data stored in the memory 305, to perform various server functions and process data. Optionally, the processor 301 may be implemented using at least one of the following hardware forms: a digital signal processing (DSP), a field-programmable gate array (FPGA), or a programmable logic array (PLA). The processor 301 may integrate one or a combination of a central processing unit (CPU), a graphics processing unit (GPU), and a modem. The CPU primarily processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing content displayed on the display screen; and the modem handles wireless communications. It is understood that the modem may not be integrated into the processor 301 but implemented as a separate chip.

[0077] Among them, the memory 305 may include a random access memory (RAM) or a read-only memory (Read-Only Memory). Optionally, the memory 305 includes a non-transitory computer-readable storage medium. The memory 305 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 305 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a touch function, a sound playback function, an image playback function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 305 may also be optionally at least one storage device located away from the aforementioned processor 301. As Figure 3 As shown, the memory 305 as a computer storage medium may include an operating system, a network communication module, a user interface module, and an application program of a critical event pre-judgment method based on a big data model.

[0078] exist Figure 3In the electronic device shown, the user interface 303 is mainly used to provide an input interface for the user and obtain data input by the user; and the processor 301 can be used to call the application program of the emergency event pre-judgment method based on the big data model stored in the memory 305. When executed by one or more processors 301, the electronic device executes one or more methods as in the above-mentioned embodiments.

[0079] It should be noted that for the aforementioned method embodiments, for simplicity of description, they are all expressed as a series of action combinations, but those skilled in the art should be aware that this application is not limited by the order of the actions described, because according to this application, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also be aware that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required for this application.

[0080] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0081] In the several embodiments provided in this application, it should be understood that the disclosed devices can be implemented in other ways. For example, the device embodiments described above are merely schematic, such as the division of units, which is only a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some service interface, and the indirect coupling or communication connection of devices or units can be electrical or other forms.

[0082] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.

[0083] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.

[0084] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable memory. Based on this understanding, the technical solution of this application, or the portion that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a memory 305 and includes several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the various embodiments of the method of this application. The aforementioned memory 305 includes various media that can store program code, such as a USB flash drive, a mobile hard drive, a magnetic disk, or an optical disk.

[0085] The above is only an exemplary embodiment of the present disclosure and cannot be used to limit the scope of the present disclosure. That is, any equivalent changes and modifications made according to the teachings of the present disclosure are still within the scope of the present disclosure. After considering the disclosure of the specification and the truth of practice, those skilled in the art will easily think of other embodiments of the present disclosure. This application is intended to cover any variation, use or adaptive change of the present disclosure, which follows the general principles of the present disclosure and includes common knowledge or customary technical means in the art that are not recorded in the present disclosure. The description and examples are to be regarded as exemplary only, and the scope and spirit of the present disclosure are defined by the claims.

Claims

1. A method for prejudging critical events based on a big data model, characterized in that: Applied to an event prejudgment platform, the method comprises: Obtaining first data authorized by multiple users on social networks and second data published by multiple departments in government agencies, wherein the first data includes posting, forwarding, commenting, liking and geographic location data, and the second data includes meteorological data, geological data and infectious disease data; Extracting a first feature from the first data, and inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and mood changes of multiple users on social media, and determining a first probability of a critical event currently occurring based on the sentiment tendencies and mood changes in combination with the second data; When the first probability is greater than a first threshold, determining a first type and a first geographical location of the critical event, and sending an alarm message to a corresponding government department according to the first type and the first geographical location; When the first probability is less than or equal to a first threshold, extracting a second feature from the second data, and inputting the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset time in the future; When the second probability is greater than a second threshold, a second type and a second geographical location of the emergency event are predicted, and prompt information is sent to a corresponding government department according to the second type and the second geographical location.

2. The critical event pre-judgment method based on the big data model according to claim 1 is characterized in that: The extracting a first feature from the first data comprises: Cleaning and segmenting the text data in the first data, and counting all non-repeated words in the text data to form a vocabulary; Calculating the term frequency and the inverse document frequency of each term, and calculating the product of the term frequency and the inverse document frequency to obtain the median value of each term; A first intermediate vector is constructed according to the intermediate value, a final vector is constructed according to the first intermediate vector and the word embedding vector, and the final vector is used as the first feature.

3. The critical event pre-judgment method based on the big data model according to claim 2 is characterized in that: The constructing a final vector according to the first intermediate vector and the word embedding vector comprises: Matching the vocabulary vector of the target word from the preset word embedding model as the word embedding vector of the target word, and aggregating the word embedding vector and the first intermediate vector into a second intermediate vector by weighted average; The second intermediate vector and the first intermediate vector are concatenated into a final vector.

4. The critical event pre-judgment method based on the big data model according to claim 1 is characterized in that: The step of inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and sentiment changes of multiple users on social media includes: Matching the emotion label corresponding to each time point according to the first feature through the preset emotion analysis model, the emotion label includes positive emotion, negative emotion and neutral emotion, and the preset emotion analysis model includes the first feature, the emotion label and the corresponding relationship between the first feature and the emotion label; The emotional tendency of the target user at the current moment is determined according to the emotional label, and the emotional labels of the target user at multiple time points are integrated to form the emotional trend of the target user.

5. The critical event pre-judgment method based on the big data model according to claim 4 is characterized in that: Determining the first probability of a critical event occurring currently according to the emotional tendency and the emotional change in combination with the second data includes: Determine the first percentage of each emotional tendency in the preset topic at the current moment, and determine the second percentage of each emotional trend; Determine the mainstream emotional tendency according to the first emotional tendency, and determine the mainstream emotional change according to the first emotional trend, the first emotional tendency and the second emotional tendency are any two emotional tendencies, the first proportion of the first emotional tendency is greater than the first proportion of the second emotional tendency, the first emotional trend and the second emotional trend are any two emotional trends, the second proportion of the first emotional trend is greater than the second proportion of the second emotional trend; When the mainstream emotional tendency is the preset emotional tendency and the mainstream emotional change is the preset emotional change, the target geographical location is determined according to the first data, and the first probability is determined according to the data of the target geographical location in the second data.

6. The critical event pre-judgment method based on big data model according to claim 5 is characterized in that: Determining the first probability according to the data of the target geographical location in the second data includes: Determine the first sub-data of the target geographic location at the current moment and the second sub-data at the historical moment, count the average data of the second target sub-item in the second sub-data, and compare the first target sub-item data in the first sub-data with the average data to determine the abnormal sub-item; The abnormal sub-items are weighted and summed to obtain the first probability.

7. The critical event pre-judgment method based on big data model according to claim 1 is characterized in that: The step of inputting the extracted first feature into a preset sentiment analysis model to obtain sentiment tendencies and sentiment changes of multiple users on social media includes: Constructing a social network graph, taking users as nodes in the social network graph, taking interactions between users as edges in the social network graph, and calculating the sentiment weight of each edge according to the interaction content and sentiment tendency between users; The propagation path is determined according to the relationship between nodes, and the trend of sentiment propagation and evolution is determined according to the sentiment weight and propagation path of the edge.

8. A critical event pre-judgment system based on a big data model, characterized in that: It includes collection module, emotion module, alarm module, prediction module and prompt module, among which: A collection module configured to obtain first data authorized by multiple users on a social network and second data published by multiple departments in a government agency, wherein the first data includes posting, forwarding, commenting, liking and geographic location data, and the second data includes meteorological data, geological data and infectious disease data; an emotion module configured to extract a first feature from the first data, input the extracted first feature into a preset emotion analysis model to obtain the emotion tendency and emotion change of multiple users on the social media, and determine a first probability of a critical event occurring currently according to the emotion tendency and emotion change in combination with the second data; an alarm module, configured to determine a first type and a first geographical location of the emergency event when the first probability is greater than a first threshold, and send an alarm message to a corresponding government department according to the first type and the first geographical location; A prediction module, configured to extract a second feature from the second data when the first probability is less than or equal to a first threshold, and input the extracted second feature into a preset prediction model to obtain a second probability of a critical event occurring within a preset time in the future; The prompt module is configured to predict a second type and a second geographical location of the emergency event when the second probability is greater than a second threshold, and send prompt information to a corresponding government department according to the second type and the second geographical location.

9. An electronic device, characterized in that: It includes a processor, a memory, a user interface and a network interface, the memory is used to store instructions, the user interface and the network interface are both used to communicate with other devices, and the processor is used to execute the instructions stored in the memory so that the electronic device executes the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores instructions, and when the instructions are executed, the method according to any one of claims 1 to 7 is executed.

Citation Information

Cited By

  • Intelligent visual energy-saving power distribution system and method, electronic equipment and storage medium

    CN121189724A