Agent dynamic behavior security test method and system based on risk transmission quantification model
By constructing a behavioral risk correlation graph and a risk rule base, and combining it with a risk transmission quantification model, the behavior of intelligent agents is monitored in real time. This solves the problems of insufficient risk transmission quantification and ambiguous traceability in existing technologies, and improves the efficiency and adaptability of intelligent agent behavior safety testing.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGZHOU ZHANGDONG INTELLIGENT TECH CO LTD
- Filing Date
- 2025-12-16
- Publication Date
- 2026-05-08
AI Technical Summary
Existing intelligent agent behavior safety testing methods lack quantitative analysis of risk transmission, fail to systematically sort out the risk transmission chain, resulting in one-sided and inaccurate risk assessment, vague risk tracing mechanism, delayed intervention response and weak remediation, fixed risk judgment threshold, and weak intelligent adaptation capability.
Based on the risk transmission quantification model, a behavioral risk correlation map is constructed and multi-dimensional risk labeling is performed. A risk rule base is established, and the risk transmission probability and impact range are quantified and calculated through the trained risk transmission quantification model. The behavior trajectory of the intelligent agent is monitored in real time, and risk intervention records are generated to achieve closed-loop optimization of the entire process data.
It enables precise tracing and adaptive optimization of the dynamic behavior of intelligent agents, improves the comprehensiveness and accuracy of risk assessment, enhances the pertinence and intelligent adaptability of risk intervention, and ensures the safe operation of intelligent agents.
Smart Images

Figure CN121349899B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent agent testing technology, specifically to a method and system for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model. Background Technology
[0002] With the rapid development of artificial intelligence technology, intelligent agents have been widely applied in various fields such as financial services, industrial control, and intelligent interaction. Intelligent agents possess the ability to make autonomous decisions and dynamically execute tasks. Their behavior involves multiple stages, including perception input, logical reasoning, resource allocation, and result output, and their behavioral patterns are characterized by dynamism, correlation, and complexity. Against this backdrop, the security testing of the dynamic behavior of intelligent agents has become a crucial aspect of ensuring the stable operation of systems. Existing security testing methods for intelligent agent behavior mainly focus on risk operation identification, fixed rule matching, and single-dimensional risk assessment. The core objective is to discover explicit security vulnerabilities (such as unauthorized access, data leakage, and process violations) in the execution process of intelligent agents. However, existing technologies have the following significant shortcomings in practical applications:
[0003] On the one hand, there is a lack of quantitative analysis of risk transmission, often focusing on the isolated detection of a single risk operation, ignoring the correlation between multiple risk operations and the risk transmission effect. It is impossible to quantify the intensity, scope, and timeliness of risk propagation, resulting in a one-sided and inaccurate risk assessment. On the other hand, the risk tracing mechanism is vague. After a risk is detected, it relies heavily on manual backtracking of behavior logs, lacking a systematic review of the risk transmission chain. It is difficult to quickly locate the initial triggering node and key transmission path of the risk, resulting in delayed intervention response and weak targeted repair. In addition, the risk judgment threshold is mostly a fixed value preset by humans, which cannot be dynamically adjusted according to the actual risk intervention effect and historical risk data. Long-term use is prone to misjudgment and omission, and the intelligent adaptation capability is weak.
[0004] Therefore, there is an urgent need for a security testing method that can adapt to the dynamic behavioral characteristics of intelligent agents, quantify the risk transmission process, accurately trace the source of risks, and achieve adaptive optimization, so as to solve the problems of staticity, one-sidedness, difficulty in tracing the source, and insufficient intelligence of existing technologies, and improve the accuracy, efficiency and adaptability of intelligent agent behavior security testing. Summary of the Invention
[0005] To overcome the shortcomings of existing technologies, this invention provides a method and system for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model, in order to solve the problems in existing technologies.
[0006] One embodiment of the present invention provides a method for testing the dynamic behavior safety of intelligent agents based on a risk transmission quantification model, comprising the following steps:
[0007] Collect behavioral data during the execution of tasks by the intelligent agent, including several risk operation information and the risk correlation between each risk operation information;
[0008] By using several risk operation information as graph nodes and risk correlation as graph edges, a behavioral risk correlation graph is constructed, and risk annotation is performed on the graph nodes. The risk annotation includes risk attribute annotation, risk timeliness factor annotation, and risk transmission intensity annotation.
[0009] Based on the risk labeling results and the preset risk judgment logic, a risk rule base is constructed, which includes risk event triggering conditions and risk level judgment standards.
[0010] Input the behavioral data, behavioral risk correlation graph and risk rule base into the trained risk transmission quantification model, quantify and calculate the risk transmission probability, risk impact range and critical risk node, and output the risk transmission quantification result.
[0011] Based on the risk transmission quantification results and behavioral risk correlation map, the behavior trajectory of the intelligent agent is monitored in real time. When the behavior trajectory of the intelligent agent triggers the preset multi-dimensional risk threshold, the task execution of the intelligent agent is paused and the reasoning chain is traced back to generate a risk intervention record.
[0012] Integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate test reports based on the analysis results.
[0013] This application also relates to a safety testing system for the dynamic behavior of intelligent agents based on a risk transmission quantification model, comprising:
[0014] The data acquisition module is used to collect behavioral data during the execution of tasks by the intelligent agent. The behavioral data includes several risk operation information and the risk correlation between each risk operation information.
[0015] The risk labeling module is used to construct a behavioral risk association graph by taking several risk operation information as graph nodes and risk association relationships as graph edges, and to label the graph nodes with risk. The risk labeling includes risk attribute labeling, risk timeliness factor labeling, and risk transmission intensity labeling.
[0016] The rule base construction module is used to build a risk rule base that includes risk event triggering conditions and risk level judgment criteria based on risk labeling results and preset risk judgment logic;
[0017] The risk calculation module is used to input the behavioral data, behavioral risk correlation graph and risk rule base into the trained risk transmission quantification model, quantify and calculate the risk transmission probability, risk impact range and critical risk node, and output the risk transmission quantification result.
[0018] The backtracking reasoning module is used to monitor the agent's behavior trajectory in real time based on the risk transmission quantification results and the behavioral risk correlation graph. When the agent's behavior trajectory triggers a preset multi-dimensional risk threshold, the agent's task execution is paused and the reasoning chain is backtracked to generate a risk intervention record.
[0019] The report generation module is used to integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate test reports based on the analysis results.
[0020] This application also relates to a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above-described method for testing the dynamic behavior of an intelligent agent based on a risk transmission quantification model.
[0021] This application also relates to a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the above-described method for testing the dynamic behavior of an intelligent agent based on a risk transmission quantification model.
[0022] The above embodiments provide a method and system for testing the dynamic behavior safety of intelligent agents based on a risk transmission quantification model, which has the following beneficial effects:
[0023] This invention constructs a behavioral risk association graph based on risk operations and relationships, performs multi-dimensional risk labeling on nodes and edges, and builds a risk rule base containing triggering conditions and level standards by combining preset judgment logic. Through a trained risk transmission quantification model, it accurately calculates the risk transmission probability, impact range, and critical nodes. This not only overcomes the shortcomings of existing technologies in lacking risk transmission quantification and breaks the limitation of isolated detection of single risks, but also improves the comprehensiveness and accuracy of risk assessment. Furthermore, relying on the temporal and structural features of the graph, it quickly traces back the reasoning chain and locates the initial triggering node after a risk is triggered, replacing the inefficient method of manually tracing logs, solving the problems of ambiguous tracing and delayed response, and enhancing the targeted nature of intervention. Simultaneously, it dynamically optimizes the risk judgment threshold through a closed-loop data process, avoiding false positives and false negatives caused by fixed thresholds, and strengthening intelligent adaptability. This invention effectively addresses the pain points of existing technologies—static, one-sided, difficult to trace, and lacking in intelligence—significantly improving the accuracy, efficiency, and adaptability of intelligent agent behavioral safety testing, adapting to complex risk scenarios, and providing strong support for the safe operation of intelligent agents. Attached Figure Description
[0024] Figure 1 A flowchart of a method for testing the dynamic behavior of an intelligent agent based on a risk transmission quantification model, provided in an embodiment of the present invention;
[0025] Figure 2This is a schematic block diagram of a computer device provided in an embodiment of the present invention. Detailed Implementation
[0026] The technical solutions in the embodiments of the present invention will now be clearly and completely described in conjunction with the accompanying drawings.
[0027] Reference Figure 1 One embodiment of the present invention provides a method for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model, comprising the following steps:
[0028] S10. Collect behavioral data during the execution of the intelligent agent's task, wherein the behavioral data includes several risk operation information and the risk correlation between each risk operation information.
[0029] S20. Construct a behavioral risk association graph by taking several risk operation information as graph nodes and risk association relationships as graph edges, and label the graph nodes with risk, including risk attribute labeling, risk timeliness factor labeling and risk transmission intensity labeling.
[0030] S30. Based on the risk labeling results and the preset risk judgment logic, construct a risk rule base that includes risk event triggering conditions and risk level judgment standards.
[0031] The construction of the pre-set risk assessment logic specifically includes the following steps:
[0032] S301. Extract high-frequency risk transmission paths from the behavioral risk association graph, filter out the associated risk operation combinations whose probability of linkage is greater than or equal to a preset threshold, and organize them into a graph core feature dataset.
[0033] S302. Transform high-frequency risk transmission paths into risk event triggering conditions and define the linkage judgment logic between risk operations.
[0034] S303. Based on the risk transmission intensity labeling of the behavioral risk association graph, set the risk level adjustment rules for the associated risk operation combination. When the risk transmission intensity of the associated edge corresponding to the associated risk operation combination is greater than or equal to the preset intensity threshold, the risk level is adjusted upward accordingly.
[0035] S304. Integrate the core feature dataset of the graph, the risk event triggering conditions, and the risk level adjustment rules to obtain the preset risk judgment logic.
[0036] S40. Input the behavioral data, behavioral risk correlation graph and risk rule base into the trained risk transmission quantification model, quantify and calculate the risk transmission probability, risk impact range and critical risk node, and output the risk transmission quantification result.
[0037] S50. Based on the risk transmission quantification results and behavioral risk correlation graph, monitor the behavior trajectory of the intelligent agent in real time. When the behavior trajectory of the intelligent agent triggers the preset multi-dimensional risk threshold, pause the task execution of the intelligent agent and backtrack the reasoning chain to generate a risk intervention record.
[0038] S60. Integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate a test report based on the analysis results.
[0039] In this embodiment, steps S10-S60 are primarily implemented through agent behavior data collection, construction of a risk-labeled association graph, establishment of a risk rule base, calculation of a risk transmission quantification model, dynamic monitoring and intervention with inference chain backtracking, and multi-dimensional data fusion analysis. This addresses the shortcomings of existing technologies, such as lack of quantitative analysis of risk transmission, ambiguity in risk tracing mechanisms, and fixed risk judgment thresholds. Specifically, this ensures that the dynamic behavior safety testing of agents achieves precise quantification, efficient tracing, and adaptive threshold optimization, thereby improving the accuracy, relevance, and intelligence level of the testing.
[0040] The core of step S10 is to collect behavioral data during the execution of tasks by the intelligent agent, providing basic data support for subsequent risk analysis. Behavioral data refers to the end-to-end data generated by the intelligent agent during perception input, logical reasoning, resource allocation, and result output (such as transaction operation logs of financial intelligent agents and equipment interaction records of industrial control intelligent agents). Specifically, it includes risk operation information and the risk correlation between different risk operation information; risk operation information refers to behavioral records that may cause system security risks (such as "unauthorized access to customer core funds accounts" and "batch export of customer privacy data" in financial scenarios, and "unauthorized modification of production equipment operating parameters" in industrial control scenarios); risk correlation refers to the causal, temporal, or dependent correlation between different risk operation information (such as the temporal correlation of "unauthorized login to employee accounts" → "access to customer funds database" → "batch export of transaction records" in financial scenarios, and the correlation of "unauthorized modification of production equipment operating parameters" in industrial scenarios). The step of establishing a causal relationship between "modifying the pressure threshold" and "equipment overload operation" mainly involves using an intelligent agent behavior log collection module and system interaction monitoring tools (such as network traffic monitoring software and equipment operation recorders) to comprehensively capture risky operations and their correlations during task execution. It should be noted that the specific hardware deployment and interface adaptation techniques for data collection are well-known to those skilled in the art and will not be elaborated upon here. The reason for this operation is that existing technologies mostly focus on detecting individual risky operations and lack the ability to capture correlations. Complete behavioral data is the foundation for subsequent risk transmission links and quantitative analysis. Its beneficial effect is to provide comprehensive and authentic raw data for the construction of risk correlation maps and the formulation of risk rule bases, ensuring the relevance and reliability of subsequent testing.
[0041] The core of step S20 is to construct a behavioral risk correlation graph and complete multi-dimensional risk labeling, transforming dispersed risk operations into a structured correlation network, laying the foundation for risk transmission analysis. The behavioral risk correlation graph is a topological network model with risk operations as nodes and risk correlations as edges (for example, in a financial agent graph, node A represents "unauthorized access to the core transaction database," node B represents "batch export of customer holdings data," and the edge is the "time-series correlation" between A and B). Graph nodes represent individual risk operation information collected in S10; graph edges represent the correlations between risk operations; risk labeling supplements the risk characteristics of graph nodes and edges, specifically including risk attribute labeling, risk timeliness factor labeling, and risk transmission intensity labeling. Risk attribute labeling defines the security characteristics of each risk operation node (e.g., labeling nodes with risk levels and sensitive resource correlations), while risk timeliness factor labeling quantifies the decay characteristics of the impact of risk operations over time. (For example, the impact of high-risk operations will gradually weaken over time.) Risk transmission intensity labeling is a labeling of the ability of risk to be transmitted between nodes through related edges (for example, the probability of risk transmission is higher in some related relationships). This step mainly uses a topology network construction algorithm (such as the Neo4j graph construction tool) to build a graph framework, and then completes the labeling of three types of risks according to preset rules to form a complete structured graph. The reason for this operation is that the existing technology lacks a structured sorting of risk association and transmission characteristics, which makes it impossible to systematically analyze the risk propagation path. However, the labeled association graph can intuitively present the distribution and transmission potential of risks. Its beneficial effect is to integrate scattered risk operations into an analyzable association network. Multi-dimensional labeling provides key parameters for subsequent quantitative calculations, improving the systematicness and accuracy of risk analysis.
[0042] The core of step S30 is to construct a risk rule base based on the graph annotation results and the preset risk judgment logic, providing a standardized basis for risk judgment and quantitative analysis. The risk rule base is a structured set of rules containing risk event triggering conditions and risk level judgment criteria. The preset risk judgment logic is a structured rule system extracted from the core features of the risk association graph, such as high-frequency transmission paths, linkage probabilities, and transmission strength (the core includes three key logics: feature selection, condition transformation, and level adjustment). When extracting the preset risk judgment logic, in addition to selecting high-frequency paths (S301) and transforming triggering conditions (S302), the risk transmission strength of the graph edges (e.g., ≥0.7) must also be used as a screening condition for "whether to include in the core rules": only high-frequency paths with transmission strength exceeding the threshold will enter the subsequent level adjustment stage (S303), ensuring that the rules focus on risk combinations with high transmission potential. Risk event triggering conditions refer to specific behavioral combinations or threshold conditions that trigger safety risks (e.g., [missing information]). "Three consecutive unauthorized accesses to the core module + a batch data export operation triggered within one hour" constitutes a "data breach risk event." The risk level assessment criteria are grading rules that differentiate the severity of risks (e.g., low, medium, high, and extremely high). This step mainly involves extracting high-frequency risk correlation features from the risk graph, converting them into standardized triggering conditions and grading standards, and integrating them into a rule base (e.g., storing risk events and corresponding judgment rules in JSON format). This operation is performed because existing risk assessment technologies often rely on scattered rules and lack unified standards, leading to inconsistent judgment results. A standardized rule base can standardize risk assessment, and its beneficial effect is to provide clear judgment criteria for risk transmission quantification models, ensuring consistency in risk level classification and event identification, and improving the reliability and comparability of test results.
[0043] The pre-defined risk assessment logic is structured through steps S301-S304, focusing on the extraction of high-frequency risk features from the risk map, transformation of trigger conditions, dynamic adjustment of risk levels, and rule integration. This addresses the issues of lack of specificity and low standardization in risk assessment rules, ensuring that the logic aligns with the characteristics of risk correlation and providing a reliable basis for risk assessment. Specifically:
[0044] The core of step S301 is to extract high-frequency risk transmission paths, screen related risk operation combinations, and construct a graph core feature dataset. High-frequency risk transmission paths refer to risk association paths in the behavioral risk association graph that appear more frequently than a preset frequency threshold (e.g., ≥5 times per month); the probability of linkage occurs refers to the probability that all risk operations in a certain association path occur together; the preset threshold is the minimum probability requirement for screening high-risk association combinations (e.g., ≥60%); the graph core feature dataset is a structured dataset that integrates high-frequency, high-probability-of-linkage related risk operation combinations. For example, in the financial agent graph, the path "unauthorized login → database access → data export" appears 8 times per month (exceeding the preset frequency threshold of 5 times), and its linkage probability is 75% (exceeding the preset threshold of 60%), so this operation combination is included in the graph core feature dataset. This step mainly calculates the probability of linkage of related operations by statistically analyzing the frequency of each risk transmission path in the graph, screening out operation combinations that meet both the frequency and probability criteria, and constructing the core feature dataset. This operation is performed because existing technical rules are mostly based on single risk operations and lack attention to high-frequency association combinations, while the core feature dataset can focus on high-risk association patterns. Its beneficial effect is the extraction of high-risk association features from the graph, providing targeted foundational data for subsequent rule generation and improving the accuracy of risk rules.
[0045] The core of step S302 is to transform high-frequency risk transmission paths into risk event triggering conditions and define the linkage judgment logic. Here, a risk event triggering condition refers to the condition that triggers a risk event when an agent performs a combination of operations within a certain high-frequency associated path. For example, the high-frequency path is transformed into the triggering condition: "Complete database access + data export within 1 hour after unauthorized login." The linkage judgment logic refers to the rules for determining whether associated operations constitute a risk event (such as "execute all operations in sequence" or "execute any two or more operations"). Here, the linkage judgment logic is "execute all three operations in sequence to trigger a data leakage risk event." This step mainly analyzes the operation sequence and association logic of high-frequency risk transmission paths, transforming them into standardized triggering conditions and linkage judgment rules. This operation is performed because high-frequency associated paths are the main occurrence patterns of risk events, and transforming them into triggering conditions enables accurate identification of such risks. Its beneficial effect is the generation of highly targeted risk event triggering conditions, ensuring accurate identification of high-frequency risk patterns and improving the targeting of risk judgment.
[0046] The core of step S303 is to set risk level adjustment rules for related risk operation combinations based on risk transmission intensity labeling. These risk level adjustment rules refer to the rules for adjusting the risk event level corresponding to a path based on the risk transmission intensity of the related path. The preset intensity threshold is the minimum transmission intensity requirement to trigger level adjustment (e.g., ≥0.7). Level upgrade means that when the transmission intensity of the related path reaches the threshold, the risk level corresponding to that path is increased by one level from the base level. The base level is the initial level calculated according to the risk attribute labeling of a single core operation in the related risk operation combination (e.g., "Unauthorized Login" is medium risk, "Data Export" is high risk) and preset weights (e.g., the base level of the above path = (medium risk 0.5 + high risk 0.8) ÷ 2 = 0.65, corresponding to a "medium" level). If the risk transmission intensity labeling of the path is 0.85 (exceeding the preset intensity threshold of 0.7), then it is upgraded to "high" risk according to the adjustment rules. This step mainly establishes the association rules between risk transmission intensity and risk level by setting the transmission intensity threshold and the level adjustment range. This operation is performed because existing risk rating methods do not consider the transmission strength of associated paths, leading to inaccurate risk classification. Adjusting the rules allows for a more accurate assessment of the risk level. The beneficial effect is the ability to dynamically adjust risk levels, ensuring that classification is based on both operational combinations and transmission strength, thereby improving the accuracy of risk level determination.
[0047] The core of step S304 is to integrate the core feature dataset, triggering conditions, and adjustment rules to form a preset risk assessment logic. This step mainly uses a data integration algorithm to integrate the core feature dataset from S301, the risk event triggering conditions from S302, and the risk level adjustment rules from S303 to form a structured and standardized preset risk assessment logic. An example of the final integrated logic (in JSON format) is: {“Core Feature Combination”: “Unauthorized Login + Database Access + Data Export”, “Triggering Condition”: “Execution in Sequence + Completion within 1 Hour”, “Level Rule”: “Transmission Intensity ≥ 0.7 → Medium → High”}. This operation is performed because scattered datasets, triggering conditions, and adjustment rules cannot be directly used for risk assessment; only through integration can a complete assessment logic system be formed. Its beneficial effect is the formation of a comprehensive and standardized risk assessment logic, providing a complete basis for the construction of a risk rule base, ensuring the consistency and accuracy of risk assessment, and improving the reliability of subsequent risk analysis.
[0048] The core of step S40 is to analyze behavioral data, behavioral risk correlation graphs, and risk rule bases through a trained risk transmission quantification model, and output quantified risk transmission results. The trained risk transmission quantification model is an algorithmic model with multi-dimensional quantification capabilities (integrating an algorithmic architecture that adapts to the temporal transmission of risk and structural correlation analysis). Core quantification indicators include risk transmission probability, risk impact range, and critical risk nodes. Risk transmission probability is the quantified value of the likelihood of risk propagating from one node to an associated node (e.g., the probability of transmission from node A to node B is 85%). Risk impact range is the range of agent behavior links or system modules that the risk may affect (e.g., affecting 3 core system modules or 5 associated behavior nodes). Critical risk nodes are core nodes that play a key control role in risk transmission (blocking these nodes can significantly reduce the probability of risk propagation). The risk transmission quantification result is a structured output integrating the above three types of quantification indicators. This step mainly involves feeding preprocessed input data into the model, using the model algorithm to calculate the three types of indicators, and outputting the quantification result. This operation is performed because existing technologies lack quantitative analysis of risk transmission, leading to one-sided risk assessments. Quantification models can accurately characterize the characteristics of risk transmission, and their beneficial effect is to achieve a quantitative description of risk transmission, providing accurate decision-making basis for subsequent risk intervention and solving the deficiency of traditional assessments that are "only qualitative and not quantitative."
[0049] The core of step S50 is to monitor the agent's behavioral trajectory in real time based on the risk transmission quantification results and behavioral risk correlation graph. When a preset multi-dimensional risk threshold is triggered, the task is paused and the inference chain is traced back to generate a risk intervention record. Here, the behavioral trajectory is the real-time behavioral sequence during the agent's task execution; the multi-dimensional risk threshold is a risk warning threshold set in conjunction with quantification indicators (covering multi-dimensional judgment standards of core quantification indicators); inference chain tracing refers to tracing back the logical link and initial source of the risk (systematic tracing based on graph annotation features); and the risk intervention record is a structured document recording the risk triggering situation, intervention measures, and results (e.g., risk triggering time, triggering dimension, intervention measures, intervention effect, etc., example: "Risk triggering time: 2025-XX-XX 14:32, triggering dimension: transmission probability 85%+, impact range 3"). The module includes intervention measures such as freezing accounts and intercepting data transmission, with the intervention effect being the termination of risk transmission. This step mainly involves tracking behavioral trajectories through a real-time monitoring module and comparing them with multi-dimensional thresholds. When a threshold is triggered, the task is paused and the source of the risk is traced back, recording the intervention process. This operation is performed because existing technologies suffer from lagging risk intervention and vague source tracing, resulting in the inability to promptly block risks and poor targeted remediation. Real-time monitoring and source tracing, on the other hand, enable precise intervention. Its beneficial effects include real-time risk warning and rapid response, accurate location of the risk source through reasoning chain tracing, improved timeliness of intervention and targeted remediation, and reduced security losses.
[0050] The core of step S60 is to integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate a test report based on the analysis results. The test report is a comprehensive document integrating four types of key data, including core content such as risk distribution, transmission characteristics, intervention effects, and optimization suggestions (example report core content: "Test Overview: 72-hour task execution test of the financial intelligent agent, capturing 12 risky operations and triggering 3 warnings; Risk Analysis: Data security risks accounted for 62%, with critical nodes concentrated in the 'data export' stage; Intervention Effect: Risk blocking success rate 100%; Optimization Suggestions: Strengthen account login IP binding and secondary verification; sensitive data export requires multi-level approval"). This step mainly integrates the four types of data through data fusion algorithms, performs statistical analysis and pattern extraction, and forms a structured test report. This operation is performed because existing technology test results are fragmented and lack systematic summarization, while a comprehensive report can fully reflect the security status of the intelligent agent. Its beneficial effect is to provide users with comprehensive and clear test conclusions, identify the weak links and optimization directions of the intelligent agent's behavioral security, and provide a complete basis for subsequent security reinforcement.
[0051] To more clearly illustrate the implementation process of the overall solution, the following provides a specific feasible implementation example in the context of a financial intelligent agent, assuming that a financial intelligent agent is performing customer asset query and data processing tasks:
[0052] The S10 uses an intelligent log parsing system and network traffic monitoring tools to accurately capture complete behavioral data such as "unauthorized login to administrator account (non-working hours 14:20) → unauthorized query of 500 customer holding data → batch export of 300 customer ID numbers + bank card numbers", as well as risk correlations of "time-series correlation + dependency correlation".
[0053] S20 constructs a graph by treating the three types of operations as independent nodes and the temporal relationships as directed edges, thus completing multi-dimensional risk labeling: risk attribute labeling ("Unauthorized login" high risk 3, sensitive resource correlation 0.9; "Unauthorized query" high risk 3, correlation 0.85; "Batch export" high risk 3, correlation 0.87); and time factor labeling (8 hours after the export operation, because it belongs to the long-term impact risk category, the time factor = 3 × ≈2.52); Conduction intensity label (“Unauthorized login → Unauthorized query” intensity 1.06, “Unauthorized query → Batch export” intensity 1.15).
[0054] S30 constructs a risk rule base based on the high-frequency path (occurring 6 times per month) of "login-query-export" in the graph and its transmission intensity: the trigger condition is "unauthorized login + unauthorized query + data export completed continuously within 1 hour", and the level adjustment rule is "the initial basic level is high risk, and if the transmission intensity is ≥0.7, it will be upgraded to extremely high risk".
[0055] S40 inputs behavioral data, labeled graphs, and rule bases into a trained fusion model. The dynamic Bayesian network calculates the propagation probability based on temporal features (unauthorized login → unauthorized query 83%, unauthorized query → batch export 79%). The graph neural network defines the scope of influence based on the topology (three core modules: customer asset database, data export service, and external interface communication), and finally outputs the critical node "unauthorized query".
[0056] The S50 detected a propagation probability deviation of 10.67% (beyond the critical value of 10%) through the real-time monitoring module and immediately suspended the agent's data export permission. Combining the graph timeliness factor (unauthorized login timeliness factor 2.53) and the propagation strength, the path confidence was calculated to be 1.79 ≥ threshold 1.2, accurately tracing back to the "unauthorized login administrator account" as the source of risk, freezing the violating account and intercepting data transmission, and generating a standardized intervention record.
[0057] The S60 integrates behavioral data, graph annotations, quantitative results, and intervention records to generate a test report. Core data shows that "three high-risk events were captured during the test, with a 100% intervention success rate and a 0% false alarm rate." Targeted recommendations include "strengthening account IP binding and secondary verification, requiring multi-level approval for sensitive data export, and automatically triggering security audits when logging in outside of working hours." The entire process achieves a closed loop from accurate risk capture and multi-dimensional quantitative analysis to rapid intervention, effectively protecting the behavioral security of financial intelligent agents and customer data privacy.
[0058] It should be noted that the high-frequency path determination frequency, linkage probability threshold, intensity threshold, level adjustment range, risk operation type, correlation form, annotation parameters, rule base content, quantitative indicator range, threshold setting, and report presentation format in the above examples are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the high-frequency path screening criteria, linkage probability threshold, intensity threshold setting, level adjustment rules, logical integration method, behavioral data collection dimensions, graph construction parameters, rule base determination logic, model algorithm details, threshold settings, and report presentation format can be flexibly adjusted according to the actual situation such as the intelligent agent application scenario (financial services, industrial control, intelligent interaction, etc.), system security requirements, and risk type characteristics. All of these can achieve the purpose of constructing a preset risk determination logic that fits the risk correlation characteristics and conducting quantitative security testing, accurate tracing, and adaptive intervention for the dynamic behavior of intelligent agents.
[0059] In one embodiment, step S20 specifically includes the following steps:
[0060] S210. Using several risk operation information as graph nodes and risk correlation relationships as graph edges, a preliminary topological structure of the behavioral risk correlation graph is constructed.
[0061] S220. Mark the risk attributes of the graph nodes, wherein the risk attributes include the risk level and the degree of correlation with sensitive resources;
[0062] S230. Mark the risk timeliness factor on the map node. The risk timeliness factor is calculated by multiplying the initial risk level quantification value by the time decay coefficient.
[0063] S240. Mark the risk transmission intensity of the edges of the graph. The risk transmission intensity is calculated by multiplying the probability of the associated risk operation corresponding to each edge of the graph to be marked by the linkage hazard amplification coefficient.
[0064] S250. Integrate the topological structure and risk labeling results of the behavioral risk association map to form a complete behavioral risk association map.
[0065] In this embodiment, the core of step S210 is to initially construct the topology of the behavioral risk association graph and build the basic network framework of the graph. The topology refers to the undirected or directed network skeleton with risk operations as nodes and risk associations as edges; several risk operation information refers to the specific risk behavior records collected in S10 (such as "unauthorized login" and "batch export of customer data" in financial scenarios, and "unauthorized modification of equipment parameters" and "unauthorized start / stop of modules" in industrial scenarios); risk associations refer to the temporal, causal, or dependent associations between various risk operations (such as the temporal association of "unauthorized login → batch export of customer data"). This step mainly uses topology network construction tools (such as Neo4j and ArangoDB) to map each risk operation information into an independent node and transform risk associations into connecting edges between nodes, forming a preliminary network topology (for example, in the financial intelligent agent graph, node 1 is "unauthorized login", node 2 is "unauthorized asset query", node 3 is "batch export of data", edge 1-2 corresponds to "temporal association", and edge 2-3 corresponds to "dependent association").
[0066] The core of step S220 is to label the risk attributes of the graph nodes and clarify the inherent security characteristics of each risk operation node. Specifically, risk attributes include risk level and sensitivity resource correlation. Risk level is a grading standard based on the severity of security losses that a risky operation may cause (e.g., low, medium, high, and extremely high, corresponding to quantitative values 1, 2, 3, and 4). Judgment requires consideration of the type of security loss (data breach / resource waste, etc.), the scope of impact (single node / entire system, etc.), and recovery costs. Sensitive resource correlation is the degree of connection between the resources involved in the risky operation and the system's core sensitive resources (e.g., customer privacy data, device control permissions, core transaction interfaces), quantified using a 0-1 range. Its evaluation model uses a weighted calculation based on three dimensions: resource confidentiality level, resource access permission requirements, and resource impact scope. The weighting formula is: Correlation = (Confidentiality Level × 0.4 + Access Permissions × 0.3 + Impact Scope × 0.3). For example, in a financial scenario, "unauthorized export of customer ID numbers + historical transaction records" falls under the risk level judgment standard of "data breach + system-wide impact + high recovery costs," corresponding to high risk (quantitative value 3). Its sensitive resource correlation is calculated... The value is 0.87 (Confidentiality level 0.9 × 0.4 + Access requirements 0.8 × 0.3 + Scope of impact 0.9 × 0.3 = 0.36 + 0.24 + 0.27). It should be noted that the specific number of risk level classifications, the selection and weighting of judgment dimensions, and the combination of dimensions, weighting coefficients, and quantification rules of the sensitive resource correlation assessment model can be flexibly adjusted by those skilled in the art based on the actual situation of intelligent agent application scenarios (financial services, industrial control, intelligent interaction, etc.), system security requirements, and risk type characteristics, without being limited to the above exemplary settings. For further examples, "unauthorized login to the core system" (data leakage + system-wide impact + high recovery cost) is judged as high risk (quantification value 3), and "temporary over-limit call to computing resources" (resource waste + single-department impact + low recovery cost) is judged as medium risk (quantification value 2). The sensitive resource correlation of "querying publicly available industry data" is calculated as 0.1 × 0.4 + 0.2 × 0.3 + 0.2 × 0.3 = 0.04 + 0.06 + 0.06 = 0.16.
[0067] The core of step S230 is to label the map nodes with risk duration factors to quantify the characteristics of risk operation impact decay over time. The risk duration factor is a quantitative indicator reflecting the duration and decay rate of risk impact, calculated by multiplying the initial risk level quantification value by a time decay coefficient. The initial risk level quantification value is the quantification value corresponding to the risk level in step S220 (e.g., low=1, medium=2, high=3, extremely high=4). The time decay coefficient is a coefficient that decreases over time based on the risk type (short-term impact risks decay quickly, coefficient such as 0.92 / hour; long-term impact risks decay slowly, coefficient such as 0.98 / hour). The risk type classification based on the time decay coefficient refers to the "impact duration" of the risk operation. "① Short-term impact risks (such as temporary over-limit use of computing resources, the impact of which ends when the resources are released), with a decay coefficient set at 0.92 / hour; ② Long-term impact risks (such as leakage of customer privacy data, the impact of which continues), with a decay coefficient set at 0.98 / hour. The classification criteria can be combined with industry security standards (such as the definition of the impact of data leakage in the Data Security Law). For example, in financial scenarios, "bulk export of customer privacy data" is a high-risk activity (initial quantification value 3), belonging to the long-term impact risk category, with a time decay coefficient of 0.98 / hour. The risk duration factor 8 hours after the operation occurs = 3 ×" The value is approximately 2.52, indicating that the risk impact gradually weakens over time. This step mainly involves obtaining the occurrence time, duration, and risk type of the risk operation, and then calculating and labeling the risk timeliness factor for each node in conjunction with the preset time decay coefficient.
[0068] The core of step S240 is to label the risk transmission intensity of the edges in the graph, quantifying the ability of risk to be transmitted between associated nodes. Risk transmission intensity is a comprehensive quantitative indicator that measures the probability and amplification degree of risk transmission from one node to another through associated edges. It is calculated by multiplying the probability of a linked risk operation corresponding to each edge by a linkage harm amplification coefficient. The probability of a linked operation refers to the probability that another associated risk operation (target node) will occur after a certain risk operation (source node) occurs (based on historical risk data statistics). For example, the probability of a linked operation ("unauthorized login" (source node) followed by "unauthorized asset query" (target node) is 0.76. The linkage harm amplification coefficient refers to the amplification factor of the overall harm when two associated risk operations occur together compared to when a single operation occurs independently (no amplification = 1.0, slight amplification = 1.2, significant amplification = 1.5, severe amplification = 2.0). For example, the linkage harm amplification coefficient for "unauthorized login + unauthorized asset query" is 1.4, and the risk transmission intensity of this edge = 0.76 × 1.4 ≈ 1.06.
[0069] The core of step S250 is to integrate the topological structure of the behavioral risk association graph with various risk labeling results to form a complete and usable behavioral risk association graph. This step mainly uses data integration algorithms (such as structured data binding technology) to bind the topological structure (the relationship between nodes and edges) constructed in S210 with the risk attribute labeling in S220, the risk timeliness factor labeling in S230, and the risk transmission intensity labeling in S240 one by one, so that each node contains both inherent security attributes and time decay characteristics, and each edge contains a quantitative value of risk transmission capability (for example, the information of the integrated node "unauthorized login" is: high risk level (3), sensitive resource correlation degree 0.9, risk timeliness factor 2.52; the information of the edge "unauthorized login → unauthorized query of assets" is: risk transmission intensity 1.06).
[0070] The steps S210-S250 described above, through a progressive process of "topology construction → multi-dimensional risk labeling of nodes → edge characteristic quantification → full information integration," systematically solve the problems of lack of structured presentation of risk associations, lack of precise quantification of risk characteristics, and neglect of time dimension and transmission capability in existing technologies. Ultimately, a complete behavioral risk association graph is formed, combining topological association logic with multi-dimensional risk characteristics. This provides standardized risk feature data for the subsequent S30 risk rule base construction and core input parameters such as node attributes, time decay, and transmission strength for S40 risk transmission quantification calculation, effectively improving the systematicness, accuracy, and dynamic adaptability of intelligent agent dynamic behavior safety testing. It should be noted that the topology construction tools, risk level classification standards, sensitive resource association values, time decay coefficients, probability of linkage occurrence, linkage hazard amplification coefficients, and calculation results in the above example are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the topology construction tools, risk attribute labeling dimensions, level quantification rules, attenuation coefficient values, linkage probability statistics methods, amplification coefficient settings, and integration algorithms can be flexibly adjusted according to the actual situation of intelligent agent application scenarios (financial services, industrial control, intelligent interaction, etc.), risk type characteristics, system security requirements, etc., so as to achieve the purpose of constructing behavioral risk association graphs with complete risk labels.
[0071] In one embodiment, the construction of the trained risk transmission quantification model specifically includes the following steps:
[0072] S401. A risk transmission quantification model is constructed by adopting a fusion architecture of dynamic Bayesian network and graph neural network, with risk transmission probability, risk impact range and critical risk node as the core quantitative indicators.
[0073] S402. Collect agent behavior logs, risk event history records and system topology data, and preprocess the data according to preset rules to obtain a risk operation feature parameter vector that adapts to the input requirements of the fusion architecture.
[0074] S403. Input the risk operation feature parameter vector into the risk transmission quantification model, train the risk time-series transmission logic based on the dynamic Bayesian network, and train the risk structure correlation analysis logic based on the graph neural network, so that the risk transmission quantification model can be adapted to the calculation requirements of different core quantification indicators respectively.
[0075] S404. Establish a fusion and interaction mechanism between dynamic Bayesian networks and graph neural networks, and optimize the parameters of the risk transmission quantification model by combining the risk level judgment criteria in the risk rule base.
[0076] S405. Based on the optimized risk transmission quantification model, a trained risk transmission quantification model is obtained, which is used to quantify the risk transmission probability, the scope of risk impact, and the critical risk node, and outputs the risk transmission quantification results.
[0077] In this embodiment, the core of step S401 is to determine the model fusion architecture and core quantitative indicators, and to build the basic framework of the risk transmission quantitative model. The fusion architecture refers to the collaborative working structure of a dynamic Bayesian network and a graph neural network: the dynamic Bayesian network excels at processing time-series data and characterizing the transmission patterns of risk over time, while the graph neural network excels at mining network topology features and analyzing the structural correlation logic of risks. The two complement each other to meet the multi-dimensional computational needs of the model. The core quantitative indicators are defined as the probability of risk transmission, the scope of risk impact, and critical risk nodes, corresponding to the quantitative requirements of "risk transmission probability," "risk impact range," and "key nodes for risk control," respectively. This step mainly uses algorithm architecture design tools (such as TensorFlow and PyTorch's custom architecture modules) to clarify the functional division of labor and data interaction interfaces between the two networks. For example, in the financial intelligent agent model, the dynamic Bayesian network is responsible for tracking the time-series transmission process of "unauthorized login → data export," while the graph neural network is responsible for analyzing the system module correlation structure involved in this path, jointly supporting the calculation of the three core indicators.
[0078] The core of step S402 is to collect multi-source training data and complete preprocessing to generate input feature vectors that adapt to the fusion architecture. The collected data includes agent behavior logs (such as account operation sequences of financial agents and equipment call records of industrial agents), risk event history records (such as operation links of past data leakage events and trigger trajectories of equipment failure risks), and system topology data (such as connection relationship diagrams between agents and core databases and external interfaces). The preset preprocessing rules include data cleaning (removing invalid and redundant records in logs, such as repeated normal query operations), data standardization (unifying the dimensions of timestamps and risk level quantification values of different formats), and feature extraction (extracting key features such as "operation type, execution duration, and accessed resources" from behavior logs, and extracting structural features such as "node association density and path length" from topology data). The final risk operation feature parameter vector is multi-dimensional structured data. For example, a feature vector example for a financial scenario is: [operation type (unauthorized login = 3), execution time (14:32), sensitive resource association degree (0.9), number of node associations (5), historical linkage probability (0.76)], ensuring that the temporal feature input of dynamic Bayesian networks and the structural feature input requirements of graph neural networks can be met at the same time.
[0079] The core of step S403 is to train the model logic using sub-networks, enabling the model to adapt to the computational needs of different core indicators. This step inputs the preprocessed risk operation feature parameter vectors into the model, training the risk temporal transmission logic based on a dynamic Bayesian network: focusing on the temporal sequence, duration, and decay patterns of risk operations, learning the temporal transmission probability of "source node risk → associated node risk" (e.g., training the model to calculate the transmission probability of "data export triggered within 1 hour after unauthorized login"); and training the risk structure association analysis logic based on a graph neural network: focusing on the node connections, module distribution, and path characteristics of the risk association graph, learning the logic for defining the scope of risk impact and identifying critical nodes (e.g., training the model to determine the number of system modules that may be affected by the risk through node association density and the proportion of core paths). Through sub-module training, the dynamic Bayesian network is primarily adapted to the calculation of risk transmission probabilities, while the graph neural network is primarily adapted to the definition of the scope of risk impact. Both work together to support the identification of critical risk nodes, ensuring that each core indicator has targeted algorithmic logic support.
[0080] The core of step S404 is to establish a network fusion and interaction mechanism, and optimize model parameters in conjunction with a risk rule base. This fusion and interaction mechanism refers to the logical rules for mutual feedback and weighted integration of the computational results of the two networks. For example, the temporal propagation probability output by the dynamic Bayesian network provides weights for the structural association analysis of the graph neural network (paths with higher propagation probabilities are given higher priority in structural analysis); the node association importance output by the graph neural network provides a basis for the temporal logic optimization of the dynamic Bayesian network (the temporal propagation weights of core structural nodes can be appropriately increased). The data flow logic of the fusion and interaction mechanism is as follows: ① The risk propagation probability output by the dynamic Bayesian network (e.g., A→B=83%) is used as the weight for the "node association importance" analysis in the graph neural network (nodes with higher propagation probabilities have their weight increased by 2% in structural analysis). 0%); ② The node association density output by the graph neural network (e.g., the association degree of node B is 0.9) is fed back to the dynamic Bayesian network to adjust its temporal state transition matrix (the temporal transmission weight of nodes with high association density is increased by 15%), realizing bidirectional data collaboration; at the same time, combined with the risk level judgment criteria in the risk rule base (e.g., the transmission probability threshold and the impact range threshold of high-risk events), the model parameters (e.g., the state transition probability matrix of the dynamic Bayesian network and the node feature weights of the graph neural network) are iteratively optimized through the gradient descent algorithm. For example, when the high-risk path transmission probability calculated by the model deviates from the standard deviation of the rule base by more than 10%, the weight parameters of the network are automatically adjusted to ensure that the model output is consistent with the judgment criteria of the risk rule base.
[0081] The core of step S405 is to output the trained risk transmission quantification model, clarifying its application scenario and output format. This step uses a validation dataset (20% of the reserved multi-source training data) to perform performance testing on the optimized model. When the model's calculated risk transmission probability error is ≤5%, the accuracy of defining the scope of influence is ≥90%, and the accuracy of identifying critical nodes is ≥85%, the model training is considered complete. The trained model can be directly used for dynamic behavior safety testing of intelligent agents. After inputting behavioral data, risk association graphs, and risk rule bases, it can quickly quantify and output the results of the three core indicators. For example, the model output example for an industrial intelligent agent is: {"Risk transmission probability": {"Unauthorized parameter modification → equipment overload": 82%}, "Risk impact scope": {"System modules": 2 (production control module, fault early warning module), "Associated nodes": 4}, "Critical risk node": "Unauthorized parameter modification"}, providing accurate quantitative basis for subsequent risk intervention.
[0082] The steps S401-S405 described above, through a progressive process of "architecture design → data preprocessing → sub-network training → fusion optimization → model output," systematically solve the problems in existing technologies where a single algorithm model cannot simultaneously handle risk temporal transmission and structural correlation analysis, the model input data adaptability is poor, and parameters are not optimized in conjunction with risk rules. The resulting trained risk transmission quantification model possesses both the ability to accurately calculate the temporal probability of risk transmission and the ability to clearly define the scope of risk impact and identify critical nodes in structural analysis. This provides high-performance, highly adaptable algorithmic support for the risk quantification calculation in S40, effectively improving the quantification accuracy and efficiency of intelligent agent dynamic behavior safety testing. It should be noted that the fusion architecture algorithm, data acquisition type, preprocessing rules, interaction mechanism logic, and model performance indicators in the above example are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the algorithm architecture combination, training data source, preprocessing process, interaction mechanism design and parameter optimization strategy can be flexibly adjusted according to the actual situation of the intelligent agent application scenario (financial services, industrial control, intelligent interaction, etc.), the accuracy requirements of core quantitative indicators, and data resources. All of these can achieve the goal of building a risk transmission quantitative model with multi-dimensional quantitative computing capabilities.
[0083] In one embodiment, step S40 specifically includes the following steps:
[0084] S410. Perform data preprocessing on the behavioral data, behavioral risk association map and risk rule base according to preset rules to obtain the current feature parameter vector;
[0085] S420. Input the current feature parameter vector and the risk transmission intensity label in the behavioral risk association map into the trained risk transmission quantization model, and calculate the risk transmission probability through dynamic Bayesian network quantization.
[0086] S430. Based on the risk transmission probability and the risk level determination criteria in the risk rule base, the scope of risk impact is defined by a graph neural network.
[0087] S440. Combining the probability of risk transmission with the scope of risk impact, critical risk nodes are identified through the fusion and interaction mechanism of dynamic Bayesian networks and graph neural networks.
[0088] S450 integrates the probability of risk transmission, the scope of risk impact, and critical risk nodes to obtain and output the quantitative results of risk transmission.
[0089] In this embodiment, the core of step S410 is to preprocess the multi-source input data to generate the current feature parameter vector for the adaptive model calculation. The preprocessing objects include the behavioral data collected in step S10 (such as the operation logs of financial intelligent agents and the equipment interaction records of industrial intelligent agents), the behavioral risk association graph constructed in S20 (including node annotations and edge transmission strength information), and the risk rule base built in S30 (including triggering conditions and level standards). The preset rules specifically include data cleaning (removing invalid and redundant records, such as duplicate normal permission operation logs and incorrectly formatted graph node information) and data standardization (unifying indicators of different dimensions such as risk transmission strength and risk level to the [0,1] interval, transforming unstructured associations into...). The structured adjacency matrix and feature fusion (extracting "operation time sequence, resource type" features from behavioral data, "node association density, edge transmission strength" features from the graph, and "risk level threshold, trigger condition weight" features from the rule base) result in a multi-dimensional structured feature parameter vector. For example, a feature vector example for a financial scenario is: [operation type (unauthorized export = 4), risk transmission strength (1.12), risk level threshold (high = 3), number of node associations (6), historical linkage probability (0.85)], ensuring that the input requirements of dynamic Bayesian networks and graph neural networks are met simultaneously.
[0090] The core of step S420 is to input the model to calculate the risk transmission probability, focusing on quantifying the temporal transmission possibility of risk between related nodes. The input data includes the current feature parameter vector obtained in S410, and the risk transmission strength label for each edge in the behavioral risk association graph (e.g., the transmission strength of the edge "Unauthorized Login → Data Export" is 1.01). The core function of the dynamic Bayesian network is to utilize its temporal modeling capabilities, combining the operational temporal features and transmission strength labels in the feature vector, to learn the transmission pattern of risk over time and calculate the transmission probability between adjacent nodes. For example, in a financial intelligent agent scenario, after inputting the feature vector [Operation Type = 4, Transmission Strength = 1.01, Level Threshold = 3, Number of Associations = 6, Linkage Probability = 0.85] into the model, the dynamic Bayesian network analyzes the temporal logic of "Unauthorized Login → Unauthorized Query → Data Export" and outputs a quantitative result of 83% transmission probability for A→B and 79% transmission probability for B→C, accurately characterizing the temporal transmission characteristics of risk.
[0091] The core of step S430 is to define the scope of risk impact using a graph neural network based on transmission probability and rule base standards. The definition criteria include the risk transmission probability calculated in S420 (a higher transmission probability indicates a greater likelihood of the impact spreading) and the risk level judgment standards in the risk rule base (such as the impact scope threshold corresponding to high-risk events). Graph neural networks excel at mining topological features. By analyzing the node connections and module distribution in the behavioral risk correlation graph, they identify the intelligent agent behavior links and system modules that the risk may affect. For example, in an industrial intelligent agent scenario, when the transmission probability of "unauthorized parameter modification → equipment overload" reaches 82% (exceeding the high-risk threshold of 75% in the rule base), the graph neural network analyzes the topological connections of the production control module, fault warning module, and data acquisition module involved in this path, defining the scope of risk impact as "3 core system modules + 5 related behavioral nodes," thus clarifying the boundary of risk spread.
[0092] The core of step S440 is to identify critical risk nodes by integrating the computational results of the two types of networks through a fusion interaction mechanism. The fusion and interaction mechanism refers to the logic of weighting the temporal transmission probability output by the dynamic Bayesian network with the structural correlation importance output by the graph neural network (e.g., transmission probability weight 0.6, structural importance weight 0.4). The identification criterion for critical risk nodes is "after blocking the node, the risk transmission probability decreases by ≥50% and the impact range is reduced by ≥40%". The judgment threshold for critical risk nodes (transmission probability decreases by ≥50%, impact range is reduced by ≥40%) is based on historical risk intervention data: statistics from 100 successful intervention cases show that after blocking the "critical node", the risk transmission probability decreases by an average of 58%. Therefore, the threshold is set at 50% to ensure that the judgment criteria are consistent with the actual intervention effect. For example, in a financial scenario, combining the A→B transmission probability of 83% (temporal result) and the structural correlation degree of node B of 0.9 (topological result), after fusion calculation, node B (over-authority query) is judged as a critical risk node. Model calculation shows that after blocking the node, the transmission probability of B→C decreases from 79% to 9%, and the risk impact range is reduced by 65%, which meets the judgment criteria for critical nodes.
[0093] The core of step S450 is to integrate three core quantitative indicators to output structured quantitative results of risk transmission. This step structurally integrates the risk transmission probability from S420, the risk impact range from S430, and the critical risk nodes from S440 to form quantitative results containing specific values, range boundaries, and core nodes. The output format is standardized structured data, such as the output example (JSON format) for a financial intelligent agent scenario: {"Risk Transmission Probability": {"Unauthorized Login → Unauthorized Query": 83%, "Unauthorized Query → Data Export": 79%}, "Risk Impact Range": {"System Modules": 3 (Customer Asset Database, Data Export Service, External Interface Communication), "Behavioral Nodes": 5 (Account Authentication, Permission Verification, Data Read / Write, Transmission Verification, Log Recording)}, "Critical Risk Node": "Unauthorized Query of Customer Assets (Node ID: FIN-B-002)"}, ensuring that the output results are clear and can be directly used for subsequent risk intervention decisions.
[0094] The steps S410-S450 described above, through a progressive process of "data preprocessing → propagation probability calculation → impact range definition → critical node identification → result integration," systematically solve the problems of lack of temporal and structural collaborative analysis and fragmented, unstructured presentation of results in existing risk quantification calculations. Leveraging the fusion advantages of dynamic Bayesian networks and graph neural networks, they achieve accurate quantification and integrated output of risk propagation probability, impact range, and critical nodes. This provides a directly applicable and accurate decision-making basis for dynamic monitoring and risk intervention in S50, effectively improving the quantification depth and intervention targeting of intelligent agent dynamic behavior safety testing. It should be noted that the preprocessing rules, model calculation logic, quantification result format, and critical node judgment criteria in the above example are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the preprocessing process, model input parameters, impact range definition dimensions, critical node judgment thresholds, and output result formats can be flexibly adjusted according to the actual situation of the intelligent agent application scenario (financial services, industrial control, intelligent interaction, etc.), system security requirements, and risk type characteristics, all of which can achieve the goal of accurately outputting risk propagation quantification results.
[0095] In one embodiment, step S50 specifically includes the following steps:
[0096] S510. Based on the risk level determination criteria and system security requirements in the risk rule base, a three-dimensional risk threshold matrix is constructed. The three-dimensional risk threshold matrix includes a risk transmission probability threshold, a risk impact range threshold, and a critical risk node association density threshold. The critical risk node association density is calculated by the coupling coefficient between the risk transmission intensity and the risk impact range.
[0097] S520. Through the fusion and interaction mechanism of the trained risk transmission quantification model, the risk transmission quantification results are compared with the three-dimensional risk threshold matrix, and the risk deviation of each dimension is calculated respectively.
[0098] S530: Real-time monitoring of the agent's behavior trajectory. When the risk deviation of any dimension of the behavior trajectory exceeds the preset threshold, or when two or more dimensions reach the preset warning threshold at the same time, the risk warning condition is triggered.
[0099] S540: Pause the agent's task execution, and based on the risk timeliness factor labeling and risk transmission intensity labeling of the behavioral risk correlation graph, backtrack the agent's behavioral reasoning chain to locate the risk triggering source;
[0100] S550: Record the risk trigger dimensions, risk trigger sources, intervention time and intervention measures, and generate risk intervention records;
[0101] S560. Based on the risk intervention effect and historical risk data, the parameters of the three-dimensional risk threshold matrix are adaptively adjusted through the trained risk transmission quantification model.
[0102] In this embodiment, the core of step S510 is to construct a three-dimensional risk threshold matrix and clarify the multi-dimensional judgment criteria for risk warning. The three-dimensional risk threshold matrix is a quantitative judgment system built upon risk level judgment criteria based on a risk rule base (e.g., a transmission probability threshold of 75% for high risk) and system security requirements (e.g., the data security requirements for financial industry clients are higher than in ordinary scenarios). Specifically, it includes a risk transmission probability threshold (a critical value measuring the likelihood of risk transmission), a risk impact range threshold (a critical value defining the boundary of risk diffusion, e.g., the number of system modules ≤ 3), and a critical risk node association density threshold (a critical value judging the degree of risk aggregation at critical nodes). The critical risk node association density is calculated as a coupling system between risk transmission intensity and risk impact range. The coupling coefficient is calculated as (mean risk transmission intensity × 0.5 + quantified risk impact range × 0.5). For example, if the mean transmission intensity of a certain risk path is 1.08 and the quantified impact range is 3 (corresponding to 3 modules), then the correlation density is (1.08 × 0.5 + 3 × 0.5) = 2.04, with a preset correlation density threshold of 2.0. The final constructed three-dimensional risk threshold matrix example (financial scenario) is: {"Risk transmission probability threshold": 75%, "Risk impact range threshold": 3 system modules, "Critical risk node correlation density threshold": 2.0}, providing a clear basis for subsequent risk deviation calculation and early warning triggering.
[0103] The core of step S520 is to compare the quantification results with the threshold matrix and calculate the risk deviation of each dimension. Among them, the risk deviation is an indicator that measures the degree of deviation between the actual risk quantification value and the corresponding threshold. It is calculated as (actual quantification value - threshold) / threshold × 100% (positive deviation indicates risk exceeding the standard, negative deviation indicates compliance). The fusion and interaction mechanism of the trained risk transmission quantification model is responsible for coordinating the comparison logic of different dimensions: the dynamic Bayesian network focuses on the comparison of risk transmission probability related to time series, and the graph neural network focuses on the comparison of influence range and association density related to structure. For example, the risk transmission quantification result (transmission probability 83%, influence range 3 modules, association density 2.04) is compared with the above threshold matrix to calculate the deviation of each dimension: transmission probability deviation = (83% - 75%) / 75% × 100% ≈ 10.67%, influence range deviation = (3 - 3) / 3 × 100% = 0%, association density deviation = (2.04 - 2.0) / 2.0 × 100% = 2%, clearly quantifying the risk exceeding the standard in each dimension.
[0104] The core of step S530 is to monitor behavioral trajectories in real time and clarify the risk warning trigger conditions. Real-time monitoring involves tracking the agent's operation sequences and resource usage behavior through behavioral trajectory collection modules (such as real-time log analysis tools and real-time network traffic monitoring systems). Preset thresholds are extreme thresholds for triggering emergency intervention (e.g., deviation ≥ 10%), and preset warning thresholds are regular thresholds for triggering reminder-style warnings (e.g., deviation ≥ 5%). Trigger conditions are divided into two categories: first, any dimension's risk deviation exceeds the threshold (e.g., propagation probability deviation ≥ 10.67%); second, two or more dimensions simultaneously reach the warning threshold (e.g., propagation probability deviation 8% + correlation density deviation 6%, both ≥ 5%). For example, if a financial agent monitors the behavioral trajectory of "unauthorized login → unauthorized query → data export" in real time, corresponding to a propagation probability deviation exceeding the threshold of 10.67%, it determines that the risk warning condition has been triggered and initiates the intervention process.
[0105] The core of step S540 is to pause task execution and backtrack the reasoning chain to accurately locate the source of the risk trigger. This step first suspends the agent's task execution permissions (such as freezing transaction interface calls and blocking data export services) to prevent the risk from escalating. The core basis for backtracking the inference chain is the risk timeliness factor labeling of the behavioral risk association graph (to judge the freshness of the risky operation; the higher the timeliness factor, the more likely it is to be the source) and the risk transmission strength labeling (to judge the importance of the path; the higher the transmission strength, the more likely it is to be the core path). The backtracking logic is to trace back from the terminal operation that triggered the warning to the initial operation, and to verify the path confidence by combining the timeliness factor and transmission strength. For example, tracing back from "batch export of data" (terminal operation, timeliness factor 2.47) to "unauthorized query" (transmission strength 1.15), and then tracing back to "unauthorized login" (timeliness factor 2.53, transmission strength 1.01), the path confidence is calculated as (2.53×0.4+1.01×0.3+1.15×0.3)=1.66≥confidence threshold 1.2, and "unauthorized login" is determined to be the source of the risk.
[0106] The core of step S550 is to record key information about risk intervention and generate standardized risk intervention records. The core content of the records includes the risk trigger dimension (e.g., exceeding the transmission probability dimension), the risk trigger source (e.g., unauthorized login account FIN-2025-003), the intervention time (e.g., 2025-XX-XX 15:05), the intervention measures (e.g., freezing the violating account, intercepting data export, auditing operation logs), and the intervention effect (e.g., termination of risk transmission, no data leakage). The record format is a structured document (e.g., JSON or table format), for example: {“Risk Trigger Dimension”: “Risk Transmission Probability (deviation 10.67%)”, “Risk Trigger Source”: “Unauthorized Login Account FIN-2025-003 (Employee ID XXX)”, “Intervention Time”: “2025-XX-XX 15:05”, “Intervention Measures”: “Account Freeze + Intercept Data Export + Notify Security Department”, “Intervention Effect”: “Risk did not spread, the agent resumed compliant operation within 1 hour”}, providing data support for subsequent threshold adjustments and risk reviews.
[0107] The core of step S560 is to adaptively adjust the parameters of the three-dimensional risk threshold matrix based on intervention effectiveness and historical data. This step analyzes the risk intervention effectiveness (such as intervention success rate, false alarm rate, and false negative rate) and historical risk data (such as the risk trigger frequency and distribution of exceedance dimensions in the past month) using a trained risk transmission quantification model, and dynamically optimizes the threshold parameters. The quantification formulas for intervention effectiveness are: ① Intervention success rate = Number of times risk was successfully blocked / Total number of warning triggers × 100%; ② False alarm rate = Number of times warnings were triggered by non-risk behaviors / Total number of warning triggers × 100%; ③ False negative rate = Actual number of times warnings were not triggered / Total number of actual risks × 100%. The thresholds are adjusted based on the above quantification results to ensure the adjustment logic. Reproducible; the adjustment logic is as follows: for several pre-success rates ≥95% and false alarm rates ≤3%, the thresholds are appropriately relaxed (e.g., the transmission probability threshold is increased from 75% to 78%); if the false negative rate is ≥5%, the thresholds are tightened (e.g., the transmission probability threshold is decreased from 75% to 72%); if a certain dimension has not exceeded the standard for a long period (e.g., the correlation density dimension has not exceeded the standard for 3 months), the threshold for that dimension is appropriately increased (e.g., increased from 2.0 to 2.2); for example, if a financial intelligent agent has an intervention success rate of 98% and a false alarm rate of 2% for 1 consecutive month, the model will adjust the transmission probability threshold from 75% to 78% to improve the threshold adaptability and reduce unnecessary intervention.
[0108] The steps S510-S560 described above, through a closed-loop process of "threshold matrix construction → deviation calculation → early warning triggering → source location → intervention recording → threshold adaptive adjustment," systematically solve the problems of fixed risk thresholds, ambiguous source tracing logic, and lack of dynamic optimization after intervention in existing technologies. It achieves multi-dimensional accurate early warning through three-dimensional thresholds, precise risk source location based on graph annotation, and continuous adaptation of thresholds to changes in system safety status through adaptive adjustment. This provides full-process support of "early warning-intervention-optimization" for the dynamic behavior safety testing of intelligent agents, effectively improving the timeliness, accuracy, and long-term effectiveness of risk intervention. It should be noted that the threshold values, deviation calculation methods, trigger condition thresholds, backtracking confidence standards, adjustment logic, and recording formats in the above examples are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the threshold matrix dimension, coupling coefficient calculation rules, deviation formula, trigger condition standards, backtracking basis, and adaptive adjustment strategy can be flexibly adjusted according to the actual situation of the intelligent agent application scenario (financial services, industrial control, intelligent interaction, etc.), system security requirement level, and risk occurrence frequency, so as to achieve the purpose of dynamic risk monitoring and precise intervention.
[0109] In one embodiment, step S540 specifically includes the following steps:
[0110] S541. Pause the agent's task execution, and based on the risk timeliness factor labeling of the behavior risk association graph, split the temporal nodes of the agent's behavior reasoning chain, and sort out the behavior execution sequence and association relationship of each temporal node in chronological order.
[0111] S542. Combining the risk transmission intensity labeling of the behavioral risk association map, calculate the risk transmission confidence of the association path between each time series node. The risk transmission confidence is obtained by weighted summation of the risk transmission intensity quantification value and the risk timeliness factor quantification value.
[0112] S543. Screen the associated paths with a risk transmission confidence level higher than the preset confidence threshold, form key risk transmission links, and trace the initial triggering node of the key risk transmission links;
[0113] S544. Verify the matching degree between the behavioral characteristics of the initial trigger node and the risk event triggering conditions in the risk rule base. When the matching degree reaches the preset matching threshold, determine that the initial trigger node is the source of risk triggering.
[0114] In this embodiment, the core of step S541 is to pause the task and split the time-series nodes to sort out the temporal logic of the behavioral reasoning chain. This step first pauses the execution of the intelligent agent's tasks (such as freezing the data export permission of the financial intelligent agent and the equipment control command issuance permission of the industrial intelligent agent) to prevent further spread of risks; then, based on the risk timeliness factor labeling of the behavioral risk association graph (reflecting the time freshness of the behavior of each node, the higher the quantitative value, the more recent the behavior occurred and the more significant the impact), the time-series nodes of the intelligent agent's behavioral reasoning chain are split: based on the timestamp, the continuous behavioral process is split into independent time-series nodes (such as node T1: 14:20 unauthorized login, node T2: 14:45 unauthorized query, node T3: 15:05 data export), and sorts out the specific behavioral execution content of each time-series node (such as "unauthorized query of 1500 customer asset data" in T2) and the relationship between nodes (such as T1 and T2 being time-series associations, and T2 and T3 being dependency associations) in the chronological order of "T1→T2→T3", providing a clear temporal structure foundation for subsequent confidence calculation.
[0115] The core of step S542 is to calculate the risk transmission confidence of each associated path by combining the transmission strength label. The risk transmission confidence is a core indicator for measuring the authenticity and risk correlation of the associated path. It is calculated as a weighted sum of the quantified value of risk transmission strength and the quantified value of risk timeliness factor. The preset weighting coefficients can be adjusted according to scenario requirements (e.g., transmission strength weight 0.5, timeliness factor weight 0.5, or emphasizing a certain dimension based on security needs). The setting of the weighting coefficients refers to the risk focus of the scenario: ① Financial scenario (emphasizing risk transmission speed), the risk timeliness factor weight is set to 0.6, and the risk transmission strength weight is set to 0.4; ② Industrial scenario (emphasizing transmission reliability), the risk transmission strength weight is set to 0.6, and the risk timeliness factor weight is set to 0.4, ensuring that the confidence calculation aligns with the core needs of the scenario; Risk transmission strength... The quantified values are the annotation results of the graph edges (e.g., the transmission strength of T1→T2 is 1.01, and the transmission strength of T2→T3 is 1.15), and the quantified values of the risk timeliness factor are the annotation results of each time series node (e.g., the timeliness factor of T1 is 2.53, the timeliness factor of T2 is 2.47, and the timeliness factor of T3 is 2.31). For example, to calculate the confidence of the T1→T2→T3 path: first calculate the confidence between adjacent nodes (T1→T2: 1.01×0.5+2.53×0.5=1.77; T2→T3: 1.15×0.5+2.47×0.5=1.81), and then take the overall confidence mean of the path (1.77+1.81)÷2=1.79 to accurately quantify the reliability of the risk transmission of the path.
[0116] The core of step S543 is to screen key risk transmission links and trace the initial triggering node. Here, a pre-set confidence threshold is the critical value that distinguishes between critical and non-critical paths (e.g., a preset threshold of 1.2, which can be adjusted according to the risk sensitivity of the scenario). Paths with confidence levels higher than this threshold are screened (e.g., 1.79 ≥ 1.2, identified as critical paths). Key risk transmission links are the high-confidence paths after screening, accurately pinpointing the core channels of risk propagation. Subsequently, the process is reversed along the key links, tracing back from the terminal time-series node (e.g., T3: data export) to the earliest occurrence time-series node (e.g., T1: unauthorized login). This earliest node is the initial triggering node, providing a clear target for subsequent source verification.
[0117] The core of step S544 is to verify the matching degree between the initial trigger node and the rule base, and ultimately determine the source of the risk trigger. The verification dimensions for the matching degree include the behavior type of the initial trigger node (e.g., whether "unauthorized login" matches the trigger behavior type of "data leakage risk event" in the rule base), execution conditions (e.g., whether the login account permissions and execution time match), and associated resources (e.g., whether the accessed database is a sensitive resource defined in the rule base). The preset matching threshold is the critical value for determining a valid match (e.g., 85%; the more matching dimensions and the higher the fit, the higher the matching degree). For example, the behavior characteristics of the initial trigger node T1 are "unauthorized login to an employee account (permission level: administrator) + login time: non-working hours 14:20 + accessed resource: customer asset database." This is compared with the trigger conditions of "data leakage risk event" in the risk rule base (unauthorized login to an administrator account + access to a sensitive database during non-working hours). If the matching degree reaches 98% ≥ 85%, T1 (unauthorized login) is ultimately determined to be the source of the risk trigger.
[0118] The steps S541-S544 described above, through a progressive process of "time-series node decomposition → confidence calculation → key link screening → matching degree verification," systematically solve the problems of lack of structured logic and lack of quantitative basis for source determination in existing technologies for risk tracing. Relying on the labeled data of the behavioral risk association graph, it achieves precise tracing from "behavioral trajectory" to "key link" and then to "risk source." It clarifies the temporal logic through time-series decomposition, locks the core path through confidence quantification, and ensures the accuracy of source determination through rule matching verification. This provides clear target objects for risk intervention and effectively improves the efficiency and reliability of source tracing in the dynamic behavior safety testing of intelligent agents. It should be noted that the weighting coefficients, confidence thresholds, matching thresholds, verification dimensions, and calculation results in the above examples are merely exemplary settings for ease of understanding and do not constitute a limitation of the present invention. In practical applications, the weighting coefficient allocation, confidence threshold setting, matching dimension selection, and matching threshold standard can be flexibly adjusted according to the actual situation of the intelligent agent application scenario (financial services, industrial control, intelligent interaction, etc.), risk type characteristics, system security requirements, etc., so as to achieve the goal of accurately locating the source of risk triggering.
[0119] In one embodiment, a safety testing system for agent dynamic behavior based on a risk transmission quantification model is provided. This system corresponds to the agent dynamic behavior safety testing method based on a risk transmission quantification model described in the previous embodiment. The agent dynamic behavior safety testing system based on a risk transmission quantification model includes:
[0120] The data acquisition module is used to collect behavioral data during the execution of tasks by the intelligent agent. The behavioral data includes several risk operation information and the risk correlation between each risk operation information.
[0121] The risk labeling module is used to construct a behavioral risk association graph by taking several risk operation information as graph nodes and risk association relationships as graph edges, and to label the graph nodes with risk. The risk labeling includes risk attribute labeling, risk timeliness factor labeling, and risk transmission intensity labeling.
[0122] The rule base construction module is used to build a risk rule base that includes risk event triggering conditions and risk level judgment criteria based on risk labeling results and preset risk judgment logic;
[0123] The risk calculation module is used to input the behavioral data, behavioral risk correlation graph and risk rule base into the trained risk transmission quantification model, quantify and calculate the risk transmission probability, risk impact range and critical risk node, and output the risk transmission quantification result.
[0124] The backtracking reasoning module is used to monitor the behavior trajectory of the agent in real time based on the risk transmission quantification results and the behavior risk correlation graph. When the behavior trajectory of the agent triggers the preset multi-dimensional risk threshold, the agent's task execution is paused and the reasoning chain is backtracked to generate a risk intervention record.
[0125] The report generation module is used to integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate test reports based on the analysis results.
[0126] Specific limitations regarding the intelligent agent dynamic behavior safety testing system based on a risk transmission quantification model can be found in the limitations of the intelligent agent dynamic behavior safety testing method based on a risk transmission quantification model described above, and will not be repeated here. Each module in the aforementioned intelligent agent dynamic behavior safety testing system based on a risk transmission quantification model can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the corresponding operations of each module.
[0127] In one embodiment, a computer device is provided, which may be a server, and its internal structure diagram may be as follows. Figure 2As shown, the computer device includes a processor, memory, network interface, and database connected via a system bus. The processor provides computing and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system, computer programs, and database. The internal memory provides the environment for the operation of the operating system and computer programs stored in the non-volatile storage media. The database is used for data storage, data processing, and data analysis. The network interface is used for communication with external terminals via a network connection. When the computer program is executed by the processor, it implements a method for safe testing of dynamic behavior of intelligent agents based on a risk transmission quantification model.
[0128] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements a method for testing the dynamic behavior of an intelligent agent based on a risk transmission quantification model.
[0129] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements a method for testing the dynamic behavior of an intelligent agent based on a risk transmission quantification model.
[0130] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0131] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is used as an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.
[0132] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.
Claims
1. A method for testing the dynamic behavior safety of intelligent agents based on a risk transmission quantification model, characterized in that, Includes the following steps: Collect behavioral data during the execution of tasks by the intelligent agent, including several risk operation information and the risk correlation between each risk operation information; By using several risk operation information items as graph nodes and risk correlations as graph edges, a behavioral risk correlation graph is constructed. The graph nodes are then labeled with risk attributes, risk timeliness factors, and risk transmission intensity. Specifically, the steps include: By using several risk operation information as graph nodes and risk correlation relationships as graph edges, a preliminary topological structure of the behavioral risk correlation graph is constructed. Risk attributes are labeled on the graph nodes, and the risk attributes include risk level and correlation with sensitive resources; Risk timeliness factors are labeled on the map nodes. The risk timeliness factors are calculated by multiplying the initial risk level quantification value by the time decay coefficient. The risk transmission intensity is labeled on the edges of the graph. The risk transmission intensity is quantified by multiplying the probability of the associated risk operation corresponding to each graph edge to be labeled by the linkage hazard amplification coefficient. By integrating the topological structure of the behavioral risk association map with the risk labeling results, a complete behavioral risk association map is formed; Based on the risk labeling results and the preset risk judgment logic, a risk rule base is constructed, which includes risk event triggering conditions and risk level judgment criteria. The risk event triggering conditions refer to the conditions under which a risk event is triggered when an agent performs an operation combination in a high-frequency associated path. The risk level judgment criteria are grading rules that distinguish the severity of risks. The construction of the preset risk determination logic specifically includes the following steps: High-frequency risk transmission paths are extracted from the behavioral risk association graph, and combinations of associated risk operations with a probability of linkage greater than or equal to a preset threshold are selected and compiled into a core feature dataset of the graph. The high-frequency risk transmission path refers to the risk association path in the behavioral risk association graph that appears more frequently than the preset frequency threshold. The probability of linkage refers to the probability that all risk operations in a certain association path will occur together. The high-frequency risk transmission path is transformed into risk event triggering conditions, and the linkage judgment logic between risk operations is defined; the linkage judgment logic refers to the rules for determining whether related operations constitute a risk event. Based on the risk transmission intensity labeling of the behavioral risk association graph, risk level adjustment rules are set for associated risk operation combinations. The risk level adjustment rules refer to the rules for adjusting the risk event level corresponding to the associated path according to the risk transmission intensity of the associated path. When the risk transmission intensity of the associated edge corresponding to the associated risk operation combination is greater than or equal to the preset intensity threshold, the risk level is adjusted upward accordingly. By integrating the core feature dataset of the graph, the risk event triggering conditions, and the risk level adjustment rules, a preset risk judgment logic is obtained. The behavioral data, behavioral risk correlation graph, and risk rule base are input into a trained risk transmission quantification model to quantify and calculate the risk transmission probability, risk impact range, and critical risk nodes, and output the risk transmission quantification results. The trained risk transmission quantification model adopts a fusion architecture of dynamic Bayesian network and graph neural network, and establishes a fusion interaction mechanism between the dynamic Bayesian network and the graph neural network. The dynamic Bayesian network is used to train the risk temporal transmission logic, and the graph neural network is used to train the risk structure correlation analysis logic. Specifically, the following steps are included: The behavioral data, behavioral risk correlation graph, and risk rule base are preprocessed according to preset rules to obtain the current feature parameter vector. Input the current feature parameter vector and the risk transmission intensity label in the behavioral risk association graph into the trained risk transmission quantization model, and calculate the risk transmission probability through dynamic Bayesian network quantization. Based on the risk transmission probability and the risk level determination criteria in the risk rule base, the scope of risk impact is defined by a graph neural network. By combining the probability of risk transmission with the scope of risk impact, critical risk nodes are identified through the fusion and interaction mechanism of dynamic Bayesian networks and graph neural networks. By integrating the probability of risk transmission, the scope of risk impact, and critical risk nodes, the quantitative results of risk transmission are obtained and output. Based on the risk transmission quantification results and behavioral risk correlation map, the behavior trajectory of the intelligent agent is monitored in real time. When the behavior trajectory of the intelligent agent triggers the preset multi-dimensional risk threshold, the task execution of the intelligent agent is paused and the reasoning chain is traced back to generate a risk intervention record. Integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate test reports based on the analysis results.
2. The method for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model as described in claim 1, characterized in that, The construction of the trained risk transmission quantification model specifically includes the following steps: A risk transmission quantification model is constructed by adopting a fusion architecture of dynamic Bayesian network and graph neural network, with risk transmission probability, risk impact range and critical risk node as the core quantitative indicators. Collect agent behavior logs, risk event history records, and system topology data, and preprocess the data according to preset rules to obtain a risk operation feature parameter vector that adapts to the input requirements of the fusion architecture; The risk operation feature parameter vector is input into the risk transmission quantification model. The risk time-series transmission logic is trained based on the dynamic Bayesian network, and the risk structure correlation analysis logic is trained based on the graph neural network, so that the risk transmission quantification model can be adapted to the calculation requirements of different core quantification indicators. Establish a fusion and interaction mechanism between dynamic Bayesian networks and graph neural networks, and optimize the parameters of the risk transmission quantification model by combining the risk level judgment criteria in the risk rule base; Based on the optimized risk transmission quantification model, a trained risk transmission quantification model is obtained, which is used to quantify the risk transmission probability, the scope of risk impact, and the critical risk node, and outputs the risk transmission quantification results.
3. The method for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model as described in claim 2, characterized in that, The step of monitoring the agent's behavioral trajectory in real time based on the risk transmission quantification results and behavioral risk correlation graph, and pausing the agent's task execution and backtracking the inference chain to generate a risk intervention record when the agent's behavioral trajectory triggers a preset multi-dimensional risk threshold, specifically includes the following steps: Based on the risk level determination criteria and system security requirements in the risk rule base, a three-dimensional risk threshold matrix is constructed. The three-dimensional risk threshold matrix includes a risk transmission probability threshold, a risk impact range threshold, and a critical risk node association density threshold. The critical risk node association density is calculated by the coupling coefficient between risk transmission intensity and risk impact range. By using the fusion and interaction mechanism of the trained risk transmission quantification model, the risk transmission quantification results are compared with the three-dimensional risk threshold matrix, and the risk deviation of each dimension is calculated respectively. The system monitors the behavior trajectory of the intelligent agent in real time. When the risk deviation of any dimension of the behavior trajectory exceeds the preset threshold, or when two or more dimensions reach the preset warning threshold at the same time, the system determines that the risk warning condition is triggered. The agent's task execution is paused. Based on the risk timeliness factor labeling and risk transmission intensity labeling of the behavioral risk correlation graph, the agent's behavioral reasoning chain is traced back to locate the source of risk triggering. Record the risk trigger dimensions, risk trigger sources, intervention time, and intervention measures to generate a risk intervention record; Based on the effectiveness of risk intervention and historical risk data, the parameters of the three-dimensional risk threshold matrix are adaptively adjusted using a trained risk transmission quantification model.
4. The method for testing the dynamic behavior of intelligent agents based on a risk transmission quantification model as described in claim 3, characterized in that, The step of pausing the agent's task execution, based on the risk timeliness factor labeling and risk transmission intensity labeling of the behavioral risk correlation graph, and tracing back the agent's behavioral reasoning chain to locate the risk triggering source, specifically includes the following steps: The agent's task execution is paused, and based on the risk timeliness factor annotation of the behavior risk association graph, the temporal nodes of the agent's behavior inference chain are split, and the behavior execution sequence and association relationship of each temporal node are sorted out in chronological order. By combining the risk transmission intensity labeling of the behavioral risk association map, the risk transmission confidence of the association path between each time series node is calculated. The risk transmission confidence is obtained by weighted summation of the quantified value of risk transmission intensity and the quantified value of risk timeliness factor. Screen the associated paths with a risk transmission confidence level higher than a preset confidence threshold to form key risk transmission links, and trace the initial triggering nodes of key risk transmission links; Verify the matching degree between the behavioral characteristics of the initial trigger node and the risk event triggering conditions in the risk rule base. When the matching degree reaches the preset matching threshold, determine that the initial trigger node is the source of risk triggering.
5. A safety testing system for the dynamic behavior of intelligent agents based on a risk transmission quantification model, used to implement the steps of the safety testing method for the dynamic behavior of intelligent agents based on a risk transmission quantification model as described in any one of claims 1-4, characterized in that, include: The data acquisition module is used to collect behavioral data during the execution of tasks by the intelligent agent. The behavioral data includes several risk operation information and the risk correlation between each risk operation information. The risk labeling module is used to construct a behavioral risk association graph by taking several risk operation information as graph nodes and risk association relationships as graph edges, and to label the graph nodes with risk. The risk labeling includes risk attribute labeling, risk timeliness factor labeling, and risk transmission intensity labeling. The rule base construction module is used to build a risk rule base that includes risk event triggering conditions and risk level judgment criteria based on risk labeling results and preset risk judgment logic; The risk calculation module is used to input the behavioral data, behavioral risk correlation graph and risk rule base into the trained risk transmission quantification model, quantify and calculate the risk transmission probability, risk impact range and critical risk node, and output the risk transmission quantification result. The backtracking reasoning module is used to monitor the behavior trajectory of the agent in real time based on the risk transmission quantification results and the behavior risk correlation graph. When the behavior trajectory of the agent triggers the preset multi-dimensional risk threshold, the agent's task execution is paused and the reasoning chain is backtracked to generate a risk intervention record. The report generation module is used to integrate and analyze behavioral data, behavioral risk correlation maps, risk transmission quantification results, and risk intervention records, and generate test reports based on the analysis results.
6. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the intelligent agent dynamic behavior safety testing method based on the risk transmission quantization model as described in any one of claims 1-4.
7. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the intelligent agent dynamic behavior safety testing method based on the risk transmission quantification model as described in any one of claims 1-4.
Citation Information
Patent Citations
Enterprise data risk processing method and system based on dynamic knowledge graph
CN120494538A