A method and system for controlling abnormal data of financial transactions based on the Internet of Things
By only transmitting model parameters in financial transaction abnormal data control, a clustering model of financial transaction behavior is constructed and updated, which solves the problem of data leakage in the existing technology and improves data security and privacy protection.
Patent Information
- Application Number
- CN202410676718.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-29
- Publication Date
- 2024-08-27
- Estimated Expiration
- 2044-05-29
AI Technical Summary
Existing financial transaction abnormal data control methods lack privacy protection for original data and can easily lead to data leakage.
By obtaining the financial transaction behavior data of target users, converting it into behavior vectors, and performing cluster analysis to build a cluster model, only the model parameters are transmitted to the IoT federated server to build and update the global model parameters, avoiding the transmission of original data, and using The updated model detects abnormal behavior and handles alarms.
The risk of data leakage is reduced, and the privacy protection of original data and the data security of the abnormal data control process of financial transactions are improved.
Smart Images

Figure CN118245827B
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Internet of Things, and in particular to a method and system for controlling abnormal data in financial transactions based on the Internet of Things. Background Art
[0002] With the rapid development of modern information technology and the increasing risk of cyber attacks, enterprises are facing more and more security threats. In order to ensure the security and reliability of business operations and prevent security incidents caused by malicious operations or negligence of internal employees, timely and accurate monitoring of abnormal employee behavior is particularly necessary for enterprise operations. Employee behavior anomaly detection refers to monitoring and analyzing the financial transaction behavior of enterprise employees, identifying possible abnormal behaviors in employee operations, and issuing timely warnings for abnormal behaviors to prevent internal threat events.
[0003] At present, commonly used methods for detecting abnormal employee behavior include rule-based detection methods, machine learning-based detection methods, and deep learning-based detection methods. Among them, rule-based detection methods are limited by fixed rules, lack flexibility, and are difficult to adapt to the endless stream of new attack methods and hidden abnormal behaviors, and their scope of application is limited. Detection methods based on machine learning or deep learning can adaptively learn new attack methods and have high flexibility, but they require a large amount of data as training samples. In the process of modeling and detection, a large amount of raw data is needed, and there is a lack of privacy protection for the raw data, which poses a risk of data leakage. Summary of the invention
[0004] In view of the technical problems existing in the prior art, the present invention provides a method and system for controlling abnormal data of financial transactions based on the Internet of Things, so as to solve the technical problem that the existing abnormal data control method of financial transactions does not protect the privacy of original data and easily leads to data leakage.
[0005] The technical solution of the present invention to solve the above technical problems is as follows: A method for controlling abnormal data of financial transactions based on the Internet of Things, comprising:
[0006] Acquire the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector;
[0007] Performing cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and sending private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters;
[0008] Acquire the global model parameters issued by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal;
[0009] If it is detected that the financial transaction behavior of the target user is abnormal, an alarm will be issued to the target user.
[0010] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, the converting of the financial transaction behavior data into a behavior vector comprises:
[0011] Extracting the financial transaction behavior of the target user from the financial transaction behavior data, and the operation object corresponding to the financial transaction behavior;
[0012] Performing splicing processing on the financial transaction behavior and the operation object to obtain the behavior characteristics of the financial transaction behavior data;
[0013] The behavior characteristics are mapped based on a preset behavior library to obtain a behavior vector corresponding to the financial transaction behavior data; the behavior library is obtained by concatenating and unioning all the financial transaction behaviors and all the operation objects of the target user.
[0014] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, clustering analysis is performed on the behavior vector to construct a clustering model corresponding to the target user, including:
[0015] Acquire a user role of the target user, and classify the behavior vector of the target user according to the user role to obtain a set of behavior vectors corresponding to the user role;
[0016] Cluster analysis is performed on the behavior vectors in the behavior vector set to construct a cluster model corresponding to the target user; the private model parameters of the cluster model include the category center vector corresponding to the user role, and the category center vector is obtained by cluster analysis on the behavior vectors in the behavior vector set corresponding to the user role.
[0017] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, the updated clustering model is used to detect whether the financial transaction behavior of the target user is abnormal, including:
[0018] Acquire target financial transaction behavior data of the target user to be detected, and convert the target financial transaction behavior data into a target behavior vector of the target user; the target financial transaction behavior data is arranged in the order of operation time;
[0019] Performing sliding window processing on the target behavior vector based on a preset sliding step size, and calculating the cosine similarity between the target behavior vector in the time window and the model parameters of the updated clustering model during the sliding window processing to determine the threat level of the target user;
[0020] It is determined whether the financial transaction behavior of the target user is abnormal according to the threat level.
[0021] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, if the financial transaction behavior of the target user is detected to be abnormal, an alarm is issued to the target user, including:
[0022] If the financial transaction behavior of the target user is abnormal, determining an alarm level corresponding to the abnormal financial transaction behavior of the target user according to the threat level;
[0023] The target user is warned of the problem according to the measures corresponding to the warning level; the measures include forced account offline, account login restriction and account ban.
[0024] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, the step of obtaining the financial transaction behavior data of a local target user within a preset historical time period includes:
[0025] Acquire historical financial transaction behavior data of a local target user, and perform structured processing on the historical financial transaction behavior data to obtain structured data corresponding to the financial transaction behavior of the target user;
[0026] Based on the operation time sequence of the historical financial transaction behavior data, the structured data is segmented according to a preset time length to obtain the financial transaction behavior data of the target user within a preset historical time period.
[0027] According to a method for controlling abnormal financial transaction data based on the Internet of Things provided by the present invention, if the financial transaction behavior of the target user is detected to be abnormal, after issuing an alarm to the target user, the method further includes:
[0028] Obtain a weight modification factor corresponding to the alarm level, and send the weight modification factor to the IoT federation server, so that the IoT federation server can modify the weight of the private model parameter of the client corresponding to the target user according to the weight modification factor; the weight is used to calculate the global model parameter.
[0029] The present invention also provides a financial transaction abnormal data control system based on the Internet of Things, comprising:
[0030] A data processing module, used to obtain the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector;
[0031] A modeling module, used for performing cluster analysis on the behavior vector to construct a clustering model corresponding to the target user, and sending private model parameters of the clustering model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters;
[0032] An anomaly detection module, used to obtain the global model parameters sent by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal;
[0033] The financial transaction anomaly control module is used to issue an alarm to the target user if an abnormality is detected in the financial transaction behavior of the target user.
[0034] The present invention also provides an electronic device, comprising: a memory for storing a computer software program; a processor for reading and executing the computer software program, thereby implementing any of the above-mentioned methods for controlling abnormal financial transaction data based on the Internet of Things.
[0035] The present invention also provides a non-transitory computer-readable storage medium, in which a computer software program is stored. When the computer software program is executed by a processor, it implements any of the above-mentioned methods for controlling abnormal financial transaction data based on the Internet of Things.
[0036] The present invention also provides a computer program product, including a computer program, which, when executed by a processor, implements any of the above-mentioned methods for controlling abnormal financial transaction data based on the Internet of Things.
[0037] The beneficial effects of the present invention are: obtaining the financial transaction behavior data of local users in a preset historical time period and converting it into a behavior vector, clustering the behavior vector to build a local clustering model, and sending the private model parameters of the clustering model to the Internet of Things federation server; updating the local clustering model according to the global model parameters to detect whether the financial transaction behavior of local users is abnormal; if the financial transaction behavior of the target user is detected to be abnormal, the target user is warned. The present invention constructs a model for detecting abnormal behavior through federated learning. In the process of model construction and detection, only the transmission of model parameters is involved, which avoids the transmission of original data, reduces the risk of data leakage, improves the privacy protection of original data, and improves the data security of the abnormal data control process of financial transactions. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] Figure 1 This is one of the flow charts of the abnormal data control method for financial transactions based on the Internet of Things provided by the present invention;
[0039] Figure 2 is a schematic diagram of a distributed architecture of federated learning provided by an embodiment of the present invention;
[0040] Figure 3 is a modeling flow chart provided by an embodiment of the present invention;
[0041] Figure 4 This is the second flow chart of the abnormal data control method for financial transactions based on the Internet of Things provided by the present invention;
[0042] Figure 5 This is the third flow chart of the abnormal data control method for financial transactions based on the Internet of Things provided by the present invention;
[0043] Figure 6 It is a structural diagram of the financial transaction abnormal data control system based on the Internet of Things provided by the present invention;
[0044] Figure 7 A schematic diagram of an electronic device according to an embodiment of the present invention;
[0045] Figure 8 A schematic diagram of an embodiment of a computer-readable storage medium provided for an embodiment of the present invention. DETAILED DESCRIPTION
[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0047] In the description of the present invention, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Thus, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the present invention, the meaning of "plurality" is two or more, unless otherwise clearly and specifically defined.
[0048] In the description of the present invention, the term "for example" is used to mean "used as an example, illustration or explanation". Any embodiment described as "for example" in the present invention is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is given to enable any technician in the field to implement and use the present invention. In the following description, details are listed for the purpose of explanation. It should be understood that a person of ordinary skill in the art can recognize that the present invention can be implemented without using these specific details. In other examples, well-known structures and processes will not be elaborated in detail to avoid obscuring the description of the present invention with unnecessary details. Therefore, the present invention is not intended to be limited to the embodiments shown, but is consistent with the widest scope consistent with the principles and features disclosed in the present invention.
[0049] Combine the following Figure 1 The present invention describes a method for controlling abnormal data in financial transactions based on the Internet of Things, which is applied to a client and specifically includes steps 100 to 400:
[0050] Figure 1 This is a flowchart of a method for controlling abnormal financial transaction data based on the Internet of Things provided by an embodiment of the present invention. Figure 1 The method for controlling abnormal financial transaction data based on the Internet of Things provided by an embodiment of the present invention may include:
[0051] Step 100, obtaining the financial transaction behavior data of the local target user within a preset historical time period, and converting the financial transaction behavior data into a behavior vector;
[0052] Step 200, performing cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and sending the private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns the global model parameters according to the private model parameters;
[0053] Step 300, obtaining the global model parameters sent by the IoT federation server, updating the clustering model according to the global model parameters, and using the updated clustering model to detect whether there is any abnormality in the financial transaction behavior of the target user.
[0054] Step 400: If it is detected that the financial transaction behavior of the target user is abnormal, an alarm is issued to the target user.
[0055] Optionally, the financial transaction behavior data of the target user in the local client within a preset time period is obtained, and the financial transaction behavior data is converted into a behavior vector. It can be known that the target user may include one or more. When the target user includes multiple users, the obtained financial transaction behavior data includes the financial transaction behavior data of each target user in the preset historical time period, and the financial transaction behavior data of any target user corresponds to a behavior vector.
[0056] Optionally, the financial transaction behavior data corresponding to the same target user in a preset historical time period may include one or more financial transaction behaviors, and the one or more financial transaction behaviors correspond to the behavior vector of the target user. In one embodiment, the behavior vectors of different target users have the same dimension, and the dimension size of the behavior vector is related to the duration of the preset historical time period. For example, the longer the duration, the more financial transaction behaviors the target user can generate in the time period, and the larger the dimension of the corresponding behavior vector. The dimension size of the behavior vector can be determined according to the maximum number of financial transaction behaviors that the target user can generate in the preset time period.
[0057] Optionally, based on the behavior vector of the target user, by clustering the behavior vector corresponding to the financial transaction behavior of the target user, a local clustering model of the client corresponding to the target user is constructed, and the private model parameters of the clustering model are sent to the IoT federation server. Then, the global model parameters issued by the IoT federation server are obtained, and the local clustering model is updated according to the global model parameters. The updated clustering model is used to detect whether there are any abnormalities in the financial transaction behavior of the local target user. Among them, the global model parameters are determined by the IoT federation server according to the private model parameters reported by each client. The client updates the local clustering model according to the global model parameters issued by the IoT federation server, specifically, updates the private model parameters of the local clustering model. The updating method includes but is not limited to replacing the private model parameters with the global model parameters.
[0058] Specifically, the IoT federation server is responsible for receiving the private model parameters of all clients participating in the federated learning, and determining the global model parameters based on the received private model parameters of each client, and sending the global model parameters to each client. Optionally, the global model parameters corresponding to different clients may be the same or different. When different clients correspond to the same global model parameters, the global model parameters sent by the IoT federation server may be the optimal parameters selected by the IoT federation server from the private model parameters reported by each client, or may be the model parameters obtained by the IoT federation server through weighted calculation of the private model parameters reported by each client; when different clients correspond to different global model parameters, the global model parameters may also be obtained by the IoT federation server by adjusting the private model parameters reported by each client. The IoT federation server may adjust the private model parameters of the client, including but not limited to, fine-tuning the private model parameters of other clients based on the optimal parameters among the private model parameters reported by each client.
[0059] Furthermore, each client participating in federated learning updates the local clustering model according to the global model parameters sent by the IoT federation server, and uses the updated clustering model to detect whether there are any abnormalities in the financial transaction behaviors of each local target user. Specifically, the model parameters of the constructed clustering model are updated with the global model parameters sent by the IoT federation server, and the financial transaction behavior data of the local target users are detected using the clustering model after the parameter update, so as to determine whether there are any abnormalities in the financial transaction behaviors of the local target users.
[0060] In the process of federated learning, the construction of clustering models and the detection of abnormal behaviors only involve the transmission of model parameters, and the original data used only exists locally. Therefore, the privacy and security of the original data can be protected, the risk of data leakage can be reduced, and the data security in the modeling and detection process can be improved.
[0061] Furthermore, if an abnormality is detected in the financial transaction behavior of the target user, an alarm will be issued to the target user, such as forcibly logging off the target user's account, restricting login to the account, or banning the account.
[0062] In an embodiment of the present invention, the client converts the financial transaction behavior data of the local user into a behavior vector, thereby constructing a clustering model, and sends the private model parameters to the IoT federation server, and the IoT federation server determines the global model parameters based on the private model parameters of each client, and sends the global model parameters to the client. The client performs anomaly detection on the financial transaction behavior of the local user based on the global model parameters sent by the IoT federation server, and if the target user's financial transaction behavior is detected to be abnormal, an alarm is issued to the target user. Therefore, the embodiment of the present invention constructs a model for detecting abnormal behavior through federated learning. In the process of model construction and detection, only the transmission of model parameters is involved, which avoids the transmission of original data, reduces the risk of data leakage, and improves the privacy protection of original data, thereby improving the data security of the abnormal data control process of financial transactions based on the Internet of Things.
[0063] Optionally, in step 100, obtaining the financial transaction behavior data of the local target user within a preset historical time period specifically includes:
[0064] Step 101, obtaining historical financial transaction behavior data of a local target user, and performing structured processing on the historical financial transaction behavior data to obtain structured data corresponding to the financial transaction behavior of the target user;
[0065] Step 102 , segmenting the structured data according to a preset time length based on the operation time sequence of the historical financial transaction behavior data, and obtaining the financial transaction behavior data of the target user within a preset historical time period.
[0066] When obtaining the financial transaction behavior data of the local target user within a preset historical time period, first obtain the local historical financial transaction behavior data of the target user, and perform structured processing on the historical financial transaction behavior data to obtain structured data corresponding to the financial transaction behavior of the target user. Based on the operation time sequence of the historical financial transaction behavior data, the structured financial transaction behavior data is segmented according to a preset time length to obtain the financial transaction behavior data of the target user within the preset historical time period, wherein the preset time length is the time length corresponding to the preset historical time period.
[0067] The user's financial transaction behavior on the local client will generally be recorded in the database. The local client includes various operation types such as local devices, remote hosts and remote databases. Due to the differences in the systems and host categories of different clients, the data format of the recorded user's financial transaction behavior may also be different. By structuring the user's financial transaction behavior data, it is helpful to unify the data standards and formats, which is convenient for subsequent processing.
[0068] In one embodiment, structured financial transaction behavior data includes data source, operating user, operating user identification, operation time, financial transaction behavior and operation object, wherein the data source is a local host, a remote host or a remote database. For example, the operating user is "Zhang XX", the data source is a local host, the financial transaction behavior is, for example, "open", the operation object is, for example, "Document / ", and the operation time is, for example, "xx year xx month xx day xx hour xx minute xx second". Then the financial transaction behavior data of user "Zhang XX" is "open" "Document / " (file) on the local host at "xx year xx month xx day xx hour xx minute xx second".
[0069] Optionally, in step 100, converting the target user's financial transaction behavior data into a behavior vector may also include:
[0070] Step 103, extracting the financial transaction behavior of the target user from the financial transaction behavior data, and the operation object corresponding to the financial transaction behavior;
[0071] Step 104, performing splicing processing on the financial transaction behavior and the operation object to obtain the behavior characteristics of the financial transaction behavior data;
[0072] Step 105, mapping the behavior features based on a preset behavior library to obtain a behavior vector corresponding to the financial transaction behavior data; the behavior library is obtained by concatenating and unioning all the financial transaction behaviors and all the operation objects of the target user.
[0073] First, the target user's financial transaction behavior and the operation object affected by the financial transaction behavior are extracted from the financial transaction behavior data, and the financial transaction behavior and the operation object are spliced to obtain the behavior features of the target user's financial transaction behavior data, and the extracted behavior features are mapped based on the preset behavior library to obtain the behavior vector corresponding to the target user's financial transaction behavior data. The preset behavior library is obtained by splicing and union of the target user's right financial transaction behavior and all the operation objects.
[0074] Specifically, the financial transaction behavior data corresponding to the same target user may include one or more financial transaction behaviors. Multiple financial transaction behaviors may act on the same or different operation objects. The same operation object may be subjected to multiple identical repeated financial transaction behaviors. The same operation object may also be subjected to multiple different financial transaction behaviors. The same financial transaction behavior may also be repeated multiple times and act on different operation objects.
[0075] As for the behavior library, different clients have their own behavior library, which is obtained by collecting the behavior characteristics of local target users. Specifically, the full amount of financial transaction behaviors of all target users of the local client and the operation objects pointed to by each financial transaction behavior are obtained, and each financial transaction behavior is spliced with the operation object it points to to obtain the behavior characteristics of each target user, and then the behavior characteristics of different target users are taken as the union to obtain the behavior library of the client. The behavior library of any client contains all the financial transaction behaviors that may be generated locally by the client, and all the operation objects that any financial transaction behavior may point to.
[0076] In one embodiment, the extraction of financial transaction behaviors and operation objects can be realized based on the structured financial transaction behavior data. Optionally, the types of financial transaction behaviors on different types of hosts are relatively few, so the financial transaction behaviors and operation objects can be spliced to obtain more abundant financial transaction behaviors and the variation forms of financial transaction behavior objects as marks for distinguishing employee behaviors. The user's operation data is segmented by time period or login session, and the user's financial transaction behavior data in a certain time period is regarded as a sample, and the sample is converted into a behavior vector.
[0077] When converting the behavior vector, the financial transaction behaviors and operation objects of all users in the client host are collected in advance, the financial transaction behaviors are combined and numbered, and the user behavior library is established. The samples are mapped according to the behavior library.
[0078] Exemplarily, a behavior library of a certain client is established as shown in List 1 below:
[0079] Table 1:
[0080] ;
[0081] Table 2:
[0082] ;
[0083] When performing vector conversion, if sample X is Zhang XX's financial transaction behavior in a certain historical period, including the three behaviors of "cd A, cat C, ssh E", then sample X is mapped and converted into a behavior vector, and its corresponding behavior number column is marked as 1, indicating that this financial transaction behavior has occurred in sample X. The behavior number column corresponding to the financial transaction behavior that does not exist in other sample X is marked as 0, as shown in Table 2 above, and the behavior vector corresponding to sample X is: "1, 0, 1, 0, 1, ..., 0".
[0084] Optionally, in step 200, cluster analysis is performed on the behavior vector to construct a cluster model corresponding to the target user, specifically including:
[0085] Step 201, obtaining a user role of a target user, and classifying the behavior vector of the target user according to the user role to obtain a behavior vector set corresponding to the user role;
[0086] Step 202, cluster analysis is performed on the behavior vectors in the behavior vector set to construct a cluster model corresponding to the target user; the private model parameters of the cluster model include the category center vector corresponding to the user role, and the category center vector is obtained by cluster analysis of the behavior vectors in the behavior vector set corresponding to the user role.
[0087] For the same client, different target users may have different user roles. Different user roles have great differences in financial transaction behaviors, while the same user roles have great commonalities in financial transaction behaviors. Therefore, when constructing a clustering model, cluster analysis is performed on the financial transaction behaviors of the same user roles.
[0088] Specifically, first obtain the user role of each target user. The user role can be divided according to the unit and / or position and / or job of the target user. Classify the behavior vectors of the target users according to their user roles to obtain a behavior vector set corresponding to each user role. The behavior vectors of target users with the same user role are divided into the same behavior vector set, and the behavior vectors of target users with different user roles are divided into different behavior vector sets. For each divided behavior vector set, cluster analysis is performed on the behavior vectors in the same behavior vector set, so as to construct a clustering model corresponding to the target users of the client. Among them, the private model parameters of the clustering model of the client include the category center vector corresponding to each user role, and the category center vector is obtained by clustering analysis of the behavior vectors in the behavior vector set corresponding to the user role.
[0089] Optionally, the local modeling process of the client is to obtain the centroid of the cluster of financial transaction behavior data under each category based on the user role. The category centroid is calculated according to the following formula (1). For example, the cluster center of role category 1 is:
[0090] ;
[0091] In formula (1), It represents the category center vector of the first user role, Num represents the number of users included in this user role, and the dimension of the vector is N, which is the dimension of the user's behavior library. is the value of the first dimension of the i-th sample, is the value of the Nth dimension of the ith sample. Aggregating and normalizing the behavior vectors of all users in the user role can obtain the centroid of the user role cluster, which is also the category center vector. The cluster center is calculated in this way for the category corresponding to each user role, and the local modeling of the client can be completed.
[0092] For example, a user role includes three users: Zhang A, Li B, and Wang C. After their financial transaction behavior data is converted into behavior vectors, the three behavior vectors obtained are:
[0093] 1, 0, 1, 0, 1, ..., 0; 1, 1, 1, 0, 1, ..., 0; 1, 0, 1, 0, 0, ..., 0.
[0094] According to the cluster centroid calculation method, the first dimension values of the three behavior vectors are "1, 1, 1" respectively, so the value of the first dimension of the cluster center is The values of the first dimension are "0, 1, 0" respectively, and the value of the second dimension of the cluster center is , the values of the cluster centers of other dimensions can be calculated in turn, and finally the category center vector under this category can be obtained.
[0095] Optionally, after obtaining the category center vector of each category, the client sends the category center vector and the behavior vector corresponding to the financial transaction behavior data used as samples for cluster analysis to each IoT federation server. The IoT federation server models the samples of the category center vector and behavior vector sent by each client to obtain global model parameters.
[0096] Specifically, during the federation modeling process, the IoT federation server first initializes the federation parameters. When it is first executed, the weight parameters are set according to the number of hosts participating in the federation calculation and the number of host samples. Generally, the calculation method of the i-th host weight is as shown in the following formula (2):
[0097] ;
[0098] Where M is the number of client hosts participating in federated learning. The more sample data a client host generates during the federated learning process, the greater the corresponding weight in federated learning. At initialization, the sum of the weights of all client hosts is 1.
[0099] When the IoT federation server is modeling the federation, the federation weight of each client host is loaded according to the category center vector and sample data of each client. The private model parameter of the local model of the i-th client host is set to , then in each The local clustering parameters of the jth user role are included in , for each user role j in the federated model, the cluster center vector is calculated as shown in formula (3):
[0100] ;
[0101] In the federated modeling process, each user role category has a corresponding category center vector, which is calculated based on the private model parameters output by each client host, and does not directly use the original financial transaction behavior data, so the modeling process can ensure the privacy of the user's financial transaction behavior. In other words, the category center vector as a global model parameter is obtained by weighted calculation of the category center vectors of the same user role reported by different clients.
[0102] Optionally, in step 300, the local clustering model is updated according to the global model parameters sent by the IoT federation server, and the updated clustering model is used to detect whether the financial transaction behaviors of local target users are abnormal, specifically including:
[0103] Step 301, obtaining target financial transaction behavior data of a target user to be detected, and converting the target financial transaction behavior data into a target behavior vector of the target user; the target financial transaction behavior data is arranged in the order of operation time;
[0104] Step 302, performing sliding window processing on the target behavior vector based on a preset sliding step length, and calculating the cosine similarity between the target behavior vector in the time window and the model parameters of the updated clustering model during the sliding window processing to determine the threat level of the target user;
[0105] Step 303: Determine whether the target user's financial transaction behavior is abnormal based on the threat level.
[0106] When the client performs anomaly detection on the financial transaction behavior of a local target user, it first obtains the target user's financial transaction behavior data to be detected as a sample to be detected. The financial transaction behavior data can be a historical record of the target user's latest financial transaction behavior, and converts the financial transaction behavior data as the sample to be detected into a corresponding behavior vector, namely, the target behavior vector.
[0107] Furthermore, based on a preset sliding step length, a sliding window process is performed on the target behavior vector. During the sliding window process, the cosine similarity between the target behavior vector in the time window and the model parameters of the updated clustering model is calculated, and the threat level of abnormal financial transaction behavior of the target user is determined based on the cosine similarity. Whether the financial transaction behavior of the target user is abnormal is determined based on the threat level.
[0108] Exemplarily, if the threat level of the target user is greater than a preset threshold, the financial transaction behavior of the target user is abnormal; conversely, if the threat level of the target user is less than or equal to the preset threshold, the financial transaction behavior of the target user is not abnormal.
[0109] Optionally, when the client performs anomaly detection on the user's financial transaction behavior locally, it first obtains the sample to be detected, as well as the preset sliding window size and sliding step size, and arranges the financial transaction behavior data of each local user in the sample to be detected in chronological order. Taking the sliding window size of 10 as an example, the sliding window processing method is adopted. For each user i, the sliding window is moved to the earliest 10 financial transaction behaviors of user i, and the behavior vectors corresponding to the financial transaction behaviors of the users in the sliding window are merged and recorded as behavior vector X. Global model parameters issued by the IoT federation server , calculate the cosine similarity between user i and the global model parameters according to the following formula:
[0110] ;
[0111] The threat level of behavior vector X is: , and then slide the time window by one grid in chronological order, remove the earliest behavior vector in the time window, and add a behavior vector, repeat the above threat degree calculation process until the financial transaction behaviors of all users in the sample to be detected are detected. Among them, the sliding window size can be configured according to the actual detection needs, that is, according to the number of financial transaction behaviors required to detect whether there are abnormal financial transaction behaviors, the sliding window size is determined, so that according to the financial transaction behaviors of any user in the window, whether the user has abnormal financial transaction behaviors can be detected.
[0112] The existing abnormal data control methods for financial transactions based on the Internet of Things lack dynamic update mechanisms and abnormal measurement mechanisms. For the dynamic update mechanism, most of the abnormal data control methods for financial transactions based on the Internet of Things perform analysis and detection according to the established detection rules. Usually, these detection methods are solidified with specific algorithms or processing processes as carriers, and perform deterministic abnormal detection, and cannot be dynamically adjusted according to actual needs. Especially in the distributed anomaly detection process, it is not possible to dynamically adjust the modeling process according to the abnormal detection situation, optimize the parameter weights of the detection nodes, and the detection model does not establish a feedback mechanism for the results, resulting in similar behaviors repeatedly reporting abnormalities. Some abnormal behaviors may even affect the accuracy of the overall modeling. For the abnormal measurement mechanism, some behaviors may not be attack behaviors, but in the detection process, regardless of whether the risk of financial transaction behaviors is high or low, the detection results only feedback "normal" or "abnormal". The lack of a measurement mechanism for abnormal behaviors makes it difficult to determine the importance and risk level of behaviors, causing trouble for security managers.
[0113] The embodiment of the present invention solves the privacy protection and data security issues in the model building process by establishing distributed anomaly detection under the federated learning architecture. At the same time, a model feedback mechanism is established to dynamically adjust the model parameters according to the anomaly recognition results, and dynamically update the model parameters to better adapt to the abnormal data control of financial transactions based on the Internet of Things under streaming data. Further, a sliding window method is used for detection, and the data is verified multiple times. According to the verification results, a detailed judgment result of the risk degree is given to improve the credibility and reference of the anomaly detection results.
[0114] Specifically, in step 400, if it is detected that the financial transaction behavior of the target user is abnormal, an alarm is issued to the target user, including:
[0115] Step 401: if the target user's financial transaction behavior is abnormal, determine the alarm level corresponding to the target user's abnormal financial transaction behavior according to the threat level;
[0116] Step 402: Perform an alarm treatment on the target user according to the treatment measures corresponding to the alarm level; the treatment measures include forced account offline, account login restriction and account ban
[0117] If the target user's financial transaction behavior is abnormal, the alarm level corresponding to the target user's abnormal financial transaction behavior is determined based on the calculated threat level, and the target user is given an alarm based on the disposal measures corresponding to the alarm level. The disposal measures include but are not limited to forced account offline, account login restriction and account ban.
[0118] Furthermore, after step 402, the following steps are further included:
[0119] Step 403, obtain the weight modification factor corresponding to the alarm level, and send the weight modification factor to the IoT federation server; the IoT federation server modifies the weight of the private model parameter of the client corresponding to the target user according to the weight modification factor; the weight is used to calculate the global model parameter.
[0120] Different alarm levels correspond to different weight modification factors. The weight modification factor corresponding to the alarm level is obtained and sent to the IoT federation server. The IoT federation server modifies the private model parameter weight of the client corresponding to the target user according to the weight modification factor. The weight modified by the IoT federation server is the weight used to calculate the global model parameter, that is, the parameter involved in the above formula (3) It is understandable that, for different clients, the weight modification factors corresponding to the same alarm level may be the same or different, and no specific limitation is made here.
[0121] By dynamically adjusting the weights of the model parameters, we can propose the impact of risk points on the category center vector during the modeling process. The higher the degree of behavioral abnormality, the more it deviates from the cluster center, which will cause the cluster center to shift during the modeling process and ultimately affect the model accuracy.
[0122] In one embodiment, based on Figure 2 The distributed architecture of federated learning shown in the figure, the abnormal data control method for financial transactions based on the Internet of Things provided by the embodiment of the present invention presents a "one total and multiple divisions" form in the overall detection process. The local hosts of multiple clients are connected to the Internet of Things federation server, and the detection of abnormal behaviors is completed through division of labor and cooperation.
[0123] Specifically, refer to Figure 3In the modeling process based on federated learning shown in the figure, multiple client local hosts are physically isolated and data isolated, and only model parameters are transmitted between them and the IoT federation server. The IoT federation server performs federated modeling based on the private model parameters reported by each client, forms a model parameter matrix, and determines the global model parameters to send to each client, so as to control the abnormal financial transaction data based on the IoT locally on the user client.
[0124] When the client performs abnormal data control of financial transactions based on the Internet of Things locally, it adopts a sliding window processing method to verify the samples to be detected multiple times. When abnormal behavior is detected, the corresponding weight modification factor is reported to the Internet of Things federation server according to the alarm level of the abnormal behavior. The Internet of Things federation server dynamically adjusts the weight of the client according to the weight modification factor, thereby establishing a model feedback mechanism. During the modeling process, the influence of risk point data on model accuracy is eliminated.
[0125] Further, refer to Figure 4 In the control process of abnormal financial transaction data based on the Internet of Things, the local host of the client receives the financial transaction behavior data of the local user and performs preprocessing, and the preprocessing includes the structuring and standardization of the financial transaction behavior data from different sources. Based on the processed financial transaction behavior data, the financial transaction behavior data is converted into a behavior vector through behavior mapping, so as to perform local modeling, obtain a local clustering model, and pass the local private model parameters to the Internet of Things federation server. It should be noted that in order to ensure the uniformity of the data format received by the Internet of Things federation server, each client needs to convert the format of the incoming model parameters when passing in the local private model parameters, and convert the model parameters into the federated data format preset by the Internet of Things federation server. The Internet of Things federation server initializes or updates the weights of each client host according to the private model parameters passed in by each client, and calculates based on the private model parameters to obtain the global model parameters and returns them to the client. The local host of the client performs abnormal detection on the financial transaction behavior of the local user based on the global model parameters issued by the Internet of Things federation server, and when abnormal behavior is detected, the abnormal behavior is processed according to its alarm level, and the weight modification factor corresponding to the alarm level is passed to the Internet of Things federation server. The IoT federation server modifies and updates the weight of the client according to the weight modification factor passed in by the client.
[0126] In the process of transmitting the model parameters, differential privacy, homomorphic encryption, etc. can be used to encrypt the model parameters before transmission. The local modeling process of the client local host and the federated modeling process of the IoT federated server can refer to the description in the above embodiments, which will not be repeated here.
[0127] In this embodiment, based on the federated learning architecture, in the modeling process of abnormal data control of financial transactions based on the Internet of Things, no original data is designed to be transmitted, only model parameters are transmitted, and the transmission of model parameters can also be encrypted and transmitted in the form of non-plaintext data to avoid data leakage caused by transmitting original data during the modeling process.
[0128] Furthermore, based on the dynamic adjustment mechanism of model parameters of abnormal data control results of financial transactions based on IoT, the cluster centers are updated in real time, the model detection performance is continuously optimized, and the impact of abnormal behaviors on the cluster centers during the modeling process is further reduced, thereby improving the detection accuracy.
[0129] For abnormal behavior, the evaluation of the degree of abnormality is refined, multiple alarm levels are set, and different handling measures are adopted according to different alarm levels. The modeling process is optimized and adjusted according to different alarm levels, which improves the expression ability of alarm results and the ability to interpret and handle abnormal behavior alarms.
[0130] based on Figure 5 The embodiment of the present invention provides a method for controlling abnormal financial transaction data based on the Internet of Things, which is applied to the Internet of Things federation server including S1-S2:
[0131] S1, obtaining private model parameters sent by each client; the private model parameters are obtained by the client building a clustering model based on the behavior vector; the behavior vector is obtained by the client transforming the financial transaction behavior data of the target user obtained in a preset historical time period;
[0132] S2, determine the global model parameters according to the private model parameters, and send the global model parameters to each client; the client updates the clustering model according to the global model parameters, and uses the updated clustering model to detect whether there are any abnormalities in the financial transaction behavior of the local target user.
[0133] The private model parameters sent by each client are obtained by the client constructing a clustering model based on the behavior vector. The private model parameters are the model parameters of the clustering model. The behavior vector used to construct the clustering model is obtained by the client transforming the financial transaction behavior data of the local target user obtained in a preset historical time period. The client obtains the financial transaction behavior data of one or more local target users in a preset historical time period, and transforms the financial transaction behavior data of each target user into a behavior vector corresponding to the target user, and constructs a clustering model based on the behavior vectors obtained by the transformation, thereby obtaining the private model parameters of the local modeling.
[0134] Furthermore, the global model parameters are determined according to the private model parameters of each client, and the global model parameters are sent to each client. The client updates the local clustering model according to the global model parameters sent by the IoT federation server, and uses the updated clustering model to detect whether there are any abnormalities in the financial transaction behaviors of local target users.
[0135] In this embodiment, in the modeling and detection process of abnormal data control of financial transactions based on the Internet of Things, federated learning only involves the transmission of model parameters, avoiding the transmission of original financial transaction behavior data, thereby avoiding data leakage caused by data transmission during the modeling and detection process, reducing the risk of data leakage and improving data security.
[0136] The abnormal financial transaction data control system based on the Internet of Things provided by the present invention is described below. The abnormal financial transaction data control system based on the Internet of Things described below and the abnormal financial transaction data control method based on the Internet of Things described above can be referenced to each other.
[0137] like Figure 6 As shown, Figure 6 The structure diagram of the abnormal financial transaction data control system based on the Internet of Things provided by the present invention includes:
[0138] The data processing module 601 is used to obtain the financial transaction behavior data of the local target user within a preset historical time period and convert the financial transaction behavior data into a behavior vector;
[0139] A modeling module 602 is used to perform cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and send private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters;
[0140] The anomaly detection module 603 is used to obtain the global model parameters sent by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal;
[0141] The financial transaction anomaly control module 604 is used to issue an alarm to the target user if it is detected that the financial transaction behavior of the target user is abnormal.
[0142] The embodiment of the present invention constructs a model for detecting abnormal behavior through federated learning. During the model construction and detection process, only the transmission of model parameters is involved, which avoids the transmission of original data, reduces the risk of data leakage, improves the privacy protection of original data, and improves the data security of the financial transaction abnormal data control process.
[0143] See also Figure 7 , Figure 7 Schematic diagram of an electronic device provided by an embodiment of the present invention. Figure 7 As shown, an embodiment of the present invention provides an electronic device 700, including a memory 710, a processor 720, and a computer program 711 stored in the memory 710 and executable on the processor 720. When the processor 720 executes the computer program 711, the following steps are implemented:
[0144] Acquire the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector;
[0145] Performing cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and sending private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters;
[0146] Acquire the global model parameters issued by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal;
[0147] If it is detected that the financial transaction behavior of the target user is abnormal, an alarm will be issued to the target user.
[0148] See also Figure 8 , Figure 8 Schematic diagram of an embodiment of a computer-readable storage medium provided in an embodiment of the present invention. Figure 8 As shown, this embodiment provides a computer-readable storage medium 800, on which a computer program 811 is stored. When the computer program 811 is executed by a processor, the following steps are implemented:
[0149] Acquire the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector;
[0150] Performing cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and sending private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters;
[0151] Acquire the global model parameters issued by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal;
[0152] If it is detected that the financial transaction behavior of the target user is abnormal, an alarm will be issued to the target user.
[0153] It should be noted that in the above embodiments, the description of each embodiment has its own emphasis, and for parts that are not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0154] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0155] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded computer, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0156] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0157] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0158] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.
[0159] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.
Claims
1. A method for controlling abnormal data in financial transactions based on the Internet of Things. It is characterized in that include: Acquire the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector; Performing cluster analysis on the behavior vector to construct a cluster model corresponding to the target user, and sending private model parameters of the cluster model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters; Acquire the global model parameters issued by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal; If the target user's financial transaction behavior is detected to be abnormal, an alarm is issued to the target user; The clustering analysis of the behavior vectors to construct a clustering model corresponding to the target user includes: Acquire a user role of the target user, and classify the behavior vector of the target user according to the user role to obtain a set of behavior vectors corresponding to the user role; Performing cluster analysis on the behavior vectors in the behavior vector set to construct a cluster model corresponding to the target user; the private model parameters of the cluster model include a category center vector corresponding to the user role, and the category center vector is obtained by performing cluster analysis on the behavior vectors in the behavior vector set corresponding to the user role; The process of constructing the clustering model is to obtain the centroid of the clusters of the financial transaction behavior data under each category according to the user role, specifically: The centroid of the category is calculated according to the following formula (1): ; Represents the category center vector of the first user role, Num represents the number of users contained in the user role, and the dimension of the vector is N; is the value of the first dimension of the i-th sample, is the value of the Nth dimension of the ith sample; aggregate and normalize the behavior vectors of all users in the user role to obtain the centroid of the user role cluster, and the centroid of the cluster is the category center vector; Send the category center vector and the behavior vector corresponding to the financial transaction behavior data used as samples for cluster analysis to each IoT federation server, so that the IoT federation server can model according to the samples of the category center vector and behavior vector sent by each client and obtain global model parameters; Among them, the IoT federation server initializes the federation parameters during the federation modeling process. When it is executed for the first time, the weight parameters are set according to the number of hosts participating in the federation calculation and the number of host samples. The weight of the i-th host The calculation method of is shown in the following formula (2): ; Among them, M is the number of client hosts participating in federated learning. The more sample data a client host generates during the federated learning process, the greater the corresponding weight in federated learning. At the time of initialization, the sum of the weights of all client hosts is 1. Among them, when the IoT federation server is building the federation model, the federation weight of each client host is loaded according to the category center vector and sample data of each client, and the private model parameter of the local model of the i-th client host is set to , then in each The local clustering parameters of the jth user role are included in , for each user role j in the federated model, its cluster center vector The calculation method is as follows: ; In the federated modeling process, each user role category corresponds to a category center vector, which is calculated based on the private model parameters output by each client host; the category center vector of the global model parameter is obtained by weighted calculation of the category center vectors of the same user role reported by different clients.
2. According to claim 1, the method for controlling abnormal financial transaction data based on the Internet of Things, It is characterized in that The converting the financial transaction behavior data into a behavior vector includes: Extracting the financial transaction behavior of the target user from the financial transaction behavior data, and the operation object corresponding to the financial transaction behavior; Performing splicing processing on the financial transaction behavior and the operation object to obtain the behavior characteristics of the financial transaction behavior data; The behavior characteristics are mapped based on a preset behavior library to obtain a behavior vector corresponding to the financial transaction behavior data; the behavior library is obtained by concatenating and unioning all the financial transaction behaviors and all the operation objects of the target user.
3. The method for controlling abnormal financial transaction data based on the Internet of Things according to claim 1, It is characterized in that The using the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal includes: Acquire target financial transaction behavior data of the target user to be detected, and convert the target financial transaction behavior data into a target behavior vector of the target user; the target financial transaction behavior data is arranged in the order of operation time; Performing sliding window processing on the target behavior vector based on a preset sliding step size, and calculating the cosine similarity between the target behavior vector in the time window and the model parameters of the updated clustering model during the sliding window processing to determine the threat level of the target user; It is determined whether the financial transaction behavior of the target user is abnormal according to the threat level.
4. The method for controlling abnormal financial transaction data based on the Internet of Things according to claim 3, It is characterized in that If the target user's financial transaction behavior is detected to be abnormal, an alarm is issued to the target user, including: If the financial transaction behavior of the target user is abnormal, determining an alarm level corresponding to the abnormal financial transaction behavior of the target user according to the threat level; The target user is warned of the problem according to the measures corresponding to the warning level; the measures include forced account offline, account login restriction and account ban.
5. The method for controlling abnormal financial transaction data based on the Internet of Things according to claim 4, It is characterized in that The obtaining of the local target user's financial transaction behavior data within a preset historical time period includes: Acquire historical financial transaction behavior data of a local target user, and perform structured processing on the historical financial transaction behavior data to obtain structured data corresponding to the financial transaction behavior of the target user; Based on the operation time sequence of the historical financial transaction behavior data, the structured data is segmented according to a preset time length to obtain the financial transaction behavior data of the target user within a preset historical time period.
6. The method for controlling abnormal financial transaction data based on the Internet of Things according to claim 5, It is characterized in that If the target user's financial transaction behavior is detected to be abnormal, after issuing an alarm to the target user, the method further includes: Obtain a weight modification factor corresponding to the alarm level, and send the weight modification factor to the IoT federation server, so that the IoT federation server can modify the weight of the private model parameter of the client corresponding to the target user according to the weight modification factor; the weight is used to calculate the global model parameter.
7. A financial transaction abnormal data control system based on the Internet of Things, It is characterized in that include: A data processing module, used to obtain the financial transaction behavior data of the local target user within a preset historical time period, and convert the financial transaction behavior data into a behavior vector; A modeling module, used for performing cluster analysis on the behavior vector to construct a clustering model corresponding to the target user, and sending private model parameters of the clustering model to the IoT federation server, so that the IoT federation server returns global model parameters according to the private model parameters; An anomaly detection module, used to obtain the global model parameters sent by the IoT federation server, update the clustering model according to the global model parameters, and use the updated clustering model to detect whether the financial transaction behavior of the target user is abnormal; A financial transaction anomaly control module, configured to issue an alarm to the target user if an abnormality is detected in the target user's financial transaction behavior; The clustering analysis of the behavior vectors to construct a clustering model corresponding to the target user includes: Acquire a user role of the target user, and classify the behavior vector of the target user according to the user role to obtain a set of behavior vectors corresponding to the user role; Performing cluster analysis on the behavior vectors in the behavior vector set to construct a cluster model corresponding to the target user; the private model parameters of the cluster model include a category center vector corresponding to the user role, and the category center vector is obtained by performing cluster analysis on the behavior vectors in the behavior vector set corresponding to the user role; The process of constructing the clustering model is to obtain the centroid of the clusters of the financial transaction behavior data under each category according to the user role, specifically: The centroid of the category is calculated according to the following formula (1): ; Represents the category center vector of the first user role, Num represents the number of users contained in the user role, and the dimension of the vector is N; is the value of the first dimension of the i-th sample, is the value of the Nth dimension of the ith sample; aggregate and normalize the behavior vectors of all users in the user role to obtain the centroid of the user role cluster, and the centroid of the cluster is the category center vector; Send the category center vector and the behavior vector corresponding to the financial transaction behavior data used as samples for cluster analysis to each IoT federation server, so that the IoT federation server can model according to the samples of the category center vector and behavior vector sent by each client and obtain global model parameters; Among them, the IoT federation server initializes the federation parameters during the federation modeling process. When it is executed for the first time, the weight parameters are set according to the number of hosts participating in the federation calculation and the number of host samples. The weight of the i-th host The calculation method of is shown in the following formula (2): ; Among them, M is the number of client hosts participating in federated learning. The more sample data a client host generates during the federated learning process, the greater the corresponding weight in federated learning. At the time of initialization, the sum of the weights of all client hosts is 1. Among them, when the IoT federation server is building the federation model, the federation weight of each client host is loaded according to the category center vector and sample data of each client, and the private model parameter of the local model of the i-th client host is set to , then in each The local clustering parameters of the jth user role are included in , for each user role j in the federated model, its cluster center vector The calculation method is as follows: ; In the federated modeling process, each user role category corresponds to a category center vector, which is calculated based on the private model parameters output by each client host; the category center vector of the global model parameter is obtained by weighted calculation of the category center vectors of the same user role reported by different clients.
8. An electronic device, It is characterized in that include: Memory for storing computer software programs; A processor is used to read and execute the computer software program, thereby implementing the abnormal data control method for financial transactions based on the Internet of Things as described in any one of claims 1-6.
9. A non-transitory computer-readable storage medium, It is characterized in that The storage medium stores a computer software program, and when the computer software program is executed by the processor, the method for controlling abnormal financial transaction data based on the Internet of Things as described in any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Federal learning security aggregation method and apparatus, and electronic device
CN113919513A
Federal learning-based transaction risk prediction method, device and system
CN117237100A
Data anomaly detection method and device
CN117591860A
Abnormal financial account detection method and device based on federated learning privacy protection
CN117592096A
Abnormal transaction identification method and device, equipment and storage medium
CN117670364A
