Civil aviation safety report topic modeling method based on large language model and semantic enhancement

By employing a semantic enhancement method based on a large language model, combined with the HDBSCAN algorithm and a noise sample evaluation and repair mechanism, the problem of large data scale and dense professional terminology in thematic modeling of civil aviation safety reports was solved. This enabled efficient and accurate risk identification and trend analysis, adapting to the professional semantic characteristics of the civil aviation safety field and improving the comprehensiveness and reliability of the analysis results.

CN122155555APending Publication Date: 2026-06-05CHINA ACAD OF CIVIL AVIATION SCI & TECH

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA ACAD OF CIVIL AVIATION SCI & TECH
Filing Date
2026-05-08
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing technologies for thematic modeling in civil aviation safety reports suffer from problems such as large data scale, unstructured data, dense technical terminology, poor domain adaptability, imbalance between modeling efficiency and effectiveness, distortion of long-tail distribution structure, and lack of self-optimization ability, resulting in inaccurate analysis results and low efficiency.

Method used

We employ a method based on large language models and semantic enhancement. We perform initial clustering using the HDBSCAN algorithm, combine a noise sample evaluation and repair mechanism with representative sample screening, construct a comprehensive gain function, iteratively screen representative samples, and use a joint similarity function to preserve boundary and noise samples, thereby achieving topic adaptive optimization.

Benefits of technology

It achieves semantically accurate, comprehensive, efficient, and stable topic modeling, can identify long-tail risk patterns, adapts to the professional semantic features of the civil aviation safety field, reduces computational costs, and improves the comprehensiveness and reliability of analysis.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122155555A_ABST
    Figure CN122155555A_ABST
Patent Text Reader

Abstract

The application discloses a kind of civil aviation safety report theme modeling methods based on large language model and semantic enhancement, its method includes: civil aviation safety theme semantic feature model extracts the text semantic vector and event structure vector of safety report text, and obtains the fusion feature vector of safety report text by fusion;Safety report text database is carried out cluster clustering processing and obtains initial cluster set and noise sample set;Select representative front p% as the representative sample set of cluster;Construct noise sample evaluation repair mechanism module, and select the candidate cluster to which noise sample belongs using noise sample evaluation repair mechanism module;Comprehensive gain function is constructed using representative sample set in cluster, and representative sample iteration screening processing of candidate sample is carried out in cluster.The application realizes the theme modeling goal of semantic accuracy, comprehensive coverage and stable result by multi-module collaborative innovation, and provides reliable technical support for management decision.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of constructing a large predictive model for civil aviation safety reports, and in particular to a method for modeling civil aviation safety reports based on a large language model and semantic enhancement. Background Technology

[0002] Employee voluntary reports are a core data source for the civil aviation safety management system. Their content covers various types of information such as operational risks, operational deviations, and equipment anomalies, and has irreplaceable value for safety risk identification and trend warning. However, voluntary report data generally has the following significant characteristics: (1) The data scale is huge and continues to grow rapidly. Airlines or airport management agencies may receive thousands to tens of thousands of reports per day, which has far exceeded the limit of manual processing capacity; (2) The text content is highly unstructured. Frontline employees have non-standard phenomena such as colloquialism, abbreviation, and different expression methods when filling out reports, and there is a lack of a unified template; (3) Professional terms are highly dense, and the same term may refer to different connotations due to different operating scenarios. The same risk event may also present completely different textual expressions due to the description habits of personnel in different positions. The traditional method of processing employee voluntary reports mainly relies on safety analysis experts to read each report, manually classify and statistically analyze them. This approach suffers from significant efficiency bottlenecks. It not only consumes substantial human and time resources, resulting in analysis cycles measured in weeks or even months, severely lagging behind the rapid evolution of operational risks, but also struggles to cope with explosive growth in data volumes. Furthermore, the analysis results are highly dependent on the individual knowledge and subjective judgment of experts; different experts may categorize the same report differently, making consistency and repeatability difficult to guarantee, and hindering large-scale, continuous, and automated analysis. Therefore, the industry urgently needs an intelligent topic modeling technology to efficiently and accurately uncover potential security hotspots and risk patterns from massive amounts of unstructured text, shifting the security management model from passive "incident investigation" to proactive "data-driven risk identification."

[0003] Existing technologies for text topic modeling mainly include the following methods: The first category is probabilistic model-based methods, represented by the Latent Dirichlet Allocation (LDA) model (a representative example is LDA, such as Chinese patent CN2024118327435). These methods are based on the bag-of-words assumption and infer the probability distribution of document-topic and topic-vocabulary relationships through word frequency statistics. However, their core flaw lies in completely ignoring the sequential relationships and deep semantic connections between words, and can only output semantically discrete sets of keywords. For example, "aircraft overruns the runway" and "aircraft deviates from the runway surface" will be regarded as two weakly related sets of words and cannot be identified as the same type of event; the generated "topic-vocabulary" probability distribution has poor interpretability, and business personnel cannot accurately understand the connotation of the topic based on discrete words alone. In practical applications, experts often still need to manually "translate" and summarize. The second category comprises methods based on semantic embedding and clustering, such as BERTopic (a representative example being Chinese patent CN2023116208460). These methods utilize pre-trained language models to generate sentence-level semantic vectors, followed by dimensionality reduction and density clustering. This addresses the semantic expression problem to some extent, allowing semantically similar texts to be clustered. However, the final output remains a set of keywords extracted based on word frequency statistics or TF-IDF-like methods, essentially failing to overcome the limitations of "bag-of-vocabularies" expression and still lacking coherent sentence-level semantic descriptions, resulting in limited improvement in business comprehensibility. The third category comprises methods based on large language models, such as TopicGPT. These methods can directly generate sentence-level, highly readable topic descriptions, exhibiting the best overall performance. However, in large-scale data scenarios, directly calling large language models for inference on all texts faces enormous computational overhead and inference latency, leading to high costs. Existing methods generally lack effective sample selection mechanisms; random sampling easily misses rare but fatal low-frequency risks, while full processing is not feasible in engineering.

[0004] Moreover, when the methods mentioned above are specifically applied to the specific scenario of subject modeling for voluntary civil aviation safety reports, the following prominent challenges will be faced: (1) Poor domain adaptability; the general model has limited ability to understand the professional terminology, industry jargon, and expressions in specific contexts in the field of aviation safety, making it difficult to accurately depict its subtle semantic features. As a result, a large number of reports with highly similar semantics but large differences in literal expression cannot be effectively clustered, forming a large number of fragmented "micro-clusters" or noise points. (2) Imbalance between modeling efficiency and effect; existing methods generally lack a structure-aware sample selection mechanism, making it impossible to efficiently extract a small sample subset from massive reports that is both representative of the core and can comprehensively cover various long-tail risk patterns. Simple random sampling or sampling based on the center point is very likely to ignore scarce but high-value risk samples. (3) Structural distortion under long-tail distribution; Voluntary reports exhibit typical short text sparsity and long-tail distribution characteristics. A large number of low-frequency but effective risk reports (such as occasional failures of specific systems in specific environments) are easily discarded as "noise" due to insufficient neighborhood support during density-based clustering, or are mistakenly forcibly merged into a large cluster with a large semantic distance, resulting in distortion of the overall topic space structure and omission of potential high-risk warning signals. (4) Lack of topic self-optimization capability; Most topic modeling methods adopt a static mode of "one-time generation and fixed results". The initial topics have problems such as inconsistent granularity, semantic overlap or internal heterogeneity, which will directly affect the accuracy and business availability of the final analysis results; After topic generation, there is a lack of a closed-loop mechanism for adaptive splitting, merging or correction based on full data feedback. Summary of the Invention

[0005] The purpose of this invention is to provide a topic modeling method for civil aviation safety reports based on a large language model and semantic enhancement. Through multi-module collaboration, it achieves the goals of semantic accuracy, comprehensive coverage, high efficiency, stable results, and business applicability in topic modeling, providing reliable technical support for civil aviation safety risk identification, trend analysis, and management decision-making.

[0006] The objective of this invention is achieved through the following technical solution: A method for topic modeling in civil aviation safety reports based on large language models and semantic enhancement, the method comprising: S1. Obtain safety report texts and construct a safety report text database. Construct a civil aviation safety theme semantic feature model. The civil aviation safety theme semantic feature model divides the safety report text into several candidate sentences and obtains text semantic vectors and event structure vectors for each sentence. The event structure vectors and text semantic vectors of the safety report text are then fused to obtain the final safety report text. fusion feature vector ; S2. Initial clustering is performed on the security report texts in the security report text database using the HDBSCAN algorithm to obtain an initial cluster set. and noise sample set, For cluster number k, cluster It contains several sample security report texts. Corresponding samples ; S3, in cluster The cosine similarity between the sample and the cluster center is used as the representative value, and the top p% of the representative values ​​are selected as the clusters. A representative set of samples; S4. Select the neighborhood clusters of the noise samples in the noise sample set as candidate clusters, obtain the local neighborhood sample sets within each candidate cluster, and the local neighborhood sample sets are the sample sets within the neighborhood of the noise samples; construct a noise sample evaluation and repair mechanism module, and use the noise sample evaluation and repair mechanism module to select the candidate cluster to which the noise samples belong. S5, in cluster In the process of constructing a comprehensive gain function using a representative sample set in a cluster Within the candidate samples, iterative screening of representative samples is performed, and the candidate samples are clusters. Samples outside the representative sample set are selected, and candidate samples that maximize the overall gain are added to the representative sample set until the cluster... The iteration terminates when the representative sample set reaches the preset size.

[0007] To better implement this invention, in method S3, the top p% of representative clusters are selected. The representative sample set is the initial representative sample set; in method S5, the cluster... Based on the initial representative sample set The representative sample set after the second iteration is The expression for the combined gain function is as follows: , For the sample As candidate samples, the representative sample set is The overall benefit brought about For the sample As a fusion feature vector of candidate samples, For clusters The center vector, Indicates sample The cosine similarity between the fused feature vectors and the cluster centers. Indicates sample The most similar sample in the currently selected sample set similarity, Used to measure the additional diversity that the candidate sample can provide relative to the currently selected set. For clusters Boundary samples, This is a repair sample used to repair noise samples using the noise sample assessment and repair mechanism module. These are the weight parameters.

[0008] Preferably, in method S2, the sample Semantic consistency is evaluated with each cluster, and the two clusters with the highest and second-highest semantic consistency are selected when the following condition is met: the difference between the two clusters with the highest and second-highest semantic consistency is less than a threshold. Furthermore, the semantic consistency evaluation value of the second-highest semantic consistency cluster is greater than the threshold. If the sample is the boundary sample of the two clusters with the highest and second highest semantic consistency, then the sample will be marked as the boundary sample of the two clusters with the highest and second highest semantic consistency.

[0009] Preferably, in method S4, the noise sample evaluation and repair mechanism module calculates the semantic consistency evaluation value between the noise sample and the candidate cluster according to the following expression: , For the sample As noise samples and clusters As a semantic consistency evaluation value for candidate clusters, For clusters As a local neighborhood sample set of candidate clusters, For the sample For noisy samples and the closest sample The similarity.

[0010] Preferably, in method S4, the noise sample evaluation and repair mechanism module is internally constructed with the following multiple constraints: Neighborhood semantic consistency constraint: The average similarity between a sample and the local neighborhood sample set within the candidate cluster is higher than a set threshold A; Cluster center consistency constraint: The similarity between the sample and the cluster center vector of the candidate cluster is greater than a threshold. ; Event feature matching constraint: The matching degree between the event feature features of the sample and the event feature features of the candidate cluster is greater than a threshold. The event element features are the features in the event structure vector; The noise sample evaluation and repair mechanism module internally includes the following final repair scoring function: ,in For the sample As noise samples and clusters As the final repair evaluation value for candidate clusters, For the sample As noise samples and clusters As a neighborhood semantic consistency evaluation value for candidate clusters, For the sample As noise samples and candidate clusters Inner center vector cosine similarity, The degree of overlap between event elements matched with event elements. These are weight parameters; Select the final repair assessment value The largest cluster is selected as the candidate cluster to which the noise sample belongs.

[0011] Preferably, the civil aviation safety topic semantic feature model is derived from safety report text. The semantics of each candidate sentence are identified and extracted to form a text semantic vector. The security report text The event structure vector is obtained through structured event tuples. Encoding generated vectors , Characteristics of abnormal actions or events. Characteristics of the operational phase, For the characteristics of the objects involved, Characteristics of triggering conditions or influencing factors, Characteristics of results or consequences; the security report text fusion feature vector The fusion expression is as follows: ,in For weight fusion.

[0012] Preferably, a joint similarity function is constructed for the samples. With sample The similarity is calculated using the following joint similarity function:

[0013] in For text semantic similarity, For the sample With sample The degree of overlap of event elements This is the balance coefficient.

[0014] Preferably, the sample With sample overlap of event elements The expression is as follows: ,in The total number of event element dimensions. Number the event element dimensions. For the sample In terms of event elements Data, For the sample In terms of event elements Data, Event elements The weight, This is an indicator function.

[0015] Preferably, the present invention further includes the following method: S6, the final cluster of method S5 As a topic Get various topics, topics This includes a sample set and corresponding topic attributes. The sample set includes a representative sample set, boundary samples, and repaired samples. Repaired samples are those to which noise samples have been repaired using the noise sample evaluation and repair mechanism module. Topic attributes include topic tags and topic descriptions. On the topic Attribution confidence or probability It is obtained according to the following expression: ,in For the sample The encoded representation; Theme The encoding representation, Represents the similarity function. This represents the scaling parameter. Total number of topics Subject number; The sample is calculated according to the following expression. The corresponding topic distribution entropy : ; like or , Indicates sample Maximum attribution confidence across all topics Indicates the confidence threshold. Representing the entropy threshold, then the sample It is identified as a conflict sample and recorded in the conflict set. ; Next, the statistical topic The proportion of internal conflict samples as the conflict rate ,when At that time, on the topic Perform splitting; when the similarity between two topics is greater than a threshold If so, the two topics will be merged.

[0016] Preferably, in the process of text semantic vector recognition, the civil aviation safety topic semantic feature model selects samples with candidate sentence topic density greater than a threshold for model training. The expression is as follows: , Sentence length Indicates words in a sentence The TF-IDF weights are used to measure the importance and rarity of words in a sentence corpus; This indicates the number of words in the sentence that belong to aviation safety professional dictionaries. and These are the weighting coefficients; sentences with high topic density are selected as the core training samples.

[0017] Compared with the prior art, the present invention has the following advantages and beneficial effects: (1) This invention introduces an integrated mechanism of semantic structure repair and boundary sample recognition. Instead of directly discarding noise samples, it constructs a local neighborhood set, calculates semantic consistency scores, and combines multiple constraints such as neighborhood consistency, cluster center consistency, and event element matching to re-cluster low-frequency effective samples that are misjudged as noise. This effectively preserves long-tail risk patterns such as abnormal equipment and extreme scenario risks. By identifying boundary samples in thematic boundary areas, it avoids forcibly classifying cross-thematic composite risk samples into a single cluster, preserves thematic boundary information, and enriches thematic spatial structure. Through noise repair and boundary sample preservation, it solves the problems of incomplete thematic coverage and easy omission of key risks in existing methods, enabling the thematic modeling results to fully cover various risk patterns in the civil aviation safety voluntary report, and improving the integrity of thematic coverage and the comprehensiveness and reliability of safety analysis.

[0018] (2) This invention constructs a representative sample screening mechanism driven by coverage enhancement. By constructing a coverage gain function that integrates core representativeness, semantic diversity, boundary information, and repair information, the optimal sample is iteratively screened. While significantly reducing the sample size, the typical samples in the cluster center, boundary samples, and repaired low-frequency effective samples are retained. It can effectively solve the problems of high computational cost and low inference efficiency in large-scale data scenarios. Under the premise of reducing the inference cost of large language models (reducing the sample size by 30%-60%), it maintains or even improves the topic coverage, realizes the synergistic optimization of computational efficiency and topic quality, and is suitable for the application scenario of continuous growth and large scale of civil aviation voluntary reporting data.

[0019] (3) This invention constructs a domain text embedding model based on contrastive learning, combines the characteristics of aviation safety corpus, introduces topic density index to screen high information samples, uses a large language model to generate semantically equivalent positive samples and screens negative samples based on semantic similarity, can accurately characterize the professional semantic features of civil aviation safety, effectively narrow the distance between semantically similar but different voluntary reports in vector space, and significantly improve the accuracy and distinguishability of text semantic representation.

[0020] (4) This invention achieves adaptive optimization of the topic set by using full sample back-labeling, conflict sample identification, topic splitting and merging, and realizing a topic self-evolution optimization mechanism; by calculating the confidence of the sample's attribution to the topic and the topic distribution entropy, it identifies conflict samples with unclear topic attribution, counts the conflict rate of each topic, triggers splitting of topics with excessive internal heterogeneity, and triggers merging of topics with semantic redundancy. At the same time, it suppresses redundant topics and occasional topics through frequency filtering and semantic merging, so that the topic set can be dynamically adjusted according to the distribution of full data, avoiding topic redundancy, semantic confusion and structural distortion problems; the topic results of this invention are more in line with actual business needs, the structure is more stable and the semantics are clearer, and it can adapt to the dynamic changes of civil aviation safety voluntary report data in the long term.

[0021] (5) This invention solves the core technical problems in existing civil aviation safety voluntary report topic modeling, such as poor domain adaptability, low computational efficiency, incomplete topic coverage, unstable results, and insufficient interpretability, through multi-module collaborative innovation. It achieves the goal of topic modeling with accurate semantics, comprehensive coverage, high efficiency, and stable results, and provides reliable technical support for civil aviation safety risk identification, trend analysis, and management decision-making. Attached Figure Description

[0022] Figure 1 This is a flowchart of the civil aviation safety report topic modeling method of the present invention. Detailed Implementation

[0023] The present invention will be further described in detail below with reference to embodiments: Example like Figure 1 As shown, a method for topic modeling in civil aviation safety reports based on a large language model and semantic enhancement is presented. The method includes: S1. Obtain safety report texts and construct a safety report text database. Construct a civil aviation safety theme semantic feature model. The civil aviation safety theme semantic feature model divides the safety report text into several candidate sentences and obtains text semantic vectors and event structure vectors for each sentence. The event structure vectors and text semantic vectors of the safety report text are then fused to obtain the final safety report text. fusion feature vector Preferably, the civil aviation safety topic semantic feature model is derived from the safety report text. The semantics of each candidate sentence are identified and extracted to form a text semantic vector. Safety report text Event structure vector (security report text) (The vector after structured representation) is passed through structured event tuples Encoding generated vectors , Features of abnormal actions or events (such as "the front wheel cannot be engaged", "passengers are agitated", "the risk of crew fatigue is increased"). These are the characteristics of the operational phase (such as "post-landing taxiing phase", "taxiing phase", "pre-flight support phase"). For the characteristics of the objects involved (such as "aircraft nose wheel turning system", "ground vehicles", "passenger baggage size rules" etc.). For triggering conditions or influencing factors (such as "failure of the left-side steering wheel front wheel turn release switch", "incorrect information displayed by the third-party platform", "tight flight schedule connection, insufficient rest", etc.). Characteristics of the results or consequences (such as "difficulty in taxiing direction control", "passengers making loud noises at the security checkpoint and posing a risk of complaints", "fatigue-related operational risks for the next day's duty personnel", etc.). Safety report text fusion feature vector The fusion expression is as follows: ,in For weight fusion.

[0024] In some embodiments, the civil aviation safety topic semantic feature model selects samples with candidate sentence topic density greater than a threshold for model training during text semantic vector recognition. The topic density of the candidate sentences... The expression is as follows: , Sentence length Indicates words in a sentence The TF-IDF weights are used to measure the importance and rarity of words in a sentence corpus. This indicates the number of words in the sentence that belong to aviation safety professional dictionaries. and These are the weighting coefficients; sentences with high topic density are selected as the core training samples. Preferably, during the construction of positive and negative samples, for each original sentence... Generate semantically equivalent but differently expressed sentences using large language models. As positive samples; simultaneously, semantic similarity is calculated based on the semantic feature model of civil aviation safety topics, and samples are selected from the corpus that are similar to those in the corpus. Sentences with significant semantic differences As negative samples, these triples are used to construct the semantic feature model training for civil aviation safety topics. .

[0025] S2. Initial clustering is performed on the security report texts in the security report text database using the HDBSCAN algorithm to obtain an initial cluster set. , and the noisy sample set (i.e., the set of samples that are not assigned to any cluster). For cluster number k, cluster It contains several sample security report texts. Corresponding samples In some embodiments, for samples Semantic consistency is evaluated with each cluster, and the two clusters with the highest and second-highest semantic consistency are selected when the following condition is met: the difference between the two clusters with the highest and second-highest semantic consistency is less than a threshold. Furthermore, the semantic consistency evaluation value of the second-highest semantic consistency cluster is greater than the threshold. Then, the sample is labeled as the boundary sample of the two clusters with the highest and second-highest semantic consistency. An example is as follows: Let the highest and second-highest scores be: When the following conditions are met: When this happens, the sample is marked as a boundary sample (and given higher weight in subsequent sample screening to preserve information about the topic boundary area).

[0026] S3, in cluster The cosine similarity between the sample and the cluster center is used as the representativeness, and the top p% (20% in this example) are selected as the clusters. A representative sample set.

[0027] S4. Using the noise samples in the noise sample set as the center, select their neighborhood clusters as candidate clusters, and obtain the local neighborhood sample sets within each candidate cluster. The local neighborhood sample sets are the sample sets within the neighborhood region of the noise sample. Construct a noise sample evaluation and repair mechanism module, and use the noise sample evaluation and repair mechanism module to select the candidate cluster to which the noise sample belongs.

[0028] In some embodiments, the noise sample evaluation and repair mechanism module calculates the semantic consistency evaluation value between the noise sample and the candidate cluster according to the following expression (the larger the semantic consistency evaluation value, the higher the consistency of the sample in the semantic space of the cluster, and the more likely it is to belong to the cluster): , For the sample As noise samples and clusters As a semantic consistency evaluation value for candidate clusters, For clusters The local neighborhood sample set (neighborhood set is used to characterize samples) serves as a candidate cluster. In cluster The local semantic distribution reflects its neighborhood similarity within the cluster. For the sample For noisy samples and the closest sample The similarity.

[0029] In some embodiments, the noise sample evaluation and repair mechanism module is internally constructed with the following multiple constraints: Neighborhood semantic consistency constraint: The average similarity between a sample and the local neighborhood sample set within the candidate cluster is higher than a set threshold A.

[0030] Cluster center consistency constraint: The similarity between the sample and the cluster center vector of the candidate cluster is greater than a threshold. ,Right now .

[0031] Event feature matching constraint: The matching degree between the event feature features of the sample and the event feature features of the candidate cluster is greater than a threshold. The event element features are the features in the event structure vector.

[0032] The noise sample evaluation and repair mechanism module internally includes the following final repair scoring function: ,in For the sample As noise samples and clusters As the final repair evaluation value for candidate clusters, For the sample As noise samples and clusters As a neighborhood semantic consistency evaluation value for candidate clusters, For the sample As noise samples and candidate clusters Inner center vector cosine similarity, The degree of overlap between event elements matched with event elements. These are the weighting parameters. The final repair evaluation value is selected. The largest cluster is selected as the candidate cluster to which the noise sample belongs.

[0033] This invention constructs a joint similarity function for samples. With sample The similarity is calculated using the following joint similarity function:

[0034] in For text semantic similarity, For the sample With sample The degree of overlap of event elements This is the balance coefficient. (Sample) With sample overlap of event elements The expression is as follows: ,in The total number of event element dimensions. Number the event element dimensions. For the sample In terms of event elements Data, For the sample In terms of event elements Data, Event elements The weight, This is an indicator function. This embodiment, through a joint similarity function, can simultaneously preserve both the overall semantics of the text and the event structure information, ensuring higher consistency in the representation space for reports with different wording but consistent event structures; the joint similarity function... This serves as the basis for subsequent calculations for noise sample identification, candidate cluster construction, boundary sample identification, and coverage enhancement screening.

[0035] S5, in cluster In the process of constructing a comprehensive gain function using a representative sample set in a cluster Within the candidate samples, iterative screening of representative samples is performed, and the candidate samples are clusters. Samples outside the representative sample set are selected, and candidate samples that maximize the overall gain are added to the representative sample set until the cluster... The iteration terminates when the representative sample set reaches the preset size.

[0036] In some embodiments, method S3 selects the representative top p% (20% in this example) as the cluster. The representative sample set is the initial representative sample set; in method S5, the cluster... Based on the initial representative sample set The representative sample set after the second iteration is The expression for the overall gain function is as follows: ,in For the sample As candidate samples, the representative sample set is The overall benefit brought about Indicates sample Whether it is close to the cluster center is representative. The closer it is to the cluster center, the more it can represent the mainstream semantics (typicality) of the cluster. Indicates sample Is it sufficiently different from the already selected samples? If it is very similar to the selected samples, then there is little new information; if it is significantly different from the selected samples, it means that it can supplement new semantic content; prevent excessive sampling and improve the coverage of the sample set. Indicates boundary sample compensation, if If it is a boundary sample, give it a certain weight to increase its probability of being selected; this is to preserve the information of the topic boundary area and avoid the subsequent large model only seeing very typical samples, but not easily confused or cross-topic samples. Indicates sample compensation for repair, if Samples that have been re-included into the cluster after noise repair are given a certain weight; this is done to retain low-density but semantically effective samples and avoid ignoring important long-tail risks. For the sample As a fusion feature vector of candidate samples, For clusters The center vector (i.e.) For clusters (cluster center), cluster center vector The expression is as follows: The cluster center vector reflects the overall semantic features of the cluster. Indicates sample The cosine similarity between the fused feature vectors and the cluster centers is calculated, i.e., the sample vectors are calculated. with cluster center vector cosine similarity The higher the similarity, the closer the sample is to the semantic center of the cluster, and the more representative it is. Indicates sample The most similar sample in the currently selected sample set similarity, Used to measure the additional diversity that the candidate sample can provide relative to the currently selected set. For clusters Boundary samples, This is a repair sample used to repair noise samples using the noise sample assessment and repair mechanism module. These are the weight parameters. The iteration continues until the preset size is reached, yielding the final sample set for that cluster. Furthermore, the sample sets obtained from each cluster can be merged to form the final sample set. ;in Cluster The representative sample set obtained after coverage enhancement screening Indicates the total number of clusters. This represents the final representative sample set used for generating subsequent topics.

[0037] S6, the final cluster of method S5 As a topic Get various topics, topics This includes a sample set and corresponding topic attributes. The sample set comprises a representative sample set, boundary samples, and repair samples. Repair samples are those belonging to the sample set after being repaired by the noise sample evaluation and repair mechanism module. Topic attributes are generated inductively from the sample set based on a large language model. Topic attributes include topic tags (topic tags are core topic words or frequently repeated topic words in the corresponding sample set) and topic descriptions (topic descriptions are keyword descriptions, content descriptions, etc., of the corresponding topic tags). The sample set (including the representative sample set, boundary samples, and repair samples) of this invention is continuously updated and changed as the security report text increases (changes include topic splitting and merging). The topic attributes (including topic tags and topic descriptions) generated by the large language model based on the sample set also update and change accordingly (achieving the purpose of dynamic self-evolution and topic optimization). On the topic Attribution confidence or probability It is obtained according to the following expression: ,in For the sample The encoding representation. Theme The encoding representation, Represents the similarity function. This represents the scaling parameter. Total number of topics The subject number is used. The sample is calculated using the following expression. The corresponding topic distribution entropy : .

[0038] like or , Indicates sample Maximum attribution confidence across all topics Indicates the confidence threshold. Representing the entropy threshold, then the sample It is identified as a conflict sample and recorded in the conflict set. Next, we will collect statistics on the topics. The proportion of internal conflict samples as the conflict rate ,when At that time, on the topic Perform splitting; when the similarity between two topics is greater than a threshold If so, the two topics will be merged.

[0039] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A method for topic modeling of civil aviation safety reports based on large language models and semantic enhancement, characterized in that: The methods include: S1. Obtain safety report texts and construct a safety report text database. Construct a civil aviation safety theme semantic feature model. The civil aviation safety theme semantic feature model divides the safety report text into several candidate sentences and obtains text semantic vectors and event structure vectors for each sentence. The event structure vectors and text semantic vectors of the safety report text are then fused to obtain the final safety report text. fused feature vector ; S2. Initial clustering is performed on the security report texts in the security report text database using the HDBSCAN algorithm to obtain an initial cluster set. and noise sample set, For cluster number k, cluster It contains several sample security report texts. Corresponding samples ; S3, in cluster The cosine similarity between the sample and the cluster center is used as the representative value, and the top p% of the representative values ​​are selected as the clusters. A representative set of samples; S4. Select the neighborhood clusters of the noise samples in the noise sample set as candidate clusters, obtain the local neighborhood sample sets within each candidate cluster, and the local neighborhood sample sets are the sample sets within the neighborhood of the noise samples; construct a noise sample evaluation and repair mechanism module, and use the noise sample evaluation and repair mechanism module to select the candidate cluster to which the noise samples belong. S5, in cluster In the process of constructing a comprehensive gain function using a representative sample set in a cluster Within the candidate samples, iterative screening of representative samples is performed, and the candidate samples are clusters. Samples outside the representative sample set are selected, and candidate samples that maximize the overall gain are added to the representative sample set until the cluster... The iteration terminates when the representative sample set reaches the preset size.

2. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: In method S3, the top p% representative values ​​are selected as the cluster. The representative sample set is the initial representative sample set; in method S5, the cluster... Based on the initial representative sample set The representative sample set after the second iteration is The expression for the combined gain function is as follows: , For the sample As candidate samples, the representative sample set is The overall benefit brought about For the sample As a fusion feature vector of candidate samples, For clusters The center vector, Indicates sample The cosine similarity between the fused feature vectors and the cluster centers. Indicates sample The most similar sample in the currently selected sample set similarity, Used to measure the additional diversity that the candidate sample can provide relative to the currently selected set. For clusters Boundary samples, This is a repair sample used to repair noise samples using the noise sample assessment and repair mechanism module. These are the weight parameters.

3. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 2, characterized in that: In method S2, for the sample Semantic consistency is evaluated with each cluster, and the two clusters with the highest and second-highest semantic consistency are selected when the following condition is met: the difference between the two clusters with the highest and second-highest semantic consistency is less than a threshold. Furthermore, the semantic consistency evaluation value of the second-highest semantic consistency cluster is greater than the threshold. If the sample is the boundary sample of the two clusters with the highest and second highest semantic consistency, then the sample will be marked as the boundary sample of the two clusters with the highest and second highest semantic consistency.

4. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: In method S4, the noise sample evaluation and repair mechanism module calculates the semantic consistency evaluation value between the noise sample and the candidate cluster according to the following expression: , For the sample As noise samples and clusters As a semantic consistency evaluation value for candidate clusters, For clusters As a local neighborhood sample set of candidate clusters, For the sample For noisy samples and the closest sample The similarity.

5. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: In method S4, the noise sample evaluation and repair mechanism module is internally constructed with the following multiple constraints: Neighborhood semantic consistency constraint: The average similarity between a sample and the local neighborhood sample set within the candidate cluster is higher than a set threshold A; Cluster center consistency constraint: The similarity between the sample and the cluster center vector of the candidate cluster is greater than a threshold. ; Event feature matching constraint: The matching degree between the event feature features of the sample and the event feature features of the candidate cluster is greater than a threshold. The event element features are the features in the event structure vector; The noise sample evaluation and repair mechanism module internally includes the following final repair scoring function: ,in For the sample As noise samples and clusters As the final repair evaluation value for candidate clusters, For the sample As noise samples and clusters As a neighborhood semantic consistency evaluation value for candidate clusters, For the sample As noise samples and candidate clusters Inner center vector cosine similarity, The degree of overlap between event elements matched with event elements. These are weight parameters; Select the final repair assessment value The largest cluster is selected as the candidate cluster to which the noise sample belongs.

6. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: The civil aviation safety topic semantic feature model is derived from safety report text. The semantics of each candidate sentence are identified and extracted to form a text semantic vector. The security report text The event structure vector is obtained through structured event tuples. Encoding generated vectors , Characteristics of abnormal actions or events. Characteristics of the operational phase, For the characteristics of the objects involved, Characteristics of triggering conditions or influencing factors, Characteristics of results or consequences; the security report text fused feature vector The fusion expression is as follows: ,in For weight fusion.

7. The civil aviation safety report topic modeling method based on a large language model and semantic enhancement according to claim 2, 4, or 5, characterized in that: A joint similarity function is constructed for the samples. With sample The similarity is calculated using the following joint similarity function: ; in For text semantic similarity, For the sample With sample The degree of overlap of event elements This is the balance coefficient.

8. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 7, characterized in that: The sample With sample overlap of event elements The expression is as follows: ,in The total number of event element dimensions. Number the event element dimensions. For the sample In terms of event elements Data, For the sample In terms of event elements Data, Event elements The weight, This is an indicator function.

9. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: It also includes the following methods: S6, the final cluster of method S5 As a topic Get each topic, topic This includes a sample set and corresponding topic attributes. The sample set includes a representative sample set, boundary samples, and repaired samples. Repaired samples are those to which noise samples have been repaired using the noise sample evaluation and repair mechanism module. Topic attributes include topic tags and topic descriptions. On the topic Attribution confidence or probability It is obtained according to the following expression: ,in For the sample The encoded representation; Theme The encoding representation, Represents the similarity function. This represents the scaling parameter. Total number of topics Subject number; The sample is calculated according to the following expression. The corresponding topic distribution entropy : ; like or , Indicates sample Maximum attribution confidence across all topics Indicates the confidence threshold. Representing the entropy threshold, then the sample It is identified as a conflict sample and recorded in the conflict set. ; Next, the statistical topic The proportion of internal conflict samples as the conflict rate ,when At that time, on the topic Perform splitting; when the similarity between two topics is greater than a threshold If so, the two topics will be merged.

10. The civil aviation safety report topic modeling method based on large language model and semantic enhancement according to claim 1, characterized in that: The civil aviation safety topic semantic feature model selects samples with a topic density greater than a threshold for model training during text semantic vector recognition. The topic density of the candidate sentences... The expression is as follows: , Sentence length Indicates words in a sentence The TF-IDF weights are used to measure the importance and rarity of words in a sentence corpus; This indicates the number of words in the sentence that belong to aviation safety professional dictionaries. and These are the weighting coefficients; sentences with high topic density are selected as the core training samples.