A method and system for automatically constructing a risk knowledge graph related to government affairs, and a storage medium

CN122886750APending Publication Date: 2026-10-09HUNAN DAILY INTELLIGENT MEDIA TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611127953.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-07-28
Publication Date
2026-10-09

AI Technical Summary

Technical Problem

[0007]针对现有技术中所存在的不足,本发明提供了一种涉政风险知识图谱自动构建方法、系统及存储介质,其解决了现有识别涉政风险内容的技术手段,难以有效识别隐性、变体及指代性涉政表达,以及缺乏结构化风险关系建模能力和自适应能力的问题

Benefits of technology

通过风险逻辑模板与大语言模型的深度结合,能够有效识别并抽取至少包括隐性表达词和指代性词汇的涉政风险实体,解决了传统方法对隐喻、指代和上下文关联语义的盲区问题,显著降低假阴性率,增强了隐性风险识别能力。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122886750A_ABST
    Figure CN122886750A_ABST
Patent Text Reader

Abstract

The application provides a kind of government-related risk knowledge graph automatic construction method, system and storage medium, method includes: using large language model to carry out depth semantic analysis to audit corpus, extract government-related risk entity;Risk entity is converted into semantic vector, the similarity of calculating semantics is constructed graph structure: when semantic similarity is greater than or equal to first threshold value, execute node fusion operation;When semantic similarity is less than second threshold value, create new graph node;When second threshold value is less than or equal to semantic similarity and less than first threshold value, establish semantic association edge;Graph structure is stored in graph database, forms initial risk knowledge graph, identifies risk hot spot and propagation link based on graph algorithm;Risk hot spot and propagation link are fed back to the audit system, and dynamic update risk classification model, sensitive word library and audit rules.The application solves the problems that the prior art is difficult to identify implicit, variant and referential government-related expressions, and lacks structured risk relationship modeling capability and self-adaptive capability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of artificial intelligence technology, and in particular to a method, system, and storage medium for automatically constructing a knowledge graph of political risks. Background Technology

[0002] With the explosive growth of internet information, politically sensitive content in cyberspace is becoming increasingly covert, organized, and complex, posing a serious challenge to national security and social stability. As national security departments have pointed out, the misuse of artificial intelligence technology could become an "invisible weapon" threatening national security, employing methods such as deepfakes, disinformation campaigns, and ideological incitement. Against this backdrop, building an intelligent content security governance system capable of identifying covert, variant, and complexly interconnected content has become an urgent need to ensure the modernization of digital governance capabilities.

[0003] Currently, mainstream network content security governance systems mainly rely on the following three types of technical means when identifying politically sensitive content: static sensitive word database matching, rule engines, and classification models. Among them, the static sensitive word database filters text through a preset keyword blacklist, the rule engine relies on manually written regular expressions or strategy combinations for matching, and the classification model is based on traditional machine learning or deep learning text binary or multi-class classification models.

[0004] However, when faced with increasingly complex politically sensitive content, the aforementioned technical methods reveal the following significant limitations: First, it is difficult to effectively identify implicit, variant, and referential political expressions: The actual risk content uses a lot of homophones (such as "demobilized soldiers"), similar-looking characters (such as "nationality"), decomposition and combination, metaphors and referential expressions (such as "that document" and "that matter"), which traditional keyword matching and rule engines are almost powerless to deal with. On the other hand, relying solely on text classification models also results in a very high false negative rate due to the lack of reasoning ability on deep semantics and context.

[0005] Secondly, the lack of structured risk relationship modeling capabilities makes it impossible to achieve network-level risk assessment: existing systems typically identify each piece of content as an isolated "point," failing to effectively mine and model the intrinsic connections between risk entities, resulting in the inability to identify the propagation chain of misleading policy information, the evolution path of public opinion, and the multi-node collaborative diffusion network.

[0006] Third, the knowledge system cannot continuously evolve, and the system lacks self-adaptive capabilities: the manually maintained sensitive word database and rule engine have inherent problems such as delayed updates, incomplete coverage, and inability to automatically expand. Faced with constantly emerging new risk variants and rhetoric, the system cannot achieve self-evolution, resulting in a gradual decline in defense capabilities. As relevant research points out, content security in the AIGC era urgently needs to be upgraded from "compliance verification" to "intent insight" to build a risk control system with deep semantic understanding and knowledge reasoning capabilities. Summary of the Invention

[0007] To address the shortcomings of existing technologies, this invention provides a method, system, and storage medium for automatically constructing a knowledge graph of political risks. It solves the problems that existing technical means for identifying political risk content are unable to effectively identify implicit, variant, and referential political expressions, and lack the ability to model structured risk relationships and adapt.

[0008] According to an embodiment of the present invention, an automatic construction method for a political risk knowledge graph includes the following steps: Configure a risk logic template for dynamically parsing expressions of political risks, and use a large language model to perform deep semantic inductive analysis on the acquired review corpus in combination with the risk logic template to extract political risk entities. The political risk entities include at least implicit expressions and referential words. The extracted politically-related risk entities are converted into semantic vectors, the semantic similarity between different politically-related risk entities is calculated, and a graph structure is constructed based on the semantic similarity. The constructed graph structure is stored in a graph database to form an initial risk knowledge graph. Risk propagation analysis is performed on the risk knowledge graph based on graph algorithms to identify risk hotspots and propagation links. The identified risk hotspots and transmission links are fed back to the review system as feedback data to dynamically update the risk classification model, sensitive word library and review rules; The construction of the graph structure based on the semantic similarity specifically includes: When the semantic similarity between two entities involved in political risks is greater than or equal to a preset first threshold, they are determined to be strongly related risk entities, and node fusion operation is performed. When the semantic similarity between two politically risky entities is less than a preset second threshold, they are determined to be independent risky entities, and a new graph node is created. When the second threshold is less than or equal to the semantic similarity between two politically risky entities and less than the first threshold, they are identified as potential risk relationships, and a semantic association edge is established between the nodes corresponding to the two politically risky entities.

[0009] According to another embodiment of the present invention, an automatic construction system for a political risk knowledge graph includes: The content access module is used to acquire the corpus data to be reviewed; The semantic analysis module, which integrates a large language model and communicates with the content access module, is used to configure and dynamically parse the risk logic template of political risk expression, and to use the large language model to perform in-depth semantic induction analysis on the review corpus to extract political risk entities that include at least implicit expression words and referential words. The vector encoding module, which is communicatively connected to the semantic analysis module, is used to convert the extracted political risk entities into semantic vectors and calculate the semantic similarity between different political risk entities. The graph fusion management module is communicatively connected to the vector encoding module and is used to construct a graph structure based on the semantic similarity and execute a dynamic fusion strategy. The graph database storage module is communicatively connected to the graph fusion management module and is used to store the constructed graph structure into the graph database to form an initial risk knowledge graph. The graph algorithm analysis module is communicatively connected to the graph database storage module and is used to perform risk propagation analysis on the risk knowledge graph according to the graph algorithm to identify risk hotspots and propagation links. The risk strategy feedback module is connected to the graph algorithm analysis module and the semantic analysis module. It is used to feed back the identified risk hotspots and propagation links as feedback data to the review system in order to dynamically update the risk classification model, sensitive word library and review rules.

[0010] According to another embodiment of the present invention, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the above-described method for automatically constructing a political risk knowledge graph.

[0011] Compared with the prior art, the present invention has the following beneficial effects: By deeply integrating risk logic templates with large language models, we can effectively identify and extract politically risky entities that include at least implicit expressions and referential terms. This solves the blind spots of traditional methods in terms of metaphor, reference, and contextual semantics, significantly reduces the false negative rate, and enhances the ability to identify implicit risks.

[0012] By adopting a dynamic graph structure construction strategy based on semantic similarity (strong association fusion, weak relationship creation, and potential relationship edge construction), a more accurate and dynamic knowledge graph can be constructed. The knowledge graph structure is more in line with semantic reality, avoids arbitrary connection of noisy entities, and improves the quality of the graph and the accuracy of reasoning.

[0013] By proactively feeding back graph analysis results (risk hotspots, propagation links) to the front-end review system, the sensitive word library, review rules, and risk models are dynamically updated, realizing a systematic and automated "perception-decision-feedback" closed loop. This enables the entire system to have continuous learning capabilities, cope with new and variant risk expression methods, and maintain the efficiency and timeliness of risk identification.

[0014] By automating the building process and dynamically updating it, reliance on human expert experience is significantly reduced, as is the workload of manual annotation and rule writing, enabling a shift from "passive response" to "proactive early warning." Compared to traditional manual methods, this improves review efficiency and reduces operating costs. Attached Figure Description

[0015] Figure 1 This is a flowchart illustrating the automatic construction method of a political risk knowledge graph according to Embodiment 1 of the present invention.

[0016] Figure 2 This diagram illustrates the specific steps of constructing a graph structure based on semantic similarity in Embodiment 1 of the present invention.

[0017] Figure 3 This diagram illustrates the specific steps involved in dynamically updating the risk classification model, sensitive word database, and review rules according to Embodiment 1 of the present invention.

[0018] Figure 4 This is a control principle diagram of an automatic construction system for a political risk knowledge graph according to Embodiment 2 of the present invention.

[0019] In the above attached diagram: 1. Content access module; 2. Semantic analysis module; 3. Vector encoding module; 4. Graph fusion management module; 5. Graph database storage module; 6. Graph algorithm analysis module; 7. Risk strategy feedback module; 21. Large language model. Detailed Implementation

[0020] The technical solutions of the present invention will be further described below with reference to the accompanying drawings and embodiments.

[0021] Example 1 like Figure 1 As shown in the figure, this invention proposes an automatic construction method for a knowledge graph of political risks, including the following steps: S1. Configure a risk logic template for dynamically parsing expressions of political risks, and use the large language model 21 to perform deep semantic inductive analysis on the obtained audit corpus in combination with the risk logic template to extract political risk entities. The political risk entities include at least implicit expressions and referential words. The risk logic template includes prompt word templates for identifying referential resolution, metaphor, and contextual association, so as to guide the large language model 21 to capture implicit risk semantics.

[0022] Specifically, the risk logic template is configured by designing a series of cue word templates to guide the Large Language Model 21 (LLM). The cue word templates include referential resolution templates (such as the specific objects referred to by pronouns like 'he', 'this', and 'that'), metaphor templates (identifying whether there are words in the text that use rhetorical devices such as metaphor and metonymy to implicitly express political stances, such as using 'weather' to metaphorically represent 'political climate'), and context association templates (words that are risk-free when viewed alone, but will have negative political connotations in a specific context (such as when combined with specific events or people).

[0023] LLM is used to perform deep semantic inductive analysis on the acquired censorship corpus. For example, if a post, "That incident has caused quite a stir recently, and the higher-ups seem very nervous," is input into LLM and combined with the template mentioned above, LLM can analyze the following: Implicit expressions: “that thing” (referring to a specific social event that is not explicitly stated); referential terms: “above” (referring to higher-level government or management); risk entities: [“that thing_sensitive_event”, “above_authority”].

[0024] By leveraging a large language model21 to extract entities and relationships from policy documents, it can better handle complex semantics such as ambiguity and irony compared to traditional rule-based or simple BERT models, thus reducing the rate of missed and false queries.

[0025] S2. Convert the extracted political risk entities into semantic vectors, calculate the semantic similarity between different political risk entities, and construct a graph structure based on the semantic similarity. Among them, such as Figure 2 As shown, the semantic similarity is calculated based on cosine similarity or Euclidean distance in the vector space model. The construction of the graph structure based on the semantic similarity specifically includes: S21. When the semantic similarity between two entities involved in political risks is greater than or equal to the preset first threshold, they are determined to be strongly related risk entities, and node fusion operation is performed. S22. When the semantic similarity between two entities involved in political risks is less than the preset second threshold, they are determined to be independent risk entities, and a new graph node is created. S23. When the second threshold ≤ the semantic similarity of the two politically risky entities < the first threshold, it is determined to be a potential risk relationship, and a semantic association edge is established between the nodes corresponding to the two politically risky entities.

[0026] Specifically, the extracted entities (such as "that_incident_sensitive_event" and "above_authority") are converted into high-dimensional vectors V1 and V2 through a pre-trained embedding model (such as BERT), and then cosine similarity or Euclidean distance is used to calculate the similarity between the two entity vectors.

[0027] Wherein, cosine similarity measures the included angle between two vectors in direction. The closer the value is to 1, the more similar the semantics are. The specific calculation formula is: Wherein, is the dot product of vectors, and are the moduli of the two vectors.

[0028] Euclidean distance measures the straight-line distance between two vectors in a multi-dimensional space. The smaller the distance is, the more similar the semantics are. The specific calculation formula is: Wherein, and are the components of the vectors on the th dimension, is the total number of dimensions.

[0029] A first preset threshold (e.g., 0.85) and a second preset threshold (e.g., 0.40) are set, and a graph structure construction strategy is executed according to the calculation result of the above semantic similarity, which is specifically as follows: 1) Node fusion (similarity ≥ 0.85): if the similarity between "above_authority" and "civil_servant_authority" is 0.95 > 0.85, they are determined as strongly associated risk entities, and node fusion is performed. At this time, the two entities are merged into the same graph node, for example "central_government_authoritative_institution", and their associated text corpora are aggregated, which ensures the simplicity and abstraction of the knowledge graph.

[0030] 2) Creating a new node (similarity < 0.40): if the cosine similarity between the new entity "the weather is nice today" and "that_incident_sensitive_event" is only 0.15 < 0.40, it is determined as an independent risk entity, and a brand new node is created for it in the graph, which indicates that the entity has no direct and clear semantic association with other high-risk entities in the current context.

[0031] 3) Establish semantic association edges (0.40 ≤ similarity < 0.85): If the similarity between “that thing_sensitive_event” and “a certain event_protest” is 0.70, it falls within this range and is judged as a potential risk relationship. A directed or unweighted edge is established between the two nodes. The edge attribute can store the similarity value of 0.70, which indicates that there is a potential semantic association, but it is not as close as the fused nodes. This helps to discover hidden association networks in the future.

[0032] This method of node fusion, creation, and edge connection based on explicit mathematical formulas has higher accuracy and interpretability compared to traditional fuzzy methods that rely on manually set rules.

[0033] S3. Store the constructed graph structure into a graph database to form an initial risk knowledge graph. Perform risk propagation analysis on the risk knowledge graph based on graph algorithms to identify risk hotspots and propagation links. The identification of risk hotspots and transmission chains specifically includes: Based on the initial risk knowledge graph in the graph database, graph algorithms are used to analyze risk propagation, identify risk hotspots with high propagation influence, and mine the propagation path and topology of risk information in the graph structure to locate the source and spread channel of risk.

[0034] The graph algorithm includes the PageRank algorithm for calculating node propagation weights and / or a community detection algorithm for discovering high-density propagation clusters.

[0035] Specifically, the constructed graph structure is stored in a graph database (such as Neo4j), and deep analysis is performed using graph algorithms. These algorithms include the PageRank algorithm (which calculates node propagation weights) and community detection algorithms (which identify high-density propagation clusters). The PageRank algorithm is used to identify risk hotspots in the graph. The algorithm assumes that if a high-risk node is linked to another node, then the linked node should also be high-risk. Through iterative calculation, each node is assigned a PageRank value. Nodes with high PageRank values ​​are key hubs or hotspots for risk propagation. For example, the node "_authority" may have a very high PageRank value because it is connected to many nodes. Community detection algorithms (such as the Louvain algorithm) are used to identify risk propagation links. It divides the graph into several clusters. Nodes within a cluster are closely connected, while connections between clusters are sparse. Through community detection, "risk propagation links" and factions can be identified. For example, a group of nodes closely related to "_protest" forms a high-risk community, which clarifies the source and spread channel of risk information.

[0036] S4. The identified risk hotspots and propagation links are fed back to the review system as feedback data to dynamically update the risk classification model, sensitive word library and review rules; The feedback data includes one or more of the following: newly discovered risk entities and their relationships, identified risk propagation path topology, and the evolution trend of hotspot subgraphs.

[0037] Among them, such as Figure 3 As shown, the dynamic updating of the risk classification model, sensitive word database, and review rules specifically includes: S41. Automatically add newly discovered risky entities and entity relationships from the feedback data to the sensitive word database; S42. Optimize the association rules in the audit rule engine by utilizing the risk propagation path topology identified in the feedback data; S43. Adjust the decision boundary of the risk classification model based on the evolution trend of hotspot subplots in the feedback data.

[0038] Specifically, the analysis results are fed back to the review system in the form of feedback, and the risk classification model, sensitive word library and review rules are dynamically updated according to the form of feedback. The feedback data includes one or more of the following: newly discovered risk entities and entity relationships (e.g., the newly extracted entity "a certain statement_coded_phrase" by LLM and its association with "above_authority"), the topology of the identified risk propagation path (e.g., the propagation path from "a certain event_protest" to "related_commenter" and then to "ordinary_netizen" revealed by the community discovery algorithm), and the evolution trend of hotspot subgraphs (e.g., the significant increase trend of PageRank value around the "above_authority" node over time (or after a certain event).

[0039] The dynamic updating mechanism for the risk classification model, sensitive word database, and review rules is as follows: 1) Automatically add sensitive words to the database: Newly discovered risky entities (such as "a certain statement_coded_phrase") are automatically added to the sensitive word database of the review system. This makes up for the deficiency of traditional static databases in being unable to cover new words.

[0040] 2) Optimize review rules: Utilize the risk propagation path topology to update review rules. For example, add a rule that "when a user is discussing that _sensitive_event, if they also mention _authority above, then advanced review will be triggered." This is smarter and more accurate than simple keyword matching.

[0041] 3) Adjust the decision boundary of the classification model: Based on the evolution trend of hotspot subgraphs, retrain or fine-tune the risk classification model. If a behavior pattern that was originally considered low-risk (such as frequent use of a specific meme graph) is found to evolve into the core of a high-risk subgraph in subsequent analysis, the decision boundary of the model can be adjusted to increase the risk level of the pattern.

[0042] By employing an architecture of "deep understanding of the Big Language Model 21 + precise measurement of mathematical expressions + deep analysis of graph algorithms + dynamic updates through closed-loop feedback," the system effectively addresses the challenges of identifying implicit and referential risk entities, the ambiguity of relationship measurement, and the rigidity of the system in traditional political risk identification. Its core computational expression vector similarity calculation and graph algorithms such as PageRank and community detection ensure the quantifiability and verifiability of the method. The introduction of the Big Language Model 21 endows the system with a powerful ability to understand complex human language, enabling the entire system to constitute an intelligent risk prevention and control system capable of self-learning, adaptation, and evolution.

[0043] Example 2 like Figure 4 As shown, another embodiment of the present invention proposes an automatic construction system for a knowledge graph of political risks, comprising: Content access module 1 is used to acquire the corpus data to be reviewed; The semantic analysis module 2, which integrates a large language model 21, is connected to the content access module 1. It is used to configure and dynamically parse the risk logic template of the expression of political risk, and use the large language model 21 to perform in-depth semantic induction analysis on the review corpus to extract political risk entities that include at least implicit expression words and referential words. Vector encoding module 3, which is communicatively connected to the semantic analysis module 2, is used to convert the extracted political risk entities into semantic vectors and calculate the semantic similarity between different political risk entities. The graph fusion management module 4 is communicatively connected to the vector encoding module 3 and is used to construct a graph structure based on the semantic similarity and execute a dynamic fusion strategy. The graph database storage module 5 is communicatively connected to the graph fusion management module 4 and is used to store the constructed graph structure into the graph database to form an initial risk knowledge graph. The graph algorithm analysis module 6 is communicatively connected to the graph database storage module 5 and is used to perform risk propagation analysis on the risk knowledge graph according to the graph algorithm to identify risk hotspots and propagation links. The risk strategy feedback module 7 is communicatively connected to the graph algorithm analysis module 6 and the semantic analysis module 2. It is used to feed back the identified risk hotspots and propagation links as feedback data to the audit system in order to dynamically update the risk classification model, sensitive word library and audit rules.

[0044] In this embodiment, taking the content review scenario of a government new media platform as an example, the specific steps are explained in detail as follows: (1) Reviewing the acquisition of corpus and model pre-setting: First, the content access module 1 obtains the corpus data to be reviewed, such as a user-posted comment: "Their new 'Lighthouse Project' is not as simple as it seems on the surface. Referring to the old example of Country E, in the long run, it may shake our foundations." At the same time, in the semantic analysis module 2, the risk logic template for political fields is pre-configured. The risk logic template contains specific prompt words to guide the large language model 21 to identify referential resolution (such as "they", "that"), metaphors (such as "old example", "Lighthouse Project"), and contextual associations.

[0045] (2) Deep semantic analysis and risk entity extraction: Using a large language model21 (e.g., a model based on GLM-4 or the Generalized Questions model), combined with the aforementioned risk logic template, the corpus is analyzed, and LLM attempts to parse it: "They" refers to an external force or a specific interest group; "Project Lighthouse" is a euphemism for a policy or action that may have negative connotations; "the old precedent of Country E" is a metaphor for a historical event, implying that the plan may lead to adverse consequences.

[0046] Through this in-depth analysis, entities at risk of political involvement were successfully extracted, including explicit terms (such as "external forces" and "country E"), implicit terms (such as "shaking the foundation" and "it's not that simple on the surface"), and referential terms (such as "they" and "that").

[0047] (3) Semantic vector transformation and similarity calculation: The extracted political risk entities are converted into semantic vectors by the vector encoding module 3, and these words are mapped to a high-dimensional vector space using a pre-trained BERT model or similar model. Then, the semantic similarity between different vectors is calculated (based on cosine similarity or Euclidean distance in the vector space model). For example, the semantic similarity between the entities “shaking the foundation” and “regime subversion” is as high as 0.92.

[0048] (4) Construction of dynamic graph structure: The graph fusion management module 4 executes a graph structure construction strategy based on the semantic similarity calculation results (the preset first threshold is 0.90, and the second threshold is 0.35): 1) Since the similarity between “shaking the foundation” and “subversion of the regime” (0.92) is greater than or equal to the first threshold (0.90), it is determined to be a strongly associated risk entity. Node fusion operation is performed, or “shaking the foundation” is directly associated with a specific manifestation of “subversion of the regime” in the graph. 2) The similarity between "Project Lighthouse" and "Economic Sanctions" is calculated to be 0.25, which is less than the second threshold (0.35). They are determined to be independent risk entities, and new graph nodes are created for "Project Lighthouse" and "Economic Sanctions" respectively. 3) The similarity between “E Country” and “Negative Historical Lessons” is calculated to be 0.67, which is between the second threshold (0.35) and the first threshold (0.90). It is determined to be a potential risk relationship. Then, a semantic association edge with a weight (such as 0.67) is established between the two nodes.

[0049] (5) Graph storage and risk propagation analysis: The constructed graph structure is stored in a graph database (such as Neo4j) through the graph database storage module 5. Then, the graph algorithm analysis module 6 is started and uses the PageRank algorithm to calculate the propagation influence of all nodes. It is found that the PageRank value of the "external forces" node is the highest, so it is identified as the current risk hotspot. At the same time, a high-density propagation cluster composed of nodes such as "Lighthouse Project", "E Country Old Example", and "Undermining the Foundation" is discovered using a community detection algorithm (such as the Louvain algorithm). The propagation path is found to be: "External forces" → "Planning the Lighthouse Project" → "Imitating the E Country Old Example" → "Intending to Undermining the Foundation".

[0050] (6) Closed-loop feedback and model update: The risk strategy feedback module 7 feeds the above findings back to the review system as feedback data, dynamically updating the risk classification model, sensitive word library, and review rules, as detailed below: 1) Automatically add newly discovered entities such as "Project Lighthouse" (in this specific context) and "shaking the foundation" to the sensitive word database; 2) Based on the identified propagation path "external forces → planning actions → imitating other countries → shaking the foundation", optimize the review rule engine, for example, by adding new regular expressions or association rules, and trigger a higher level of review when "external forces" and a certain representative item appear in the text at the same time. 3) Based on the evolution trend of hotspot subgraphs (such as a surge in the number of nodes and edge density of the cluster in a short period of time), adjust the decision boundary of the risk classification model and classify such patterns as high-risk categories.

[0051] Through the aforementioned closed loop, when the system encounters similar corpus such as "a certain organization's 'New Path Plan' will erode our consensus, just like the mistakes of country F," it can more accurately and efficiently identify and issue warnings.

[0052] It's worth noting that the PageRank algorithm described above is a link analysis-based method used to assess the relative importance of web pages. Its core principle is as follows: if a web page is linked to by numerous other web pages, it is generally considered a more important or higher-quality resource. The algorithm not only calculates the number of links pointing to the web page but also considers the weight of each linking web page itself—its own PageRank value—as well as the number of links it points to other web pages.

[0053] The Louvain algorithm is a heuristic community detection algorithm based on modularity optimization. It is used to efficiently identify dense community structures in large-scale networks. Through an iterative process of local node movement and community aggregation, it maximizes the internal connection density of the community and minimizes the external connections. It has advantages such as high speed, no need to pre-define the number of communities, and support for hierarchical structures.

[0054] Example 3 Another embodiment of the present invention proposes a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the above-described method for automatically constructing a political risk knowledge graph.

[0055] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.

Claims

1. A method for automatically constructing a knowledge graph of political risks, characterized in that, Includes the following steps: Configure a risk logic template for dynamically parsing expressions of political risks, and use a large language model to perform deep semantic inductive analysis on the acquired review corpus in combination with the risk logic template to extract political risk entities. The political risk entities include at least implicit expressions and referential words. The extracted politically-related risk entities are converted into semantic vectors, the semantic similarity between different politically-related risk entities is calculated, and a graph structure is constructed based on the semantic similarity. The constructed graph structure is stored in a graph database to form an initial risk knowledge graph. Risk propagation analysis is performed on the risk knowledge graph based on graph algorithms to identify risk hotspots and propagation links. The identified risk hotspots and transmission links are fed back to the review system as feedback data to dynamically update the risk classification model, sensitive word library and review rules; The construction of the graph structure based on the semantic similarity specifically includes: When the semantic similarity between two entities involved in political risks is greater than or equal to a preset first threshold, they are determined to be strongly related risk entities, and node fusion operation is performed. When the semantic similarity between two politically risky entities is less than a preset second threshold, they are determined to be independent risky entities, and a new graph node is created. When the second threshold is less than or equal to the semantic similarity between two politically risky entities and less than the first threshold, they are identified as potential risk relationships, and a semantic association edge is established between the nodes corresponding to the two politically risky entities.

2. The method for automatically constructing a knowledge graph of political risks as described in claim 1, characterized in that, The risk logic template includes prompt word templates for identifying referential resolution, metaphor, and contextual association, to guide the large language model to capture implicit risk semantics.

3. The method for automatically constructing a knowledge graph of political risks as described in claim 1, characterized in that, The semantic similarity is calculated based on cosine similarity or Euclidean distance in the vector space model.

4. The method for automatically constructing a knowledge graph of political risks as described in claim 1, characterized in that, The identification of risk hotspots and transmission chains specifically includes: Based on the initial risk knowledge graph in the graph database, graph algorithms are used to analyze risk propagation, identify risk hotspots with high propagation influence, and mine the propagation path and topology of risk information in the graph structure to locate the source and spread channel of risk.

5. The method for automatically constructing a knowledge graph of political risks as described in claim 1 or 4, characterized in that, The graph algorithms include the PageRank algorithm for calculating node propagation weights, and / or a community detection algorithm for discovering high-density propagation clusters.

6. The method for automatically constructing a knowledge graph of political risks as described in claim 1, characterized in that, The feedback data includes one or more of the following: newly discovered risk entities and their relationships, identified risk propagation path topology, and the evolution trend of hotspot subgraphs.

7. The method for automatically constructing a knowledge graph of political risks as described in claim 6, characterized in that, The dynamically updated risk classification model, sensitive word database, and review rules specifically include: Newly discovered risky entities and entity relationships in the feedback data will be automatically added to the sensitive word database; Optimize the association rules in the audit rule engine by utilizing the risk propagation path topology identified in the feedback data; Based on the evolution trend of hotspot subplots in the feedback data, adjust the decision boundary of the risk classification model.

8. An automatic construction system for a political risk knowledge graph, employing the automatic construction method for a political risk knowledge graph as described in any one of claims 1-7, characterized in that, include: The content access module is used to acquire the corpus data to be reviewed; The semantic analysis module, which integrates a large language model and communicates with the content access module, is used to configure and dynamically parse the risk logic template of political risk expression, and to use the large language model to perform in-depth semantic induction analysis on the review corpus to extract political risk entities that include at least implicit expression words and referential words. The vector encoding module, which is communicatively connected to the semantic analysis module, is used to convert the extracted political risk entities into semantic vectors and calculate the semantic similarity between different political risk entities. The graph fusion management module is communicatively connected to the vector encoding module and is used to construct a graph structure based on the semantic similarity and execute a dynamic fusion strategy. The graph database storage module is communicatively connected to the graph fusion management module and is used to store the constructed graph structure into the graph database to form an initial risk knowledge graph. The graph algorithm analysis module is communicatively connected to the graph database storage module and is used to perform risk propagation analysis on the risk knowledge graph according to the graph algorithm to identify risk hotspots and propagation links. The risk strategy feedback module is connected to the graph algorithm analysis module and the semantic analysis module. It is used to feed back the identified risk hotspots and propagation links as feedback data to the review system in order to dynamically update the risk classification model, sensitive word library and review rules.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the method for automatically constructing a political risk knowledge graph according to any one of claims 1-7.