Interface data monitoring method and device, computer device, and storage medium
By performing feature extraction and normalization on interface data, an alarm level prediction model was trained, which solved the problem of low alarm accuracy in interface data monitoring and enabled dynamic anomaly identification and accurate alarms for interface data.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- PING AN TECH (SHENZHEN) CO LTD
- Filing Date
- 2022-09-22
- Publication Date
- 2026-06-02
AI Technical Summary
Existing technologies fail to dynamically analyze and identify abnormal requests in interface data monitoring, resulting in low accuracy of interface data alarms and an inability to distinguish between auxiliary function interfaces that have a minor impact on the system and critical interfaces that require urgent handling.
By determining the target historical data characteristics of the preset interface, normalizing them, training an initial alarm level prediction model, constructing an alarm level prediction model using the nearest neighbor algorithm, and calculating the alarm level of the interface data to be monitored based on Euclidean distance and weight coefficients.
It improves the accuracy of interface data monitoring, can dynamically identify abnormal requests, reduce false alarms, and improve system stability and availability.
Smart Images

Figure CN115454774B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to an interface data monitoring method, apparatus, computer equipment, and storage medium. Background Technology
[0002] Due to the rapid development of information technology, various system software applications are used in all aspects of life, with service functions becoming increasingly finely segmented, and the requirements for the stability and availability of application systems are becoming increasingly stringent. The current mainstream solution is to optimize application systems with a distributed architecture, finely breaking them down into various service components based on different business functions, service dimensions, and user groups. These service components may be developed by different teams, implemented using different programming languages, and deployed in multiple different data center server rooms. Therefore, highly compatible monitoring tools are needed to monitor each service component, enabling rapid location and resolution of problems in the event of a failure.
[0003] In the process of developing this application, the applicant discovered the following problems with the existing technology: Regarding anomaly alarms, pre-set thresholds for the system or interface are generally used as alarm triggering conditions, failing to achieve dynamic analysis and identification of abnormal requests, resulting in low accuracy of interface data alarms. For example, a system interface request failure rate exceeding 5% is set to trigger a telephone alarm. However, since interface a1 is an auxiliary function, a 5% failure rate has no actual business impact and can be ignored, thus not requiring a telephone alarm.
[0004] Therefore, it is necessary to provide an interface data monitoring method that can improve the accuracy of interface data alarms. Summary of the Invention
[0005] In view of the above, it is necessary to propose an interface data monitoring method, an interface data monitoring device, a computer device, and a storage medium, which can improve the accuracy of interface data alarms.
[0006] This application provides an interface data monitoring method, the interface data monitoring method comprising:
[0007] Determine the target historical data characteristics corresponding to the preset interface;
[0008] Determine the target historical interface dataset corresponding to the target historical data features;
[0009] Determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain the historical alarm level set;
[0010] The target historical interface dataset and the data in the historical alarm level set are combined into training data to train the initial alarm level prediction model and obtain the alarm level prediction model.
[0011] Acquire initial monitoring interface data and preprocess the initial monitoring interface data to obtain target monitoring interface data;
[0012] The alarm level prediction model is invoked to process the target interface data to be monitored, and the target alarm level corresponding to the target interface data to be monitored is obtained.
[0013] Furthermore, in the interface data monitoring method provided in the embodiments of this application, determining the target historical data features corresponding to the preset interface includes:
[0014] Obtain the initial historical data features corresponding to the preset interface;
[0015] Determine the importance value of the initial historical data features;
[0016] Historical data features whose importance value exceeds a preset importance threshold are selected from the initial historical data features as target historical data features.
[0017] Furthermore, in the interface data monitoring method provided in the embodiments of this application, determining the target historical interface dataset corresponding to the target historical data feature includes:
[0018] Determine the initial historical interface dataset corresponding to the target historical data features;
[0019] The first mathematical model is invoked to determine the average value of the historical interface data corresponding to the initial historical interface dataset;
[0020] The second mathematical model is invoked to determine the standard deviation of the historical interface data corresponding to the initial historical interface dataset.
[0021] The initial historical interface dataset is normalized by calling a third mathematical model based on the average value and standard deviation of the historical interface data to obtain the target historical interface dataset.
[0022] Furthermore, in the interface data monitoring method provided in the embodiments of this application, the step of determining the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain a historical alarm level set includes:
[0023] Determine the historical interface logs corresponding to each target historical interface data in the target historical interface dataset;
[0024] Determine the preset alarm keywords in the historical interface logs;
[0025] The alarm information corresponding to the preset alarm keywords is used as the historical alarm level;
[0026] By combining several historical alarm levels in the order of each target historical interface data in the target historical interface dataset, a historical alarm level set is obtained.
[0027] Furthermore, in the interface data monitoring method provided in the embodiments of this application, the step of preprocessing the initial interface data to be monitored to obtain the target interface data to be monitored includes:
[0028] Obtain the average value and standard deviation of the historical interface data corresponding to the initial historical interface dataset;
[0029] The third mathematical model is invoked to normalize the initial interface data to be monitored based on the average value and standard deviation of the historical interface data, so as to obtain the target interface data to be monitored.
[0030] Furthermore, in the interface data monitoring method provided in the embodiments of this application, the step of calling the alarm level prediction model to process the target interface data to be monitored and obtaining the target alarm level corresponding to the target interface data to be monitored includes:
[0031] Calculate the Euclidean distance between the target interface data to be monitored and each historical interface data in the target historical interface dataset;
[0032] The first preset number of target historical interface data are selected as the first target historical interface data in ascending order of Euclidean distance;
[0033] Select a second preset number of target historical interface data from the first target historical interface data as the second target historical interface data;
[0034] Determine the target weight coefficient for the second target historical interface data;
[0035] Calculate the target weight distance corresponding to the second target historical interface data based on the target weight coefficient and the Euclidean distance;
[0036] The target alarm level corresponding to the target monitored interface data is determined and output based on the target weight distance.
[0037] Furthermore, in the interface data monitoring method provided in the embodiments of this application, the step of determining the target alarm level corresponding to the target monitored interface data based on the target weight distance includes:
[0038] Obtain the alarm level corresponding to the historical interface data of the second target;
[0039] Based on the alarm level, the pre-set correspondence between alarm levels and weight distances is traversed to obtain the target weight distance corresponding to the alarm level;
[0040] The alarm level with the largest target weight distance is selected as the target alarm level.
[0041] A second aspect of this application also provides an interface data monitoring device, the interface data monitoring device comprising:
[0042] The feature determination module is used to determine the target historical data features corresponding to the preset interface;
[0043] The data determination module is used to determine the target historical interface dataset corresponding to the target historical data features;
[0044] The level determination module is used to determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset, and obtain a historical alarm level set;
[0045] The model training module is used to combine the data from the target historical interface dataset and the historical alarm level set into training data, train the initial alarm level prediction model, and obtain the alarm level prediction model.
[0046] The preprocessing module is used to acquire initial interface data to be monitored and preprocess the initial interface data to be monitored to obtain target interface data to be monitored.
[0047] The alarm determination module is used to call the alarm level prediction model to process the target interface data to be monitored and obtain the target alarm level corresponding to the target interface data to be monitored.
[0048] A third aspect of this application also provides a computer device, the computer device including a processor, the processor being configured to implement the interface data monitoring method as described in any of the preceding embodiments when executing a computer program stored in a memory.
[0049] A fourth aspect of this application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the interface data monitoring method described in any one of the above embodiments.
[0050] The interface data monitoring method, device, computer equipment, and computer-readable storage medium provided in this application improve the accuracy of interface data monitoring by using a nearest neighbor algorithm to train a model on historical interface data, obtaining an alarm level prediction model, and then calling the alarm level prediction model to determine the target alarm level corresponding to the interface data to be monitored. This application can be applied to various functional modules of smart cities, such as smart government and smart transportation, including the interface data monitoring module in smart government, thus promoting the rapid development of smart cities. Attached Figure Description
[0051] Figure 1 This is a flowchart of the interface data monitoring method provided in Embodiment 1 of this application.
[0052] Figure 2a This is a schematic diagram of the initial historical interface data provided in one embodiment of this application.
[0053] Figure 2b This is a schematic diagram of target historical interface data provided in an embodiment of this application.
[0054] Figure 3 This is a schematic diagram of training data provided in one embodiment of this application.
[0055] Figure 4 This is a schematic diagram of the initial interface data to be monitored provided in one embodiment of this application.
[0056] Figure 5 This is a schematic diagram of the target interface data to be monitored provided in an embodiment of this application.
[0057] Figure 6 This is a schematic diagram of the target weight coefficient provided in an embodiment of this application.
[0058] Figure 7 This is a schematic diagram of the target weight distance provided in an embodiment of this application.
[0059] Figure 8 This is a structural diagram of the interface data monitoring device provided in Embodiment 2 of this application.
[0060] Figure 9 This is a schematic diagram of the structure of the computer device provided in Embodiment 3 of this application.
[0061] The following detailed description, in conjunction with the accompanying drawings, will further illustrate this application. Detailed Implementation
[0062] To better understand the above-mentioned objectives, features, and advantages of this application, the application will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other.
[0063] Numerous specific details are set forth in the following description in order to provide a full understanding of this application. The described embodiments are only some, not all, of the embodiments of this application.
[0064] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application.
[0065] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.
[0066] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0067] The interface data monitoring method provided in this embodiment of the invention is executed by a computer device, and correspondingly, the interface data monitoring device runs in the computer device. Figure 1 This is a flowchart of the interface data monitoring method provided in Embodiment 1 of this application. Figure 1 As shown, the interface data monitoring method may include the following steps. The order of these steps in the flowchart may be changed, and some may be omitted, depending on different requirements:
[0068] S11, Determine the target historical data features corresponding to the preset interface.
[0069] In at least one embodiment of this application, the preset interface can be an interface in an application system. To monitor the operating status of the preset interface, target historical data features of interest to the preset interface can be identified. In one embodiment, the target historical data features of interest to the preset interface can be the number of requests per unit time, the proportion of incorrect requests, etc. The target historical data features can be obtained by filtering from initial historical data features. The initial historical data features can be pre-set data features used to identify the operating status of the preset interface. In one embodiment, the initial historical data features can be features such as the number of requests per unit time, response time, and proportion of incorrect requests, etc., without limitation.
[0070] Optionally, determining the target historical data features corresponding to the preset interface includes:
[0071] Obtain the initial historical data features corresponding to the preset interface;
[0072] Determine the importance value of the initial historical data features;
[0073] Historical data features whose importance value exceeds a preset importance threshold are selected from the initial historical data features as target historical data features.
[0074] The importance of the initial historical data features can be used as a criterion for determining whether a historical data feature is a feature of interest. When the importance value of the initial historical data feature exceeds a preset importance threshold, the historical data feature is determined to be a target historical data feature; when the importance value of the initial historical data feature does not exceed the preset importance threshold, the historical data feature is determined not to be a target historical data feature. In one embodiment, the preset interface corresponds to a historical interface log, which contains the running data of each initial historical data feature. A preset database is established, and keywords of several preset initial historical data features are stored in the preset database. Obtaining the initial historical data features corresponding to the preset interface includes: obtaining the keywords of the initial historical data features in the preset database; collecting the historical interface logs corresponding to the preset interface; detecting whether the keywords of the initial historical data features exist in the historical interface logs; and when the keywords of the initial historical data features exist in the historical interface logs, the data feature corresponding to the keywords is taken as the initial historical data feature.
[0075] In one embodiment, the importance value of the initial historical data feature can be preset, and the importance value of the initial historical data feature can refer to the importance of the initial historical data feature during the operation status monitoring of a preset interface. Determining the importance value of the initial historical data feature includes: determining the mapping relationship between the initial historical data feature and the importance value; traversing the mapping relationship to obtain the importance value corresponding to the initial historical data feature. The preset importance threshold is a preset threshold.
[0076] S12, determine the target historical interface dataset corresponding to the target historical data features.
[0077] In at least one embodiment of this application, the preset database further stores an initial historical interface dataset corresponding to the preset interface, wherein the initial historical interface dataset refers to a collection of runtime data of the preset interface. Considering the reliability and privacy of data storage, the preset database can be a target node on a blockchain. The target historical interface dataset refers to a collection of runtime data corresponding to the target historical data features. In one embodiment, considering that the values of the initial historical interface data corresponding to the target historical data features are uncertain, and therefore the value range of the initial historical interface data cannot be predicted, directly using the initial historical interface dataset for interface monitoring would cause significant errors. Therefore, a series of processing steps are required on the initial historical interface dataset to obtain the target historical interface dataset.
[0078] Optionally, determining the target historical interface dataset corresponding to the target historical data feature includes:
[0079] Determine the initial historical interface dataset corresponding to the target historical data features;
[0080] The first mathematical model is invoked to determine the average value of the historical interface data corresponding to the initial historical interface dataset;
[0081] The second mathematical model is invoked to determine the standard deviation of the historical interface data corresponding to the initial historical interface dataset.
[0082] The initial historical interface dataset is normalized by calling a third mathematical model based on the average value and standard deviation of the historical interface data to obtain the target historical interface dataset.
[0083] The first mathematical model can be a mean model, assuming that the initial historical interface data in the initial historical interface dataset are as follows: The mean model can be as follows:
[0084]
[0085] The second mathematical model can be a standard deviation model, which can be as follows:
[0086]
[0087] in, Let S be the mean of all initial historical interface data, S be the standard deviation of all initial historical interface data, and n be the number of initial historical interface data. This represents the initial historical interface data for the i-th time.
[0088] The third mathematical model can be a normalized model, which can be as follows:
[0089]
[0090] in, The average value of the historical interface data corresponding to the initial historical interface dataset. The standard deviation of the historical interface data corresponding to the initial historical interface dataset is... For the i-th initial historical interface data in the initial historical interface dataset, This is the value of the i-th initial historical interface data in the initial historical interface dataset after normalization.
[0091] For example, the initial historical interface data can be as follows: Figure 2a As shown;
[0092] After normalization, the target historical interface data can be as follows: Figure 2b As shown.
[0093] This application embodiment normalizes the historical interface data corresponding to the target historical data features to avoid the problem of large errors caused by the unpredictable value range of historical interface data, thereby improving the accuracy of interface data monitoring.
[0094] S13, determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain the historical alarm level set.
[0095] In at least one embodiment of this application, the historical interface log includes not only historical interface data for each target historical data feature, but also historical alarm levels corresponding to the historical interface data. For each historical interface data corresponding to a target historical data feature, there exists a corresponding historical alarm level. The historical alarm levels are combined according to the order of each target historical interface data in the target historical interface dataset to obtain a historical alarm level set. In one embodiment, the historical alarm levels can be divided into Level 1 alarms, Level 2 alarms, Level 3 alarms, and Level 4 alarms. Level 1 alarms refer to major anomaly alarms, which send alarm information via email, SMS, or telephone to remind IT personnel to handle the situation urgently. Level 2 alarms are ordinary alarms, which send alarm information via email or SMS to remind IT personnel to analyze and handle the situation. Level 3 alarms are minor alarms, which send alarm information via email to remind IT personnel to pay attention and analyze the situation. Level 4 alarms indicate a state where no alarm is required, signifying that the preset interface is operating normally at this time.
[0096] Optionally, determining the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain a historical alarm level set includes:
[0097] Determine the historical interface logs corresponding to each target historical interface data in the target historical interface dataset;
[0098] Determine the preset alarm keywords in the historical interface logs;
[0099] The alarm information corresponding to the preset alarm keywords is used as the historical alarm level;
[0100] By combining several historical alarm levels in the order of each target historical interface data in the target historical interface dataset, a historical alarm level set is obtained.
[0101] The historical interface logs contain historical alarm levels corresponding to the target historical data features. These historical alarm levels can be determined using preset alarm keywords. By identifying the preset alarm keywords present in the historical interface logs, the alarm information corresponding to the preset alarm keywords is used as the historical alarm level. Several historical alarm levels are combined according to the order of each target historical interface data in the target historical interface dataset to obtain a historical alarm level set. For example, the alarm content in the historical interface logs is as follows: {Alert: Level 2}. Here, "Alert" is the preset alarm keyword used to identify the historical alarm level corresponding to the target historical interface data, and "Level 2" is the alarm information corresponding to the preset alarm keyword. "Level 2" is used as the historical alarm keyword.
[0102] S14, combine the data from the target historical interface dataset and the historical alarm level set into training data, train the initial alarm level prediction model, and obtain the alarm level prediction model.
[0103] In one embodiment, a training set is constructed by combining the target historical interface dataset and the data from the historical alarm level set according to a preset data format. The preset data format can be a pre-defined data format, for example, {target historical interface data, historical alarm levels}.
[0104] For example, a portion of the training data in the training set may be as follows: Figure 3 As shown.
[0105] In at least one embodiment of this application, the k-Nearest Neighbors (KNN) algorithm can be used to train an initial alarm level prediction model. The KNN algorithm is a classification algorithm that classifies data by measuring the distance between different feature values. Its working principle is to partition the feature vector space using training data, that is, using samples of all known categories as references, calculating the distance between an unknown sample and all known samples, selecting the K (also referred to as the first preset number) known samples closest to the unknown sample, and then, according to a preset classification decision rule, grouping the unknown sample and the K nearest neighbor samples with the highest proportion of their respective categories into the same type. In at least one embodiment of this application, the step of using the nearest neighbor algorithm to train the initial alarm level prediction model, taking the target historical interface data as input and the historical alarm level as output, to obtain the alarm level prediction model includes:
[0106] The target historical interface data is used as input and the historical alarm level is used as output to construct a training set;
[0107] Select the current training sample and the remaining training samples from the training set, and calculate the Euclidean distance between the target historical interface data in the current training sample and the target historical interface data in the remaining training samples;
[0108] K training samples are selected from the remaining training samples in ascending order of the Euclidean distance;
[0109] The predicted alarm level corresponding to the current training sample is determined from K training samples according to the preset classification decision rules;
[0110] Obtain the actual alarm level corresponding to the current training sample;
[0111] The model parameters of the initial alarm level prediction model are adjusted based on the predicted alarm level and the actual alarm level to obtain the alarm level prediction model.
[0112] Wherein, K is the hyperparameter of the alarm level prediction model, which can be obtained by training the initial alarm level prediction model using the training set. In one embodiment, the value of K can be 10, and there is no limitation here. The preset classification decision rule refers to the pre-set selection of the sample with the most samples belonging to the same category from the K nearest neighbor samples as the predicted alarm level. In one embodiment, the preset classification decision rule can be to select the alarm level with the largest weight distance from the K training samples. The weight distance is the product of the Euclidean distance and the weight coefficient, and both the Euclidean distance and the weight coefficient can be calculated using a pre-set mathematical formula. The processing of the weight distance is described in detail below and will not be repeated here. There is a correspondence between the target historical interface data and the historical alarm levels in the training set. By querying the correspondence, the actual alarm level corresponding to the current training sample can be obtained. The model parameters of the initial alarm level prediction model are adjusted based on the predicted alarm level and the actual alarm level to obtain target model parameters. An alarm level prediction model can be obtained based on the target model parameters so that the model accuracy of the alarm level prediction model reaches a preset accuracy threshold. The preset accuracy threshold is a pre-set threshold used to evaluate whether the trained model can be used in the application scenario. For example, the preset accuracy threshold is 95%.
[0113] S15, acquire initial monitoring interface data, and preprocess the initial monitoring interface data to obtain target monitoring interface data.
[0114] In at least one embodiment of this application, the initial interface data to be monitored is the interface data that needs to be monitored. The initial interface data to be monitored can be new interface data, that is, interface data different from the preset interface. This application obtains target interface data to be monitored by preprocessing the initial interface data to be monitored. The preprocessing can be normalization. By normalizing the initial interface data to be monitored, the problem of large errors caused by the unpredictable value range of the initial interface data to be monitored can be avoided, thereby improving the accuracy of interface data monitoring.
[0115] Optionally, the preprocessing of the initial interface data to be monitored to obtain the target interface data to be monitored includes:
[0116] Obtain the average value and standard deviation of the historical interface data corresponding to the initial historical interface dataset;
[0117] The third mathematical model is invoked to normalize the initial interface data to be monitored based on the average value and standard deviation of the historical interface data, so as to obtain the target interface data to be monitored.
[0118] The process of normalizing the interface data has been described above and will not be repeated here.
[0119] For example, the initial interface data to be monitored is as follows: Figure 4 As shown;
[0120] The target interface data to be monitored is as follows: Figure 5 As shown.
[0121] S16, call the alarm level prediction model to process the target interface data to be monitored, and obtain the target alarm level corresponding to the target interface data to be monitored.
[0122] In at least one embodiment of this application, the target interface data to be monitored is input into the alarm level prediction model. After processing by the alarm level prediction model, the target alarm level corresponding to the target interface data to be monitored can be output as output.
[0123] Optionally, the step of calling the alarm level prediction model to process the target monitored interface data and obtaining the target alarm level corresponding to the target monitored interface data includes:
[0124] Calculate the Euclidean distance between the target interface data to be monitored and each historical interface data in the target historical interface dataset;
[0125] The first preset number of target historical interface data are selected as the first target historical interface data in ascending order of Euclidean distance;
[0126] Select a second preset number of target historical interface data from the first target historical interface data as the second target historical interface data;
[0127] Determine the target weight coefficient for the second target historical interface data;
[0128] Calculate the target weight distance corresponding to the second target historical interface data based on the target weight coefficient and the Euclidean distance;
[0129] The target alarm level corresponding to the target monitored interface data is determined and output based on the target weight distance.
[0130] The first preset quantity can be a pre-set number of target historical interface data, which can be 10, and is not limited here. The second preset quantity is not greater than the square root of the first preset quantity. Taking a first preset quantity of 10 as an example, the second preset quantity is 3.
[0131] In Euclidean distance, the target historical interface data are assumed to have the same weight. This application uses weighted Euclidean distance to weight the votes of neighboring nodes, with the weight increasing as the distance increases.
[0132] The formula for the target weight coefficient is as follows:
[0133]
[0134] in, The minimum Euclidean distance. For the first The Euclidean distance between the second target's historical interface data and the target's interface data to be monitored. For the first The target weight coefficients are corresponding to the second target historical interface data. The minimum Euclidean distance d is set to 1 by default. The target weight coefficients for the remaining second target historical interface data are the minimum Euclidean distance d divided by the nth power of the Euclidean distance between the second target historical interface data and the target monitoring interface data, where n is the number of features of the target historical data.
[0135] For example, the target weight coefficient of the second target historical interface data can be as follows: Figure 6 As shown.
[0136] The target weight distance can be the product of the Euclidean distance and the target weight coefficient.
[0137] For example, the target weight distance corresponding to the second target historical interface data can be as follows: Figure 7 As shown. Optionally, determining the target alarm level corresponding to the target monitored interface data based on the target weight distance includes:
[0138] Obtain the alarm level corresponding to the historical interface data of the second target;
[0139] Based on the alarm level, the pre-set correspondence between alarm levels and weight distances is traversed to obtain the target weight distance corresponding to the alarm level;
[0140] The alarm level with the largest target weight distance is selected as the target alarm level.
[0141] Specifically, the alarm level and target weight distance corresponding to the historical interface data of the second target are obtained, and the alarm level with the largest target weight distance is selected as the target alarm level. Combined with... Figure 7 There are two interfaces with an "Alarm Level" of "Level 1": Interface J and Interface F. The total target weight distance between Interface J and Interface F is 0.421846. There is one interface with an "Alarm Level" of "Level 3": Interface I. The target weight distance for Interface I is 0.181967. Considering that the target weight distance for "Level 3" alarm level is less than the total target weight distance for "Level 1" alarm level, we select "Level 1," the alarm level with the largest target weight distance, as the target alarm level.
[0142] The interface data monitoring method provided in this application improves the accuracy of interface data monitoring by training historical interface data using the nearest neighbor algorithm to obtain an alarm level prediction model and then using this model to determine the target alarm level for the monitored interface data. This application can be applied to various functional modules of smart cities, such as smart government and smart transportation, including the interface data monitoring module in smart government, thus promoting the rapid development of smart cities.
[0143] Figure 8 This is a structural diagram of the interface data monitoring device provided in Embodiment 2 of this application.
[0144] In some embodiments, the interface data monitoring device 20 may include multiple functional modules composed of computer program segments. The computer programs of each program segment in the interface data monitoring device 20 may be stored in the memory of a computer device and executed by at least one processor to perform (see details). Figure 1 (Description) Functionality of interface data monitoring.
[0145] In this embodiment, the interface data monitoring device 20 can be divided into multiple functional modules according to its functions. These functional modules may include: a feature determination module 201, a data determination module 202, a level determination module 203, a model training module 204, a preprocessing module 205, and an alarm determination module 206. The term "module" in this application refers to a series of computer program segments that can be executed by at least one processor and perform a fixed function, and which are stored in memory. In this embodiment, the functions of each module will be detailed in subsequent embodiments.
[0146] The feature determination module 201 can be used to determine the target historical data features corresponding to the preset interface.
[0147] In at least one embodiment of this application, the preset interface can be an interface in an application system. To monitor the operating status of the preset interface, target historical data features of interest to the preset interface can be identified. In one embodiment, the target historical data features of interest to the preset interface can be the number of requests per unit time, the proportion of incorrect requests, etc. The target historical data features can be obtained by filtering from initial historical data features. The initial historical data features can be pre-set data features used to identify the operating status of the preset interface. In one embodiment, the initial historical data features can be features such as the number of requests per unit time, response time, and proportion of incorrect requests, etc., without limitation.
[0148] Optionally, determining the target historical data features corresponding to the preset interface includes:
[0149] Obtain the initial historical data features corresponding to the preset interface;
[0150] Determine the importance value of the initial historical data features;
[0151] Historical data features whose importance value exceeds a preset importance threshold are selected from the initial historical data features as target historical data features.
[0152] The importance of the initial historical data features can be used as a criterion for determining whether a historical data feature is a feature of interest. When the importance value of the initial historical data feature exceeds a preset importance threshold, the historical data feature is determined to be a target historical data feature; when the importance value of the initial historical data feature does not exceed the preset importance threshold, the historical data feature is determined not to be a target historical data feature. In one embodiment, the preset interface corresponds to a historical interface log, which contains the running data of each initial historical data feature. A preset database is established, and keywords of several preset initial historical data features are stored in the preset database. Obtaining the initial historical data features corresponding to the preset interface includes: obtaining the keywords of the initial historical data features in the preset database; collecting the historical interface logs corresponding to the preset interface; detecting whether the keywords of the initial historical data features exist in the historical interface logs; and when the keywords of the initial historical data features exist in the historical interface logs, the data feature corresponding to the keywords is taken as the initial historical data feature.
[0153] In one embodiment, the importance value of the initial historical data feature can be preset, and the importance value of the initial historical data feature can refer to the importance of the initial historical data feature during the operation status monitoring of a preset interface. Determining the importance value of the initial historical data feature includes: determining the mapping relationship between the initial historical data feature and the importance value; traversing the mapping relationship to obtain the importance value corresponding to the initial historical data feature. The preset importance threshold is a preset threshold.
[0154] The data determination module 202 can be used to determine the target historical interface dataset corresponding to the target historical data features.
[0155] In at least one embodiment of this application, the preset database further stores an initial historical interface dataset corresponding to the preset interface, wherein the initial historical interface dataset refers to a collection of runtime data of the preset interface. Considering the reliability and privacy of data storage, the preset database can be a target node on a blockchain. The target historical interface dataset refers to a collection of runtime data corresponding to the target historical data features. In one embodiment, considering that the values of the initial historical interface data corresponding to the target historical data features are uncertain, and therefore the value range of the initial historical interface data cannot be predicted, directly using the initial historical interface dataset for interface monitoring would cause significant errors. Therefore, a series of processing steps are required on the initial historical interface dataset to obtain the target historical interface dataset.
[0156] Optionally, determining the target historical interface dataset corresponding to the target historical data feature includes:
[0157] Determine the initial historical interface dataset corresponding to the target historical data features;
[0158] The first mathematical model is invoked to determine the average value of the historical interface data corresponding to the initial historical interface dataset;
[0159] The second mathematical model is invoked to determine the standard deviation of the historical interface data corresponding to the initial historical interface dataset.
[0160] The initial historical interface dataset is normalized by calling a third mathematical model based on the average value and standard deviation of the historical interface data to obtain the target historical interface dataset.
[0161] The first mathematical model can be a mean model, assuming that the initial historical interface data in the initial historical interface dataset are as follows: The mean model can be as follows:
[0162]
[0163] The second mathematical model can be a standard deviation model, which can be as follows:
[0164]
[0165] in, Let S be the mean of all initial historical interface data, S be the standard deviation of all initial historical interface data, and n be the number of initial historical interface data. This represents the initial historical interface data for the i-th time.
[0166] The third mathematical model can be a normalized model, which can be as follows:
[0167]
[0168] in, The average value of the historical interface data corresponding to the initial historical interface dataset. The standard deviation of the historical interface data corresponding to the initial historical interface dataset is... For the i-th initial historical interface data in the initial historical interface dataset, This is the value of the i-th initial historical interface data in the initial historical interface dataset after normalization.
[0169] For example, the initial historical interface data can be as follows: Figure 2a As shown;
[0170] After normalization, the target historical interface data can be as follows: Figure 2b As shown.
[0171] This application embodiment normalizes the historical interface data corresponding to the target historical data features to avoid the problem of large errors caused by the unpredictable value range of historical interface data, thereby improving the accuracy of interface data monitoring.
[0172] The level determination module 203 can be used to determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset, thereby obtaining a historical alarm level set.
[0173] In at least one embodiment of this application, the historical interface log includes not only historical interface data for each target historical data feature, but also historical alarm levels corresponding to the historical interface data. For each historical interface data corresponding to a target historical data feature, there exists a corresponding historical alarm level. The historical alarm levels are combined according to the order of each target historical interface data in the target historical interface dataset to obtain a historical alarm level set. In one embodiment, the historical alarm levels can be divided into Level 1 alarms, Level 2 alarms, Level 3 alarms, and Level 4 alarms. Level 1 alarms refer to major anomaly alarms, which send alarm information via email, SMS, or telephone to remind IT personnel to handle the situation urgently. Level 2 alarms are ordinary alarms, which send alarm information via email or SMS to remind IT personnel to analyze and handle the situation. Level 3 alarms are minor alarms, which send alarm information via email to remind IT personnel to pay attention and analyze the situation. Level 4 alarms indicate a state where no alarm is required, signifying that the preset interface is operating normally at this time.
[0174] Optionally, determining the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain a historical alarm level set includes:
[0175] Determine the historical interface logs corresponding to each target historical interface data in the target historical interface dataset;
[0176] Determine the preset alarm keywords in the historical interface logs;
[0177] The alarm information corresponding to the preset alarm keywords is used as the historical alarm level;
[0178] By combining several historical alarm levels in the order of each target historical interface data in the target historical interface dataset, a historical alarm level set is obtained.
[0179] The historical interface logs contain historical alarm levels corresponding to the target historical data features. These historical alarm levels can be determined using preset alarm keywords. By identifying the preset alarm keywords present in the historical interface logs, the alarm information corresponding to the preset alarm keywords is used as the historical alarm level. Several historical alarm levels are combined according to the order of each target historical interface data in the target historical interface dataset to obtain a historical alarm level set. For example, the alarm content in the historical interface logs is as follows: {Alert: Level 2}. Here, "Alert" is the preset alarm keyword used to identify the historical alarm level corresponding to the target historical interface data, and "Level 2" is the alarm information corresponding to the preset alarm keyword. "Level 2" is used as the historical alarm keyword.
[0180] The model training module 204 can be used to combine the data from the target historical interface dataset and the historical alarm level set into training data, train the initial alarm level prediction model, and obtain the alarm level prediction model.
[0181] In one embodiment, a training set is constructed by combining the target historical interface dataset and the data from the historical alarm level set according to a preset data format. The preset data format can be a pre-defined data format, for example, {target historical interface data, historical alarm levels}.
[0182] For example, a portion of the training data in the training set may be as follows: Figure 3 As shown.
[0183] In at least one embodiment of this application, the k-Nearest Neighbors (KNN) algorithm can be used to train an initial alarm level prediction model. The KNN algorithm is a classification algorithm that classifies data by measuring the distance between different feature values. Its working principle is to partition the feature vector space using training data, that is, using samples of all known categories as references, calculating the distance between an unknown sample and all known samples, selecting the K (also referred to as the first preset number) known samples closest to the unknown sample, and then, according to a preset classification decision rule, grouping the unknown sample and the K nearest neighbor samples with the highest proportion of their respective categories into the same type. In at least one embodiment of this application, the step of using the nearest neighbor algorithm to train the initial alarm level prediction model, taking the target historical interface data as input and the historical alarm level as output, to obtain the alarm level prediction model includes:
[0184] The target historical interface data is used as input and the historical alarm level is used as output to construct a training set;
[0185] Select the current training sample and the remaining training samples from the training set, and calculate the Euclidean distance between the target historical interface data in the current training sample and the target historical interface data in the remaining training samples;
[0186] K training samples are selected from the remaining training samples in ascending order of the Euclidean distance;
[0187] The predicted alarm level corresponding to the current training sample is determined from K training samples according to the preset classification decision rules;
[0188] Obtain the actual alarm level corresponding to the current training sample;
[0189] The model parameters of the initial alarm level prediction model are adjusted based on the predicted alarm level and the actual alarm level to obtain the alarm level prediction model.
[0190] Wherein, K is the hyperparameter of the alarm level prediction model, which can be obtained by training the initial alarm level prediction model using the training set. In one embodiment, the value of K can be 10, and there is no limitation here. The preset classification decision rule refers to the pre-set selection of the sample with the most samples belonging to the same category from the K nearest neighbor samples as the predicted alarm level. In one embodiment, the preset classification decision rule can be to select the alarm level with the largest weight distance from the K training samples. The weight distance is the product of the Euclidean distance and the weight coefficient, and both the Euclidean distance and the weight coefficient can be calculated using a pre-set mathematical formula. The processing of the weight distance is described in detail below and will not be repeated here. There is a correspondence between the target historical interface data and the historical alarm levels in the training set. By querying the correspondence, the actual alarm level corresponding to the current training sample can be obtained. The model parameters of the initial alarm level prediction model are adjusted based on the predicted alarm level and the actual alarm level to obtain target model parameters. An alarm level prediction model can be obtained based on the target model parameters so that the model accuracy of the alarm level prediction model reaches a preset accuracy threshold. The preset accuracy threshold is a pre-set threshold used to evaluate whether the trained model can be used in the application scenario. For example, the preset accuracy threshold is 95%.
[0191] The preprocessing module 205 can be used to acquire initial interface data to be monitored and preprocess the initial interface data to be monitored to obtain target interface data to be monitored.
[0192] In at least one embodiment of this application, the initial interface data to be monitored is the interface data that needs to be monitored. The initial interface data to be monitored can be new interface data, that is, interface data different from the preset interface. This application obtains target interface data to be monitored by preprocessing the initial interface data to be monitored. The preprocessing can be normalization. By normalizing the initial interface data to be monitored, the problem of large errors caused by the unpredictable value range of the initial interface data to be monitored can be avoided, thereby improving the accuracy of interface data monitoring.
[0193] Optionally, the preprocessing of the initial interface data to be monitored to obtain the target interface data to be monitored includes:
[0194] Obtain the average value and standard deviation of the historical interface data corresponding to the initial historical interface dataset;
[0195] The third mathematical model is invoked to normalize the initial interface data to be monitored based on the average value and standard deviation of the historical interface data, so as to obtain the target interface data to be monitored.
[0196] The process of normalizing the interface data has been described above and will not be repeated here.
[0197] For example, the initial interface data to be monitored is as follows: Figure 4 As shown;
[0198] The target interface data to be monitored is as follows: Figure 5 As shown.
[0199] The alarm determination module 206 can be used to call the alarm level prediction model to process the target interface data to be monitored, and obtain the target alarm level corresponding to the target interface data to be monitored.
[0200] In at least one embodiment of this application, the target interface data to be monitored is input into the alarm level prediction model. After processing by the alarm level prediction model, the target alarm level corresponding to the target interface data to be monitored can be output as output.
[0201] Optionally, the step of calling the alarm level prediction model to process the target monitored interface data and obtaining the target alarm level corresponding to the target monitored interface data includes:
[0202] Calculate the Euclidean distance between the target interface data to be monitored and each historical interface data in the target historical interface dataset;
[0203] The first preset number of target historical interface data are selected as the first target historical interface data in ascending order of Euclidean distance;
[0204] Select a second preset number of target historical interface data from the first target historical interface data as the second target historical interface data;
[0205] Determine the target weight coefficient for the second target historical interface data;
[0206] Calculate the target weight distance corresponding to the second target historical interface data based on the target weight coefficient and the Euclidean distance;
[0207] The target alarm level corresponding to the target monitored interface data is determined and output based on the target weight distance.
[0208] The first preset quantity can be a pre-set number of target historical interface data, which can be 10, and is not limited here. The second preset quantity is not greater than the square root of the first preset quantity. Taking a first preset quantity of 10 as an example, the second preset quantity is 3.
[0209] In Euclidean distance, the target historical interface data are assumed to have the same weight. This application uses weighted Euclidean distance to weight the votes of neighboring nodes, with the weight increasing as the distance increases.
[0210] The formula for the target weight coefficient is as follows:
[0211]
[0212] in, The minimum Euclidean distance. For the first The Euclidean distance between the second target's historical interface data and the target's interface data to be monitored. For the first The target weight coefficients are corresponding to the second target historical interface data. The minimum Euclidean distance d is set to 1 by default. The target weight coefficients for the remaining second target historical interface data are the minimum Euclidean distance d divided by the nth power of the Euclidean distance between the second target historical interface data and the target monitoring interface data, where n is the number of features of the target historical data.
[0213] For example, the target weight coefficient of the second target historical interface data can be as follows: Figure 6 As shown.
[0214] The target weight distance can be the product of the Euclidean distance and the target weight coefficient.
[0215] For example, the target weight distance corresponding to the second target historical interface data can be as follows: Figure 7 As shown. Optionally, determining the target alarm level corresponding to the target monitored interface data based on the target weight distance includes:
[0216] Obtain the alarm level corresponding to the historical interface data of the second target;
[0217] Based on the alarm level, the pre-set correspondence between alarm levels and weight distances is traversed to obtain the target weight distance corresponding to the alarm level;
[0218] The alarm level with the largest target weight distance is selected as the target alarm level.
[0219] Specifically, the alarm level and target weight distance corresponding to the historical interface data of the second target are obtained, and the alarm level with the largest target weight distance is selected as the target alarm level. Combined with... Figure 7 There are two interfaces with an "Alarm Level" of "Level 1": Interface J and Interface F. The total target weight distance between Interface J and Interface F is 0.421846. There is one interface with an "Alarm Level" of "Level 3": Interface I. The target weight distance for Interface I is 0.181967. Considering that the target weight distance for "Level 3" alarm level is less than the total target weight distance for "Level 1" alarm level, we select "Level 1," the alarm level with the largest target weight distance, as the target alarm level.
[0220] See Figure 9 The diagram shown is a structural schematic of a computer device provided in Embodiment 3 of this application. In a preferred embodiment of this application, the computer device 3 includes a memory 31, at least one processor 32, at least one communication bus 33, and a transceiver 34.
[0221] Those skilled in the art should understand that Figure 9 The structure of the computer device shown does not constitute a limitation of the embodiments of this application. It can be a bus structure or a star structure. The computer device 3 may also include more or fewer other hardware or software than shown, or different component arrangements.
[0222] In some embodiments, the computer device 3 is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions. Its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits, programmable gate arrays, digital processors, and embedded devices. The computer device 3 may also include client devices, which include, but are not limited to, any electronic product that can interact with a client via a keyboard, mouse, remote control, touchpad, or voice control device, such as personal computers, tablet computers, smartphones, and digital cameras.
[0223] It should be noted that the computer device 3 described is merely an example. Other existing or future electronic products that are suitable for this application should also be included within the scope of protection of this application and are incorporated herein by reference.
[0224] In some embodiments, the memory 31 stores a computer program that, when executed by the at least one processor 32, implements all or part of the steps in the interface data monitoring method described above. The memory 31 includes read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), one-time programmable read-only memory (OTPROM), electrically-erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, disk storage, magnetic tape storage, or any other computer-readable medium capable of carrying or storing data.
[0225] Furthermore, the computer-readable storage medium may primarily include a program storage area and a data storage area, wherein the program storage area may store the operating system, at least one application required for a function, etc.; and the data storage area may store data created based on the use of blockchain nodes, etc.
[0226] The blockchain referred to in this application is a novel application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanisms, and encryption algorithms. Essentially, a blockchain is a decentralized database, a chain of data blocks linked together using cryptographic methods. Each data block contains information about a batch of network transactions, used to verify the validity of the information (anti-counterfeiting) and generate the next block. A blockchain can include an underlying blockchain platform, a platform product service layer, and an application service layer.
[0227] In some embodiments, the at least one processor 32 is the control unit of the computer device 3, connecting various components of the computer device 3 via various interfaces and lines. It executes programs or modules stored in the memory 31 and calls data stored in the memory 31 to perform various functions and process data of the computer device 3. For example, when the at least one processor 32 executes the computer program stored in the memory, it implements all or part of the steps of the interface data monitoring method described in this application embodiment; or it implements all or part of the functions of the interface data monitoring device. The at least one processor 32 may be composed of integrated circuits, such as a single-packaged integrated circuit or multiple integrated circuits with the same or different functions, including combinations of one or more central processing units (CPUs), microprocessors, digital processing chips, graphics processors, and various control chips.
[0228] In some embodiments, the at least one communication bus 33 is configured to enable communication between the memory 31 and the at least one processor 32, etc.
[0229] Although not shown, the computer device 3 may also include a power supply (such as a battery) to power various components. Preferably, the power supply can be logically connected to the at least one processor 32 through a power management device, thereby enabling functions such as charging, discharging, and power consumption management. The power supply may also include one or more DC or AC power supplies, recharging devices, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components. The computer device 3 may also include various sensors, Bluetooth modules, Wi-Fi modules, etc., which will not be described in detail here.
[0230] The integrated unit implemented as a software functional module described above can be stored in a computer-readable storage medium. This software functional module, stored in a storage medium, includes several instructions to cause a computer device (which may be a personal computer, a computer device, or a network device, etc.) or a processor to execute portions of the methods described in the various embodiments of this application.
[0231] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules is only a logical functional division, and other division methods may be used in actual implementation.
[0232] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs.
[0233] Furthermore, the functional modules in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or in the form of hardware plus software functional modules.
[0234] It will be apparent to those skilled in the art that this application is not limited to the details of the exemplary embodiments described above, and that it can be implemented in other specific forms without departing from the spirit or essential characteristics of this application. Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of this application is defined by the appended claims rather than the foregoing description. Thus, all variations falling within the meaning and scope of equivalents of the claims are intended to be embraced within this application. No reference numerals in the claims should be construed as limiting the scope of the claims. Furthermore, it is clear that the word "comprising" does not exclude other elements or, and the singular does not exclude the plural. Multiple elements or devices recited in the specification may also be implemented by a single element or device through software or hardware. The terms "first," "second," etc., are used to indicate names and do not indicate any particular order.
[0235] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application and are not intended to limit it. Although this application has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of this application without departing from the spirit and scope of the technical solutions of this application.
Claims
1. A method for monitoring interface data, characterized in that, The interface data monitoring method includes: Determining the target historical data features corresponding to a preset interface includes: obtaining the initial historical data features corresponding to the preset interface; determining the importance value of the initial historical data features; selecting historical data features whose importance value exceeds a preset importance threshold from the initial historical data features as target historical data features, wherein the importance value characterizes the importance of the initial historical data features in the monitoring of the running status of the preset interface; Determine the target historical interface dataset corresponding to the target historical data features; Determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain the historical alarm level set; The target historical interface dataset and the data in the historical alarm level set are combined into training data to train the initial alarm level prediction model and obtain the alarm level prediction model. Acquire initial monitoring interface data and preprocess the initial monitoring interface data to obtain target monitoring interface data; The alarm level prediction model is invoked to process the target monitored interface data to obtain the target alarm level corresponding to the target monitored interface data. This includes: calculating the Euclidean distance between the target monitored interface data and each target historical interface data in the target historical interface dataset; selecting a first preset number of target historical interface data as first target historical interface data in ascending order of the Euclidean distance; selecting a second preset number of target historical interface data as second target historical interface data from the first target historical interface data; determining the target weight coefficient of the second target historical interface data; calculating the target weight distance corresponding to the second target historical interface data based on the target weight coefficient and the Euclidean distance; and selecting the alarm level with the largest target weight distance as the target alarm level corresponding to the target monitored interface data. The target weight coefficient represents the minimum Euclidean distance divided by the Euclidean distance between the second target historical interface data and the target monitored interface data to the power of n, where n is the number of features in the target historical data, and the second preset number is not greater than the square root of the first preset number.
2. The interface data monitoring method according to claim 1, characterized in that, The step of determining the target historical interface dataset corresponding to the target historical data features includes: Determine the initial historical interface dataset corresponding to the target historical data features; The first mathematical model is invoked to determine the average value of the historical interface data corresponding to the initial historical interface dataset; The second mathematical model is invoked to determine the standard deviation of the historical interface data corresponding to the initial historical interface dataset. The initial historical interface dataset is normalized by calling a third mathematical model based on the average value and standard deviation of the historical interface data to obtain the target historical interface dataset.
3. The interface data monitoring method according to claim 1, characterized in that, The step of determining the historical alarm level corresponding to each target historical interface data in the target historical interface dataset to obtain a historical alarm level set includes: Determine the historical interface logs corresponding to each target historical interface data in the target historical interface dataset; Determine the preset alarm keywords in the historical interface logs; The alarm information corresponding to the preset alarm keywords is used as the historical alarm level; By combining several historical alarm levels in the order of each target historical interface data in the target historical interface dataset, a historical alarm level set is obtained.
4. The interface data monitoring method according to claim 2, characterized in that, The preprocessing of the initial interface data to be monitored to obtain the target interface data to be monitored includes: Obtain the average value and standard deviation of the historical interface data corresponding to the initial historical interface dataset; The third mathematical model is invoked to normalize the initial interface data to be monitored based on the average value and standard deviation of the historical interface data, so as to obtain the target interface data to be monitored.
5. The interface data monitoring method according to claim 1, characterized in that, Selecting the alarm level with the largest target weight distance as the target alarm level corresponding to the target monitored interface data includes: Obtain the alarm level corresponding to the historical interface data of the second target; Based on the alarm level, the pre-set correspondence between alarm levels and weight distances is traversed to obtain the target weight distance corresponding to the alarm level; The alarm level with the largest target weight distance is selected as the target alarm level.
6. An interface data monitoring device, used to execute the interface data monitoring method as described in any one of claims 1 to 5, characterized in that, The interface data monitoring device includes: The feature determination module is used to determine the target historical data features corresponding to the preset interface; The data determination module is used to determine the target historical interface dataset corresponding to the target historical data features; The level determination module is used to determine the historical alarm level corresponding to each target historical interface data in the target historical interface dataset, and obtain a historical alarm level set; The model training module is used to combine the data from the target historical interface dataset and the historical alarm level set into training data, train the initial alarm level prediction model, and obtain the alarm level prediction model. The preprocessing module is used to acquire initial interface data to be monitored and preprocess the initial interface data to be monitored to obtain target interface data to be monitored. The alarm determination module is used to call the alarm level prediction model to process the target interface data to be monitored and obtain the target alarm level corresponding to the target interface data to be monitored.
7. A computer device, characterized in that, The computer device includes a processor and a memory, wherein the processor is used to implement the interface data monitoring method as described in any one of claims 1 to 5 when executing a computer program stored in the memory.
8. A computer-readable storage medium storing a computer program thereon, characterized in that, When the computer program is executed by the processor, it implements the interface data monitoring method as described in any one of claims 1 to 5.