Joint modeling method, system and medium based on financial data

By converting financial data into a unified format and utilizing coordinating encryption/decryption and secure multi-party computation techniques, the problem of data inconsistency between different institutions was solved, enabling efficient joint modeling and improving the accuracy and efficiency of the model.

CN120670381BActive Publication Date: 2025-10-28SANYA UNIVERSITY
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511180878.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-08-22
Publication Date
2025-10-28
Estimated Expiration
2045-08-22

AI Technical Summary

Technical Problem

Inconsistencies in data formats, feature definitions, and distribution among different financial institutions lead to poor joint modeling results, and privacy protection requirements limit data sharing.

Method used

The raw data from different institutions is converted into standard data in a unified format using standard templates. Encryption, decryption and verification are performed by the coordinator. Combined with secure multi-party computation technology, data verification and model training are achieved for each institution, ensuring data privacy. The model is trained using a federated learning framework, and important features are selected to participate in modeling.

Benefits of technology

While protecting data privacy, it solves the problem of inconsistent data formats and feature definitions, improves model training effectiveness and efficiency, avoids data silos, and meets the needs of different scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120670381B_ABST
    Figure CN120670381B_ABST
Patent Text Reader

Abstract

This application provides a joint modeling method, system, and medium based on financial data. The method includes: acquiring raw data from different participants and converting the raw data into standard data in a unified format according to a standard template; verifying the standard data using a verification tool to obtain a verification result for each participant; encrypting the verification result and sending it to a coordinator; the coordinator decrypting and verifying the encrypted verification result; after successful verification, the coordinator initializes a global model and sends the initial parameters of the global model to each participant; training the global model using the standard data from each participant to obtain an updated model; and after determining that the updated model meets the requirements, using the current updated model as the target model. This invention enables joint modeling of data from different financial institutions and ensures the efficiency and accuracy of the model after modeling.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of large model technology and relates to a method for financial data modeling, particularly a joint modeling method, system and medium based on financial data. Background Technology

[0002] In the financial sector, multiple institutions (such as banks, payment platforms, and insurance companies) need to jointly analyze data to complete tasks such as fraud detection, credit scoring, or risk assessment. However, due to privacy protection requirements, these institutions cannot directly share data. Privacy-preserving computation technology can help achieve joint modeling while protecting data privacy. However, in practical applications, privacy-preserving computation technology faces a significant challenge: inconsistencies in data formats, feature definitions, and distributions among different institutions increase the difficulty of joint modeling and affect its effectiveness. Summary of the Invention

[0003] The purpose of this application is to provide a joint modeling method, system, and medium based on financial data to solve the problem that data differences between different institutions affect the modeling effect in the prior art.

[0004] Firstly, this application provides a joint modeling method based on financial data, the method comprising:

[0005] Obtain raw data from different participants and convert the raw data into standard data in a unified format according to a standard template;

[0006] The standard data is verified using a verification tool to obtain a verification result for each participant. The verification result is then encrypted and sent to the coordinator, who decrypts and verifies the encrypted verification result.

[0007] After the verification is passed, the coordinator initializes the global model and sends the initial parameters of the global model to each participant.

[0008] The global model is trained using the standard data of each participant to obtain an updated model. After determining that the updated model meets the requirements, the current updated model is used as the target model.

[0009] In one implementation of the first aspect, the step of acquiring raw data from different participants and converting the raw data into standard data in a unified format according to a standard template includes:

[0010] Each of the participating parties reads the corresponding original data and loads the original data into a unified intermediate data structure for storage;

[0011] Based on the template features of the standard template, the original field features of the original data are compared one by one with the template features, so that inconsistent original field features are mapped to the corresponding template features through a mapping table, so that the original field features and the template features are consistent.

[0012] Based on the standard field type corresponding to the template feature in the standard template, the feature value corresponding to the original field feature in each original data is converted into the standard field type;

[0013] Obtain the standard unit corresponding to the standard field type, and convert the financial unit corresponding to the original field feature of the original data into the standard unit according to the exchange rate to obtain the standard data corresponding to each participant.

[0014] In one implementation of the first aspect, the step of verifying the standard data using a verification tool to obtain a verification result for each participant, encrypting the verification result and sending it to the coordinator, and then having the coordinator decrypt and verify the encrypted verification result, includes:

[0015] The verification tool performs local data verification on the standard data of each participant according to a preset verification logic to obtain the corresponding data verification result;

[0016] The verification tool performs differential privacy noise processing on the verified data to obtain a privacy verification result;

[0017] After each participant randomly splits its privacy verification result into multiple first random segments, each participant retains one of the first random segments and sends the remaining first random segments to the coordinator and the other participants.

[0018] The coordinator performs aggregation calculations on multiple of the first random fragments to obtain the privacy verification result, and verifies the privacy verification result to ensure that the data of each participating party meets the requirements.

[0019] In one implementation of the first aspect, the step of training the global model using the standard data of each participant to obtain an updated model, and then using the current updated model as the target model after determining that the updated model meets the requirements, includes:

[0020] Based on the standard data, the global model is trained by each of the participants to obtain the training parameters corresponding to each participant.

[0021] The training parameters of each participant are encrypted and uploaded to the coordinator. The coordinator updates the global model by aggregating the training parameters of each participant to obtain an updated model.

[0022] The updated model parameters are sent to each participant, and the above training process is repeated until the updated global model converges, thus obtaining the corresponding target model.

[0023] In one implementation of the first aspect, the step of training the global model based on the standard data by each of the participants to obtain training parameters corresponding to each participant includes:

[0024] Obtain the feature mapping table defined in the standard template, which is used to store the mapping relationship between the same features of different participants;

[0025] Based on the feature mapping table, verify whether the features in the standard data corresponding to different participants are aligned;

[0026] After determining the feature alignment among the different participants, each participant locally calculates the importance score for each feature;

[0027] Each of the participating parties splits the importance score of each feature into a third random field and then sends it to the coordinator and the other participating parties;

[0028] The coordinator and the other participants calculate the aggregate score corresponding to each feature based on the third random field of each participant;

[0029] The coordinator sorts the aggregate scores corresponding to each feature, selects the features whose aggregate scores are greater than a score threshold as target features, and sends the target features to each participant. The participants train the global model based on the data corresponding to each target feature to obtain the training parameters corresponding to each participant.

[0030] In one implementation of the first aspect, the step of encrypting and uploading the training parameters of each participant to the coordinator, and the coordinator updating the global model by aggregating the training parameters of each participant to obtain an updated model, includes:

[0031] The training parameters of each participant are divided into multiple second random segments. The multiple second random segments of each training parameter are encrypted and sent to the coordinator. The coordinator decrypts the encrypted second random segments to obtain multiple second random segments.

[0032] The coordinator calculates the training parameters corresponding to the current participant based on multiple second random segments;

[0033] The trained parameters of each participant are aggregated together to obtain aggregate parameters, and the global model is updated based on the aggregate parameters to obtain the updated model.

[0034] In one implementation of the first aspect, the method further includes:

[0035] After obtaining the target model, each participant performs a performance test on the target model based on its own test data to obtain performance test results. The performance test results are then encrypted and sent to the coordinator, who calculates the comprehensive performance index of the target model.

[0036] After confirming that the comprehensive performance indicators meet the requirements, the target model is verified in a trusted third-party environment to determine whether the target model meets business and privacy requirements.

[0037] In one implementation of the first aspect, after the target model has been running for a preset time, each of the participating parties trains the target model based on the latest data to update the parameters of the target model.

[0038] Secondly, this invention discloses a joint modeling system based on financial data, the system comprising:

[0039] The conversion module is used to acquire the raw data from different participants and convert the raw data into standard data in a unified format according to a standard template.

[0040] The verification module is used to verify the standard data using a verification tool to obtain the verification result for each participant, encrypt the verification result and send it to the coordinator, and the coordinator decrypts and verifies the encrypted verification result.

[0041] The sending module is used to initialize the global model through the coordinator after the verification is passed, and send the initial parameters of the global model to each of the participating parties;

[0042] The training module is used to train the global model using the standard data of each participant to obtain an updated model. After determining that the updated model meets the requirements, the current updated model is used as the target model.

[0043] Thirdly, the present invention also discloses a computer-readable storage medium having a computer program stored thereon, characterized in that the program, when executed, implements the above-mentioned joint modeling method based on financial data.

[0044] As described above, the joint modeling method, system, and medium based on financial data described in this application have the following beneficial effects:

[0045] This invention unifies the data format among different participants through a standard module, solving the problem of inconsistent data formats, feature definitions, and distributions among different participants while protecting the privacy of user data. Furthermore, it utilizes a federated learning framework to train the model simultaneously based on data from multiple participants, avoiding the problem of data silos and effectively improving the performance of the final trained model. In addition, during the modeling process, corresponding features are selected based on their importance to participate in the modeling, further improving the efficiency and accuracy of the model after modeling, thus meeting the needs of different usage scenarios. Attached Figure Description

[0046] Figure 1 The flowchart shown is a joint modeling method based on financial data as described in the embodiments of this application.

[0047] Figure 2 The diagram shown is a structural block diagram of the joint modeling system based on financial data as described in the embodiments of this application. Detailed Implementation

[0048] The following specific examples illustrate the implementation of this application. Those skilled in the art can easily understand other advantages and effects of this application from the content disclosed in this specification. This application can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of this application. It should be noted that, unless otherwise specified, the following embodiments and features in the embodiments can be combined with each other.

[0049] It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of this application. Therefore, the drawings only show the components related to this application and are not drawn according to the actual number, shape and size of the components in the actual implementation. In the actual implementation, the form, quantity and proportion of each component can be arbitrarily changed, and the layout of the components may also be more complex.

[0050] The following embodiments of this application provide a joint modeling method, system, and medium based on financial data. By standardizing the data format among different participants through standard modules, the inconsistencies in data format, feature definition, and distribution among different participants are resolved while protecting the privacy of user data. Furthermore, by utilizing a federated learning framework, training can be performed simultaneously on data from multiple participants, avoiding the problem of data silos and effectively improving the performance of the final trained model. In addition, during the modeling process, corresponding features are selected for modeling based on their importance, further improving the efficiency and accuracy of the model after modeling, thus meeting the needs of different usage scenarios.

[0051] like Figure 1 As shown in the figure, this embodiment provides a joint modeling method based on financial data, the method including the following steps:

[0052] S100. Obtain the raw data from different participants and convert the raw data into standard data in a unified format according to the standard template.

[0053] The participants are different financial institutions, such as banks, payment platforms, and insurance companies. Since the original data of different participants have different formats, feature definitions, and distributions, in the subsequent model training process, the original data is converted into standard data of a unified format through a standard template to facilitate subsequent model training and improve the performance of the model obtained from subsequent joint modeling training.

[0054] In some embodiments, obtaining raw data from different participants and converting the raw data into standard data in a unified format according to a standard template includes:

[0055] Each of the participating parties reads the corresponding original data and loads the original data into a unified intermediate data structure for storage;

[0056] Based on the template features of the standard template, the original field features of the original data are compared one by one with the template features, so that inconsistent original field features are mapped to the corresponding template features through a mapping table, so that the original field features and the template features are consistent.

[0057] Based on the standard field type corresponding to the template feature in the standard template, the feature value corresponding to the original field feature in each original data is converted into the standard field type;

[0058] Obtain the standard unit corresponding to the standard field type, and convert the financial unit corresponding to the original field feature of the original data into the standard unit according to the exchange rate to obtain the standard data corresponding to each participant.

[0059] In this embodiment, to process the raw data of each participant, each participant first reads its corresponding raw data and then loads it into a unified intermediate data structure using a parser for storage. The intermediate data structure includes a DataFrame, a built-in Python data storage structure that can store various data types from the raw data, facilitating subsequent standardization processing of the raw data using standard templates.

[0060] Then, based on the template features of the standard template, the original field features of the original data are compared one by one with the template features. This allows inconsistent original field features to be mapped to their corresponding template features through a mapping table, ensuring consistency between the original and template features. Specifically, if the original field features and template features are inconsistent, the mapping table maps the original field features to the template features. For example, if the original field feature is User ID and the template feature is Customer Number, then User ID is mapped to Customer Number. Similarly, if the original field feature is Amount and the template feature is Transaction Amount, then Amount is mapped to Transaction Amount. It should be noted that if a participant's original data has missing original field features, the participant is prompted to supplement them. If redundant original field features exist, they are ignored or deleted directly.

[0061] After completing the above processing, the feature values ​​corresponding to the original field features in each original data are further converted into standard field types. For example, if the standard field type is string, the feature values ​​corresponding to the original field features are converted into strings. For example, 12345 is converted to "12345". If the standard field type is float, the numeric type is unified to float. For example, if the original value is an integer or string (such as "1000"), it is converted to a float (such as 1000.0). Alternatively, if the standard type is datetime, the original time field is parsed according to the format in the template. For example, if the feature value of the original field feature is "2025 / 02 / 04 12:30:00" → template format YYYY-MM-DD HH:mm:ss → is converted to "2025-02-04 12:30:00". This ensures that the feature values ​​of each original field feature in the original data are converted into the standard field type of the corresponding template feature, guaranteeing that no subsequent data is missed. If the feature value type of the original field does not match the standard field type (e.g., the transaction amount contains non-numeric characters), an error will be displayed and the participant will be required to make corrections.

[0062] After the complete field type conversion, the standard unit corresponding to the standard field type is further obtained. Based on the exchange rate, the financial unit corresponding to the original field feature of the original data is converted into the standard unit to obtain the standard data corresponding to each participant.

[0063] For example, if the template feature in the standard template defines a unit (such as CNY), if the unit type of the original field feature is the same as the unit type of the corresponding template feature, no processing is performed; if they are different, they will be unified according to a preset exchange rate or conversion rule. For example:

[0064] Original value 100 USD → Exchange rate 1 USD = 6.5 CNY → Converted to 650.0 CNY.

[0065] When converting exchange rates, the real-time exchange rate is used as the standard. There are currently two ways to obtain exchange rate data. The first is to design a very simple input box so that users can manually enter the real-time exchange rate. Then, Python creates a new variable to store the user's input value and treat it as the real-time exchange rate. The second method requires connecting to a reliable exchange rate data service, such as the exchange rate query interface of the Bank of China or Alipay, which will not be elaborated on here.

[0066] Through the standardized processing described above, the raw data from multiple participants can be converted into standard data in a unified format, which facilitates subsequent joint modeling based on the standard data from multiple participants.

[0067] S200. The standard data is verified using a verification tool to obtain the verification result for each participant. The verification result is then encrypted and sent to the coordinator. The coordinator decrypts and verifies the encrypted verification result.

[0068] In some other embodiments, the step of verifying the standard data using a verification tool to obtain a verification result for each participant, encrypting the verification result and sending it to the coordinator, and then having the coordinator decrypt and verify the encrypted verification result includes:

[0069] The verification tool performs local data verification on the standard data of each participant according to a preset verification logic to obtain the corresponding data verification result;

[0070] The verification tool performs differential privacy noise processing on the verified data to obtain a privacy verification result;

[0071] After each participant randomly splits its privacy verification result into multiple first random segments, each participant retains one of the first random segments and sends the remaining first random segments to the coordinator and the other participants.

[0072] The coordinator performs aggregation calculations on multiple of the first random fragments to obtain the privacy verification result, and verifies the privacy verification result to ensure that the data of each participating party meets the requirements.

[0073] In this embodiment, after each participant obtains the standard data, a verification tool is run locally to verify it. The verification tool verifies the standard data to obtain the data verification results for each participant, thereby ensuring that the standard data of different participants meets the requirements and improving the effect of subsequent modeling.

[0074] Specifically, each participant first loads a standard template to obtain the template feature requirements. Then, they run a verification tool locally to verify the standard data. The verification tool performs local data verification on the standard data, including data type verification, date format verification, unit verification, and feature integrity verification. Data type verification verifies whether the data type corresponding to each feature of the standard data conforms to the standard template. Date format verification verifies whether the data format in the standard data conforms to the requirements of the standard template. Unit verification verifies whether the data unit in the standard data is consistent with the unit of the template feature in the standard template. Feature integrity verification verifies whether the standard data is missing any template feature from the standard template. Through the above verifications, the data verification result for each participant's standard data can be obtained to determine whether it meets the requirements.

[0075] After each participating party obtains its own data verification results, in order to further ensure the privacy and security of the data, differential privacy noise is used to add noise to the data verification results, thereby reducing the noise in the pass rate of the data verification results. The addition of noise is also completed in the MPC protocol to ensure that the noise generation process is secure.

[0076] Specifically, in this embodiment, the original verification results are processed using differential privacy-based Laplace noise or Gaussian noise. Laplace noise is suitable for count-type data (such as the number of features meeting the requirements), while Gaussian noise is suitable for continuous data (such as percentages). The magnitude of the noise is determined by the privacy budget. Control. Privacy Budget The value can be set manually and measures the strength of privacy protection. The smaller the value, the stronger the privacy protection, but the lower the accuracy of the results. The formula is as follows:

[0077] Report results = Verification results + Noise

[0078] The breadth of the reporting scope depends on the privacy budget and noise distribution; if the privacy budget is large ( Higher privacy, lower noise, and a narrower range (e.g., "94%~96%)" is possible if the privacy budget is small. (Lower), with higher noise, and a wider range (e.g., "90%~100%).

[0079] For example, taking the pass rate as the data verification result, if Laplace noise is used for differential privacy processing, the result after differential privacy processing satisfies the following formula:

[0080] ;

[0081] This indicates that the data verification result is the result after Laplace noise processing. For privacy budget, This indicates the data verification result. This indicates the preset sensitivity. Indicates based on 0 and Generate random noise that follows a Laplace distribution.

[0082] When Gaussian noise is used to perform differential privacy processing on the data verification results, the following formula is satisfied:

[0083] ;

[0084] ;

[0085] in, This indicates that the data verification result is the result after Laplace noise processing. This indicates the data verification result. This indicates that the mean is 0 and the variance is . Noise generated in a Gaussian distribution For privacy budget, This indicates the preset sensitivity; the lower the value, the better the differential privacy protection. This indicates the privacy parameter; the smaller the difference, the better the privacy protection.

[0086] It should be noted that the process of the coordinating party verifying the target result includes the verification of individual features and the verification of the overall data. When the compliance rate of the data corresponding to a certain feature in the standard data of the participating parties reaches the corresponding threshold, such as 95%, the current feature is determined to meet the requirements; otherwise, it does not. When all features in the standard data of the participating parties meet the qualification requirements, the overall data is qualified; otherwise, the overall data is unqualified.

[0087] Furthermore, when each participant verifies using the verification tool, if it is determined that certain features do not meet the requirements, the specific issues will be encrypted and sent to the coordinator. The coordinator will then provide modification suggestions so that the participants can make the necessary changes. This will not be elaborated further here.

[0088] Subsequently, based on the MPC protocol, each participant randomly divides its data verification result into multiple first random fragments. After retaining one of these fragments, each participant encrypts the remaining fragments and sends them to the coordinator and other participants. The coordinator then combines these fragments by aggregating them and decrypts them using the MPC protocol to obtain each participant's data verification result. Since only the final data verification result is decrypted, while intermediate processes and the original standard data are never arbitrarily accessed, data security is ensured. Secure Multi-Party Computation (MPC) is a cryptographic technique that allows multiple participants to collaboratively compute the result of a function without revealing their individual input data. Each participant's input data is completely confidential; only the computation result is disclosed, which will not be elaborated upon here.

[0089] S300. After the verification is passed, the coordinator initializes the global model and sends the initial parameters of the global model to each participant.

[0090] After the above format conversion and verification process, once the verification is confirmed to be successful, it is determined that the standard data of the participating parties all meet the requirements and joint modeling can be carried out. Then, the coordinator initializes the global model and sends the initial parameters of the global model to each participating party.

[0091] S400. The global model is trained using the standard data of each participant to obtain an updated model. After determining that the updated model meets the requirements, the current updated model is used as the target model.

[0092] In other embodiments, the step of training the global model using the standard data of each participant to obtain an updated model, and then using the current updated model as the target model after determining that the updated model meets the requirements, includes:

[0093] Based on the standard data, the global model is trained by each of the participants to obtain the training parameters corresponding to each participant.

[0094] The training parameters of each participant are encrypted and uploaded to the coordinator. The coordinator updates the global model by aggregating the training parameters of each participant to obtain an updated model.

[0095] The updated model parameters are sent to each participant, and the above training process is repeated until the updated global model converges, thus obtaining the corresponding target model.

[0096] In this embodiment, after each participant receives the initial parameters of the global model, they train the global model using their respective standard data to obtain training parameters for each participant. Then, the training parameters of each participant are encrypted and uploaded to the coordinator. The coordinator aggregates the training parameters of each participant and updates the global model based on the aggregation result to obtain an updated model. The coordinator then resends the updated parameters of the updated model to each participant, repeating the above training process until the updated global model converges, thus obtaining the final target model and completing the model training process.

[0097] In some other embodiments, the step of training the global model based on the standard data by each of the participants to obtain training parameters for each participant includes:

[0098] Obtain the feature mapping table defined in the standard template, which is used to store the mapping relationship between the same features of different participants;

[0099] Based on the feature mapping table, verify whether the features in the standard data corresponding to different participants are aligned;

[0100] After determining the feature alignment among the different participants, each participant locally calculates the importance score for each feature;

[0101] Each of the participating parties splits the importance score of each feature into a third random field and then sends it to the coordinator and the other participating parties;

[0102] The coordinator and the other participants calculate the aggregate score corresponding to each feature based on the third random field of each participant;

[0103] The coordinator sorts the aggregate scores corresponding to each feature, selects the features whose aggregate scores are greater than a score threshold as target features, and sends the target features to each participant. The participants train the global model based on the data corresponding to each target feature to obtain the training parameters corresponding to each participant.

[0104] In this embodiment, to further ensure the modeling effect, the model is trained by selecting features that contribute more during the training process, thereby making the final training parameters more accurate.

[0105] For example, the feature mapping table defined in the standard template is first retrieved to determine whether the features of different participants are aligned. This includes whether the feature definitions, units, value ranges, and data types are consistent. The feature mapping table provides the foundation for feature alignment, ensuring that different institutions know which features need alignment verification. For instance, each participant converts its feature definition (such as "single transaction amount") into a standardized numerical representation (such as the sum of ASCII codes). For example, participant A's feature definition is "single transaction amount," converted to the numerical value 12345. Participant B's feature definition is also "single transaction amount," converted to the numerical value 12345. If all values ​​are consistent, then the features of participant A and participant B are determined to be aligned.

[0106] After determining the feature alignment of different participants, each participant obtains the importance score of each feature locally. Each participant then splits the importance score of each feature into a third random field and sends it to the coordinator and the other participants. The coordinator and the other participants then aggregate multiple third random segments and calculate the average to obtain the aggregate score corresponding to each feature. The coordinator then sorts the aggregate scores and selects features with aggregate scores greater than a score threshold as target features. These target features are then sent to each participant. Each participant trains the global model based on the data corresponding to each target feature to obtain the training parameters corresponding to each participant. This allows features with high importance scores to participate in model training, improving the accuracy of the model obtained in subsequent training and effectively avoiding the problems of model information loss and incomplete targets.

[0107] In further embodiments, the step of encrypting and uploading the training parameters of each participant to the coordinator, and the coordinator updating the global model by aggregating the training parameters of each participant to obtain an updated model, includes:

[0108] The training parameters of each participant are divided into multiple second random segments. The multiple second random segments of each training parameter are encrypted and sent to the coordinator. The coordinator decrypts the encrypted second random segments to obtain multiple second random segments.

[0109] The coordinator calculates the training parameters corresponding to the current participant based on multiple second random segments;

[0110] The trained parameters of each participant are aggregated together to obtain aggregate parameters, and the global model is updated based on the aggregate parameters to obtain the updated model.

[0111] In this embodiment, after each participant obtains the corresponding training parameters, the training parameters are split into multiple second random segments based on the MPC protocol. Then, the multiple second random segments are sent to the coordinator. The coordinator calculates the current training parameters of the participant based on the MPC protocol. Then, the coordinator aggregates the training parameters of each participant to obtain aggregate parameters. Finally, the global model is updated based on the aggregate parameters to obtain the updated model.

[0112] For example, each participant receives model parameters (such as weights and biases) of the global model distributed by the coordinator. Each participant trains the global model using local standard data. After training, the model parameters are updated with new values, resulting in new model parameters. After local training, the participant generates updated model parameters (such as weight matrices and bias vectors). These parameters are trained based on the participant's local data and reflect the contribution of the local data to the model. To protect privacy, participants do not directly upload model parameters. Instead, they are encrypted using Secure Multi-Party Computation (MPC) before uploading. The participant divides the model parameters into multiple second random segments and sends them to the coordinator. The coordinator and other participants collaboratively compute the model parameters of each participant using the MPC protocol. Then, by calculating the weighted average of each model parameter from each participant, the corresponding aggregate parameters are obtained. After updating the global model based on the aggregate parameters, the final updated model is obtained.

[0113] Wherein, the aggregation parameter is represented as [ , ,..., ..., ], and the first The calculation process for each aggregation parameter satisfies the following formula:

[0114] ;

[0115] in, Indicates the number of training parameters. Indicates the first The first participating party One training parameter, Indicates the first The weight value corresponding to each participant , All are 1 to integers, The value is a positive integer greater than or equal to 2, and the weight value is the percentage of the data volume of the corresponding participant relative to the total data volume of all participants.

[0116] The specific process is as follows, taking the following case as an example:

[0117] (1) Local training

[0118] Each participant trains the model locally to update the model parameters.

[0119] For example, suppose the model parameters are a weight matrix W and a bias vector B, and the initial parameters, weight matrix and bias vector, are W0 and b0 (distributed by the coordinator), respectively. After local training by the participants, the parameters obtained are Wlocal and blocal.

[0120] (2) Parameter encryption

[0121] Each participant in the kernel model parameters will randomly split the updated model parameters Wlocal and blocal into multiple second random fragments.

[0122] (3) Parameter Upload

[0123] The encrypted model parameters are uploaded to the coordinator via a secure communication protocol (such as HTTPS).

[0124] (4) Parameter aggregation

[0125] The weighted average of the parameters of each model is calculated to obtain the aggregate parameters.

[0126] (5) Update the global model

[0127] After aggregation is complete, the coordinator updates the parameters of the global model based on the aggregation parameters to obtain the updated model, and then sends the parameters of the updated model to all participants.

[0128] For example, in federated learning or multi-party modeling, since each participant has a local model (or parameter vector), aggregation cannot be simply averaged because the amount or value of data differs among the participants. Here, we take three banks, A, B, and C, as an example. Bank A holds 5000 customer records, Bank B holds 15000 customer records, and Bank C holds 30000 customer records. Each bank has trained its corresponding global model locally and obtained its corresponding local parameters (e.g., each bank trained a logistic regression parameter vector).

[0129] Each of the three companies trained its local parameters and obtained:

[0130] param_A = [0.2, 0.5, -0.1]

[0131] param_B = [0.6, 0.7, 0.2]

[0132] param_C = [0.4, 0.4, 0.3]

[0133] The aggregated calculation yields the following weight values ​​for the three participants: weight_A, weight_B, and weight_C.

[0134] weight_A = 5000 / (5000 + 15000 + 30000) = 0.1

[0135] weight_B = 15000 / (5000 + 15000 + 30000) = 0.3

[0136] weight_C = 30000 / (5000 + 15000 + 30000) = 0.6

[0137] The corresponding aggregation parameters also have the same number as the training parameters, namely:

[0138] param_agg[0] = weight_A * param_A[0]+ weight_B * param_B[0] + weight_C * param_C[0]

[0139] = 0.1 * 0.2 + 0.3 * 0.6 + 0.6 * 0.4

[0140] = 0.02 + 0.18 + 0.24

[0141] = 0.44

[0142] Second dimension:

[0143] param_agg[1]

[0144] = 0.1 * 0.5 + 0.3 * 0.7 + 0.6 * 0.4

[0145] = 0.05 + 0.21 + 0.24

[0146] = 0.5

[0147] Third dimension:

[0148] param_agg[2]

[0149] = 0.1 * (-0.1) + 0.3 * 0.2 + 0.6 * 0.3

[0150] = -0.01 + 0.06 + 0.18

[0151] = 0.23

[0152] The final aggregation parameters are

[0153] param_agg = [0.44, 0.5, 0.23]

[0154] This completes the calculation process of the aggregation parameters.

[0155] In some other embodiments, the method further includes:

[0156] After obtaining the target model, each participant performs a performance test on the target model based on its own test data to obtain performance test results. The performance test results are then encrypted and sent to the coordinator, who calculates the comprehensive performance index of the target model.

[0157] After confirming that the comprehensive performance indicators meet the requirements, the target model is verified in a trusted third-party environment to determine whether the target model meets business and privacy requirements.

[0158] In this embodiment, after obtaining the target model, to further ensure its performance, a distributed evaluation method is used to evaluate the target model, ensuring data privacy during the evaluation process. Specifically, participating parties conduct tests locally using test data (provided externally or collected) to obtain performance test results, which represent the accuracy of the target model's performance against the test data. These performance test results are then encrypted and uploaded to the coordinator. The coordinator uses aggregation calculations to obtain the comprehensive performance index of the target model. After confirming that the comprehensive performance index of the target model meets the requirements, the target model is verified in a third-party environment (such as a sandbox environment) to ensure that it meets business requirements and privacy specifications. After completing the above verification process, the model evaluation is complete, and the target model is confirmed to meet the requirements.

[0159] For example, each participant evaluates model performance locally using its own test data, calculating the following metrics:

[0160] Assume that participant k's test data is (Xk, yk), and the model prediction result is y1k, specifically:

[0161] True positive (TP): The number of samples that were predicted to be positive and were actually positive.

[0162] False positive (FP): The number of samples that were predicted to be positive but were actually negative.

[0163] True negative (TN): The number of samples that were predicted to be negative and were actually negative.

[0164] False negative (FN): The number of samples that were predicted to be negative but were actually positive.

[0165] Assume that the number of true positives of participant k is TPk and the number of true negatives is TNk, and divide them into 3 random segments respectively:

[0166] TPk=share1+share2+share3, TNk=share4+share5+share6;

[0167] After each fragment is uploaded individually to the coordinator and the other participants, the coordinator aggregates the fragments and adds them together to obtain the encrypted result of the global metric. This allows for the calculation of comprehensive performance metrics, such as global accuracy. The specific calculation process is as follows:

[0168] Global accuracy = (TP + TN) / (TP + TN + FP + FN)

[0169] For example, assuming there are 3 participants, the results of their local test are as follows:

[0170] ·TP1=50,FP1=10,TN1=80,FN1=20

[0171] ·TP2=30,FP2=5,TN2=60,FN2=10

[0172] ·TP3=20,FP3=5,TN3=40,FN3=10

[0173] Each participant will then upload the test results in segments to the coordinator:

[0174] Participant 1: TP1=[20,15,15]

[0175] Participant 2: TP2=[10,10,10]

[0176] Participant 3: TP3=[5,10,5]

[0177] The coordinator then aggregates all fragments in an encrypted state to obtain a global confusion matrix:

[0178] TP = 50 + 30 + 20 = 100

[0179] FP = 10 + 5 + 5 = 20

[0180] TN = 80 + 60 + 40 = 180

[0181] FN = 20 + 10 + 10 = 40

[0182] Then, the global accuracy is calculated using the formula for global accuracy:

[0183] Global accuracy = (TP + TN) / (TP + TN + FP + FN) = (100 + 180) / (100 + 20 + 180 + 40) = 0.82

[0184] The final result is 0.82. Based on the global accuracy of the target model, the model performance can be evaluated to determine whether the target model meets the requirements.

[0185] It should be noted that there is no fixed standard for judging global accuracy. It is necessary to determine whether the current global accuracy is optimal after continuous model iteration, optimization and testing.

[0186] In some embodiments, after the target model has been running for a preset time, each of the participating parties trains the target model based on the latest data to update the parameters of the target model.

[0187] Since new data is constantly generated during the use of the model by various participants, in order to further ensure the accuracy of the model, after the target model has been running for a preset period of time, such as one month, each participant will use the latest data as the initial global model and repeat the above process to train the target model, thereby updating the target model and ensuring that the target model can be updated regularly to ensure the effectiveness of the target model.

[0188] The scope of protection of the joint modeling method based on financial data described in this application is not limited to the execution order of the steps listed in this embodiment. Any solution implemented by adding, subtracting, or replacing steps in the prior art based on the principles of this application is included within the scope of protection of this application.

[0189] This invention also discloses a joint modeling system based on financial data, with reference to Figure 2 The system includes:

[0190] The conversion module 201 is used to acquire the original data from different participants and convert the original data into standard data in a unified format according to a standard template.

[0191] Verification module 202 is used to verify the standard data using a verification tool to obtain a verification result for each participant, encrypt the verification result and send it to the coordinator, and then the coordinator decrypts and verifies the encrypted verification result.

[0192] The sending module 203 is used to initialize the global model through the coordinator after the verification is passed, and send the initial parameters of the global model to each of the participating parties;

[0193] The training module 204 is used to train the global model using the standard data of each participant to obtain an updated model, and after determining that the updated model meets the requirements, the current updated model is used as the target model.

[0194] It should be noted that the structure and principle of each of the above modules correspond one-to-one with the steps in the above-described joint modeling method based on financial data. Their specific working principles can also be found in the description of the joint modeling method based on financial data in the foregoing embodiments, and therefore will not be repeated here. Furthermore, the joint modeling system based on financial data can implement the joint modeling method based on financial data described in this application. However, the implementation apparatus for the joint modeling method based on financial data described in this application includes, but is not limited to, the structure of the joint modeling system based on financial data listed in this embodiment. Any structural modifications and substitutions of existing technologies made based on the principles of this application are included within the protection scope of this application.

[0195] The present invention also provides a computer-readable storage medium having a computer program stored thereon, which, when executed, implements the above-described joint modeling method based on financial data.

[0196] Those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing a processor. The program can be stored in a computer-readable storage medium, which is a non-transitory medium, such as random access memory, read-only memory, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof. The storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. This available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state drive (SSD)).

[0197] In the embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, or methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules / units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or units may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of apparatuses or modules or units may be electrical, mechanical, or other forms.

[0198] The modules / units described as separate components may or may not be physically separate. The components shown as modules / units may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules / units can be selected to achieve the objectives of the embodiments of this application, depending on actual needs. For example, the functional modules / units in the various embodiments of this application may be integrated into one processing module, or each module / unit may exist physically separately, or two or more modules / units may be integrated into one module / unit.

[0199] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0200] The descriptions of the processes or structures corresponding to the above figures each have their own emphasis. For parts of a process or structure that are not described in detail, please refer to the relevant descriptions of other processes or structures.

[0201] The above embodiments are merely illustrative of the principles and effects of this application and are not intended to limit this application. Any person skilled in the art can modify or alter the above embodiments without departing from the spirit and scope of this application. Therefore, all equivalent modifications or alterations made by those skilled in the art without departing from the spirit and technical concept disclosed in this application should still be covered by the claims of this application.

Claims

1. A joint modeling method based on financial data, characterized in that, The method includes: Obtain raw data from different participants and convert the raw data into standard data in a unified format according to a standard template; The standard data is verified using a verification tool to obtain a verification result for each participant. The verification result is then encrypted and sent to the coordinator, who decrypts and verifies the encrypted verification result. After the verification is passed, the coordinator initializes the global model and sends the initial parameters of the global model to each participant. The global model is trained using the standard data of each participant to obtain an updated model. After determining that the updated model meets the requirements, the current updated model is used as the target model. The step of acquiring raw data from different participants and converting the raw data into standardized data in a unified format according to a standard template includes: Each of the participating parties reads the corresponding original data and loads the original data into a unified intermediate data structure for storage; Based on the template features of the standard template, the original field features of the original data are compared one by one with the template features, so that inconsistent original field features are mapped to the corresponding template features through a mapping table, so that the original field features and the template features are consistent. Based on the standard field type corresponding to the template feature in the standard template, the feature value corresponding to the original field feature in each original data is converted into the standard field type; Obtain the standard unit corresponding to the standard field type, and convert the financial unit corresponding to the original field feature of the original data into the standard unit according to the exchange rate to obtain the standard data corresponding to each participant; The process of verifying the standard data using a verification tool to obtain a verification result for each participant, encrypting the verification result, sending it to the coordinator, and having the coordinator decrypt and verify the encrypted verification result includes: The verification tool performs local data verification on the standard data of each participant according to a preset verification logic to obtain the corresponding data verification result; The verification tool performs differential privacy noise processing on the verified data to obtain a privacy verification result; After each participant randomly splits its privacy verification result into multiple first random segments, each participant retains one of the first random segments and sends the remaining first random segments to the coordinator and the other participants. The coordinator performs aggregation calculations on multiple of the first random fragments to obtain the privacy verification result, and verifies the privacy verification result to ensure that the data of each participating party meets the requirements.

2. The joint modeling method based on financial data according to claim 1, characterized in that, The step of training the global model using the standard data of each participant to obtain an updated model, and then using the current updated model as the target model after determining that the updated model meets the requirements, includes: Based on the standard data, the global model is trained by each of the participants to obtain the training parameters corresponding to each participant. The training parameters of each participant are encrypted and uploaded to the coordinator. The coordinator updates the global model by aggregating the training parameters of each participant to obtain an updated model. The updated model parameters are sent to each participant, and the above training process is repeated until the updated global model converges, thus obtaining the corresponding target model.

3. The joint modeling method based on financial data according to claim 2, characterized in that, The step of training the global model based on the standard data by each participant to obtain training parameters for each participant includes: Obtain the feature mapping table defined in the standard template, which is used to store the mapping relationship between the same features of different participants; Based on the feature mapping table, verify whether the features in the standard data corresponding to different participants are aligned; After determining the feature alignment among the different participants, each participant locally calculates the importance score for each feature; Each of the participating parties splits the importance score of each feature into a third random field and then sends it to the coordinator and the other participating parties; The coordinator and the other participants calculate the aggregate score corresponding to each feature based on the third random field of each participant; The coordinator sorts the aggregate scores corresponding to each feature, selects the features whose aggregate scores are greater than a score threshold as target features, and sends the target features to each participant. The participants train the global model based on the data corresponding to each target feature to obtain the training parameters corresponding to each participant.

4. The joint modeling method based on financial data according to claim 2, characterized in that, The step of encrypting and uploading the training parameters of each participant to the coordinator, and the coordinator updating the global model by aggregating the training parameters of each participant to obtain an updated model, includes: The training parameters of each participant are divided into multiple second random segments. The multiple second random segments of each training parameter are encrypted and sent to the coordinator. The coordinator decrypts the encrypted second random segments to obtain multiple second random segments. The coordinator calculates the training parameters corresponding to the current participant based on multiple second random segments; The trained parameters of each participant are aggregated together to obtain aggregate parameters, and the global model is updated based on the aggregate parameters to obtain the updated model.

5. The joint modeling method based on financial data according to any one of claims 1-4, characterized in that, The method further includes: After obtaining the target model, each participant performs a performance test on the target model based on its own test data to obtain performance test results. The performance test results are then encrypted and sent to the coordinator, who calculates the comprehensive performance index of the target model. After confirming that the comprehensive performance indicators meet the requirements, the target model is validated in a trusted third-party environment to determine whether the target model meets business and privacy requirements.

6. The joint modeling method based on financial data according to claim 1, characterized in that, After the target model has been running for a preset time, each of the participating parties trains the target model based on the latest data to update the parameters of the target model.

7. A joint modeling system based on financial data, characterized in that, The system includes: The conversion module is used to acquire the raw data from different participants and convert the raw data into standard data in a unified format according to a standard template. The verification module is used to verify the standard data using a verification tool to obtain the verification result for each participant, encrypt the verification result and send it to the coordinator, and the coordinator decrypts and verifies the encrypted verification result. The sending module is used to initialize the global model through the coordinator after the verification is passed, and send the initial parameters of the global model to each of the participating parties; The training module is used to train the global model using the standard data of each participant to obtain an updated model. After determining that the updated model meets the requirements, the current updated model is used as the target model. The step of acquiring raw data from different participants and converting the raw data into standardized data in a unified format according to a standard template includes: Each of the participating parties reads the corresponding original data and loads the original data into a unified intermediate data structure for storage; Based on the template features of the standard template, the original field features of the original data are compared one by one with the template features, so that inconsistent original field features are mapped to the corresponding template features through a mapping table, so that the original field features and the template features are consistent. Based on the standard field type corresponding to the template feature in the standard template, the feature value corresponding to the original field feature in each original data is converted into the standard field type; Obtain the standard unit corresponding to the standard field type, and convert the financial unit corresponding to the original field feature of the original data into the standard unit according to the exchange rate to obtain the standard data corresponding to each participant; The process involves verifying the standard data using a verification tool to obtain a verification result for each participant, encrypting the verification result, sending it to the coordinator, and then having the coordinator decrypt and verify the encrypted verification result. This includes: The verification tool performs local data verification on the standard data of each participant according to a preset verification logic to obtain the corresponding data verification result; The verification tool performs differential privacy noise processing on the verified data to obtain a privacy verification result; After each participant randomly splits its privacy verification result into multiple first random segments, each participant retains one of the first random segments and sends the remaining first random segments to the coordinator and the other participants. The coordinator performs aggregation calculations on multiple of the first random fragments to obtain the privacy verification result, and verifies the privacy verification result to ensure that the data of each participating party meets the requirements.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed, it implements the joint modeling method based on financial data as described in any one of claims 1 to 6.

Citation Information

Patent Citations

  • Resource-sensitive joint financial fraud detection model training method and detection method

    CN111105240A

  • Lightweight privacy protection and integrity verification federated learning method, system and device and medium

    CN117196017A