Intelligent protection method for financial transaction data based on blockchain

By performing word vector analysis and clustering of financial transaction data, evaluating the correlation of financial transaction data, adaptively determining the optimal upload time interval of financial transaction data, the problem that the existing technology cannot meet the real-time requirements of different financial transaction services is solved, and the intelligent protection and efficient storage of financial transaction data are realized.

CN118573353BActive Publication Date: 2025-04-25BEIJING DIANKONG INTERNET INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410606942.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-05-16
Publication Date
2025-04-25
Estimated Expiration
2044-05-16

AI Technical Summary

Technical Problem

The existing methods cannot adaptively set the upload time interval of financial transaction data according to the characteristics of financial transaction data, resulting in the inability to meet the real-time requirements of different financial transaction services.

Method used

By obtaining each financial transaction data in each sub-time period within the preset time period and its corresponding word vectors, sample points are obtained based on the similarity of the word vectors, and clustering is performed, the correlation value of the financial transaction data of each cluster cluster is evaluated, and the optimal upload time interval is determined.

Benefits of technology

It realizes adaptively adjusting the upload time interval according to the characteristics of financial transaction data, meeting the real-time requirements of different financial transaction services, and improving the security and storage efficiency of financial transaction data.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118573353B_ABST
    Figure CN118573353B_ABST
Patent Text Reader

Abstract

The present invention relates to the technical field of financial transaction data management, and in particular to a method for intelligent protection of financial transaction data based on blockchain. The method includes: obtaining each piece of financial transaction data and its corresponding word vector in each sub-time period within a preset time period, obtaining sample points of each sub-time period based on the similarity between word vectors corresponding to different financial transaction data in each sub-time period, clustering the sample points of each sub-time period respectively, and obtaining the association value of the financial transaction data of each cluster cluster according to the clustering result; determining the optimal upload time interval according to the association value of the financial transaction data of all cluster clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period, and then uploading the financial transaction data to the blockchain for storage. The present invention can adaptively determine the optimal upload time interval for uploading financial transaction data to the blockchain.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of financial transaction data management, and in particular to a method for intelligently protecting financial transaction data based on blockchain. Background Art

[0002] With the development of informatization, the financial industry has begun to pay attention to the use and protection of financial transaction data. Since financial transaction data covers important indicators such as market data, industry indexes and corporate data, its security has also become a focus of attention. At the same time, blockchain technology, which is decentralized, reliable, secure, open and transparent, has been widely used in finance, medical care, logistics and other fields. Under the market supervision system, the use of blockchain technology can help financial institutions solve the problem of financial transaction data security, help them achieve business innovation, and improve the quality of financial information services.

[0003] In actual financial transactions, banks and users use short-interval scheduled tasks to desensitize the user's deposit and withdrawal business flow data and send it to the blockchain. The financial transaction data stored on the blockchain is encrypted, and the transaction confirmation time of the blockchain system will affect the realization of real-time chain-up. The transaction confirmation time of some public blockchain networks may be longer, which is not suitable for real-time transactions that require immediate confirmation, while some private chains or alliance chains may have faster transaction confirmation speeds. Therefore, different financial transaction businesses may have different requirements for real-time performance. Some high-frequency transactions may require real-time chain-up, while some ordinary fund transfers can often be processed with a slight delay. Therefore, how to adaptively set the upload time interval of financial transaction data according to the characteristics of financial transaction data is a problem that needs to be solved. Summary of the invention

[0004] In order to solve the problem that the existing method cannot adaptively set the upload time interval of financial transaction data according to the characteristics of financial transaction data, the purpose of the present invention is to provide a blockchain-based financial transaction data intelligent protection method, and the technical solution adopted is as follows:

[0005] The present invention provides a method for intelligently protecting financial transaction data based on blockchain, the method comprising the following steps:

[0006] Obtain each piece of financial transaction data and its corresponding word vector in each sub-time period within a preset time period, wherein each piece of financial transaction data includes transaction data of a preset number of dimensions;

[0007] Based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, sample points of each sub-time period are obtained, and the sample points of each sub-time period are clustered to obtain clusters; according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which it is located, and the time when the user corresponding to each sample point submits the query demand to the node server on the blockchain, the association value of the financial transaction data of each cluster is obtained;

[0008] According to the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period, the necessary indicators for data transmission in each sub-time period are obtained; the optimal upload time interval is determined using the necessary indicators for data transmission in all sub-time periods in the preset time period;

[0009] The financial transaction data is uploaded to the blockchain for storage based on the optimal upload time interval.

[0010] Preferably, obtaining the sample points of each sub-time period based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period includes:

[0011] Calculate the similarity between the word vectors corresponding to each two financial transaction data in each sub-time period;

[0012] The average of the similarities between the word vector corresponding to each piece of financial transaction data in each sub-time period and the word vector corresponding to all other financial transaction data is used as the similarity feature value of each piece of financial transaction data in each sub-time period;

[0013] A coordinate system is constructed with the upload time of the financial transaction data as the horizontal axis and the similar feature value of the financial transaction data as the vertical axis to obtain the sample points of each sub-time period.

[0014] Preferably, the method of obtaining the association value of the financial transaction data of each cluster according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which the sample point is located, and the time when the user corresponding to each sample point submits the query demand to the node server on the blockchain includes:

[0015] For the user corresponding to any sample point: if the number of times the user submits query requirements to the node server on the blockchain is greater than or equal to two times, then the time interval between each two consecutive query requirements submitted by the user is obtained, and the average time interval between each two consecutive query requirements submitted by the user is taken as the demand interval value of the user; if the number of times the user submits query requirements to the node server on the blockchain is less than two times, then the user who submits query requirements to the node server on the blockchain greater than or equal to two times is recorded as a reference user, and the maximum value of the demand interval values ​​of all reference users is taken as the demand interval value of the user;

[0016] According to the similarity between the word vectors corresponding to each sample point and the financial transaction data corresponding to other sample points in its sub-time period, and the demand interval value of each sample point and the user corresponding to other sample points in its sub-time period, the transaction data difference index of each sample point is obtained;

[0017] According to the transaction data difference index of each sample point in each cluster and the number of sample points in each cluster, the association value of the financial transaction data of each cluster is obtained.

[0018] Preferably, the transaction data difference index of each sample point is obtained according to the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point and other sample points in the sub-time period where the sample point is located, and the demand interval value of the user corresponding to each sample point and other sample points in the sub-time period where the sample point is located, including:

[0019] For the i-th sample point:

[0020] According to the similarity between the word vectors corresponding to the financial transaction data corresponding to the i-th sample point and each other sample point in the sub-time period where it is located, and the difference between the demand interval values ​​of the users corresponding to the i-th sample point and each other sample point in the sub-time period where it is located, the transaction data difference index of the i-th sample point is obtained; the similarity is negatively correlated with the transaction data difference index, and the difference between the demand interval values ​​is positively correlated with the transaction data difference index.

[0021] Preferably, obtaining the association value of the financial transaction data of each cluster according to the transaction data difference index of each sample point in each cluster and the number of sample points in each cluster includes:

[0022] Calculate the difference between the transaction data difference index of each sample point in each cluster and the average value of the transaction data difference index of all sample points in the cluster to which it belongs, as the first index of each sample point in each cluster;

[0023] According to the first index of all sample points in each cluster and the number of sample points in each cluster, the association value of the financial transaction data of each cluster is obtained, and the first index and the number of sample points are both positively correlated with the association value.

[0024] Preferably, obtaining the necessary indicators for data transmission in each sub-time period according to the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period includes:

[0025] For the kth sub-period:

[0026] A coordinate system is constructed based on the transaction data of each two dimensions in the kth sub-time period to obtain data points corresponding to each two dimensions; a convex hull detection is performed on the data points corresponding to each two dimensions to obtain the area of ​​the convex hull corresponding to each two dimensions;

[0027] According to the area of ​​the convex hull corresponding to every two dimensions of the k-th sub-time period and the correlation value of the financial transaction data of each cluster of the k-th sub-time period, the necessary index of data transmission of the k-th sub-time period is obtained.

[0028] Preferably, the necessary index for data transmission in the kth sub-time period is calculated using the following formula:

[0029]

[0030] Among them, B k represents the necessary index for data transmission in the kth sub-time period, G r ′ represents the correlation value of the financial transaction data of the rth cluster in the kth sub-time period, R represents the number of clusters in the kth sub-time period, T represents the number of convex hulls corresponding to the kth sub-time period, and s t represents the area of ​​the t-th convex hull corresponding to the k-th sub-time period, represents the average of the areas of all convex hulls corresponding to the kth sub-time period, exp() represents an exponential function with a natural constant as the base, || represents the absolute value sign, λ2 is the preset second adjustment parameter, and λ2 is greater than 0.

[0031] Preferably, the method of determining the optimal upload time interval by using the necessary indicators for data transmission in all sub-time periods within a preset time period includes:

[0032] For any sub-time period: the product of the length of the sub-time period and the necessary index for data transmission in the sub-time period is recorded as the first product corresponding to the sub-time period;

[0033] The result of rounding up the accumulated sum of the first products corresponding to all sub-time periods is taken as the optimal upload time interval.

[0034] Preferably, a density clustering algorithm is used to cluster all sample points in each sub-time period.

[0035] Preferably, obtaining the word vector corresponding to each piece of financial transaction data includes:

[0036] The Word2Vec algorithm is used to convert each piece of financial transaction data into an initial word vector. All the initial word vectors corresponding to each piece of financial transaction data are concatenated and padded with 0 to obtain the word vector corresponding to each piece of financial transaction data.

[0037] The present invention has at least the following beneficial effects:

[0038] The present invention first analyzes the financial transaction data within the preset time period separately, obtains multiple sample points of each sub-time period based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, one piece of financial transaction data corresponds to one sample point, and performs clustering processing on the sample points of each sub-time period, evaluates the relevance of the financial transaction data of each cluster cluster in combination with the clustering result, and realizes the adjustment of the time interval of uploading the financial transaction data according to the relevance of the financial transaction data, that is, adaptively determines the optimal uploading time interval, so as to use blockchain technology to help financial institutions solve the security problem of financial transaction data, help them realize business innovation, and improve the quality of financial information services. Compared with the traditional fixed time interval financial transaction data uploading operation, it can better guarantee the real-time reconciliation needs of financial users, and the dynamic adjustment of the storage time of financial transaction data of different users by financial institutions, so as to realize the uploading operation as early as possible, and realize the intelligent protection of financial transaction data by blockchain. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0040] Figure 1 A flowchart of a blockchain-based financial transaction data intelligent protection method provided by an embodiment of the present invention;

[0041] Figure 2 The flowchart of the method for obtaining the associated value. DETAILED DESCRIPTION

[0042] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined purpose of the invention, the blockchain-based intelligent protection method for financial transaction data proposed by the present invention is described in detail below in combination with the accompanying drawings and preferred embodiments.

[0043] Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.

[0044] The specific scheme of the intelligent protection method for financial transaction data based on blockchain provided by the present invention is described in detail below with reference to the accompanying drawings.

[0045] An embodiment of a method for intelligently protecting financial transaction data based on blockchain:

[0046] The specific scenario targeted by this embodiment is: users will generate certain financial transaction data in the process of conducting financial transactions. As time goes by, the number of users is increasing, and the number of transactions by users is increasing. In order to facilitate the subsequent retrieval of financial transaction data in historical transaction processes, the financial transaction data generated in historical financial transaction processes is generally stored and protected. When storing financial transaction data, it is stored on the blockchain for subsequent retrieval. Different financial transaction businesses may have different requirements for real-time performance. Therefore, this embodiment will adaptively determine the optimal upload time interval based on the characteristics of the financial transaction data, and then upload the financial transaction data to the blockchain.

[0047] This embodiment proposes a blockchain-based intelligent protection method for financial transaction data. Figure 1 As shown, the blockchain-based financial transaction data intelligent protection method of this embodiment includes the following steps:

[0048] Step S1, obtaining each piece of financial transaction data and its corresponding word vector in each sub-time period within a preset time period, wherein each piece of financial transaction data includes transaction data of a preset number of dimensions.

[0049] Each time a user conducts a financial transaction, at least one piece of financial transaction data is generated. In this embodiment, all financial transaction data within a preset time period is first obtained from the financial database. The metal transaction data in this embodiment includes the time of fund change, the amount of fund change, the business type, the user name, the fund account number, the bank account number, and the electronic signature data, wherein each type of data is a one-dimensional transaction data, i.e., the time of fund change is a one-dimensional transaction data, the amount of fund change is a one-dimensional transaction data, the business type is a one-dimensional transaction data, the user name is a one-dimensional transaction data, the fund account number is a one-dimensional transaction data, the bank account number is a one-dimensional transaction data, and the electronic signature data is a one-dimensional transaction data. The preset number in this embodiment is 7. In specific applications, the implementer can set it according to specific circumstances. The preset time period in this embodiment is a set of all historical moments whose time interval with the current moment is a preset time length. In this embodiment, the preset time length is three months. Therefore, this embodiment obtains all financial transaction data in the past three months from the financial database. In specific applications, the implementer can set the preset time length according to specific circumstances. The preset time period is divided into multiple sub-time periods of equal length. The present embodiment will subsequently analyze the financial transaction data in each sub-time period respectively. In the present embodiment, the duration of each sub-time period is one week. In specific applications, the implementer can set it according to the specific situation.

[0050] This embodiment obtains the financial transaction data in each sub-time period within a preset time period, performs data desensitization processing on the obtained financial transaction data, and obtains the processed data. Data desensitization processing is a prior art and will not be described in detail here. It should be noted that the financial transaction data mentioned later are all desensitized data. The Word2Vec algorithm is used to convert each financial transaction data into a word vector, and the word vector obtained at this time is recorded as the initial word vector. All the initial word vectors corresponding to each financial transaction data are spliced, and the vacant positions are filled with 0. The word vector after splicing and 0 filling at this time is used as the word vector corresponding to each financial transaction data. Each financial transaction data corresponds to a word vector, and the length of the word vector corresponding to each financial transaction data is equal. The Word2Vec algorithm is a prior art and will not be described in detail here.

[0051] So far, this embodiment has obtained each piece of financial transaction data and its corresponding word vector in each sub-time period within the preset time period.

[0052] Step S2, based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, the sample points of each sub-time period are obtained, and the sample points of each sub-time period are clustered to obtain cluster clusters; according to the number of sample points in each cluster cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster cluster and other sample points in the time period where the sample point is located, and the time when the user corresponding to each sample point submits the query request to the node server on the blockchain, the association value of the financial transaction data of each cluster cluster is obtained.

[0053] In the actual process of uploading financial transaction data to the chain, since the financial transaction behavior of users in the sub-time period is unknown, that is, the transaction frequency and transaction volume of the corresponding financial transaction data vary, the financial transaction data in each sub-time period will tend to be more randomly distributed as a whole. In a longer time span, since the user groups of financial institutions such as banks are relatively constant, the financial transaction data over a longer time span will tend to be more stably distributed as a whole. Therefore, it is necessary to determine the optimal upload interval under the premise of considering the correlation feature analysis before and after the financial transaction data in the local time series stage, so as to maximize the transmission and storage security and storage efficiency of the financial transaction data.

[0054] Step S21, based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, sample points of each sub-time period are obtained, and the sample points of each sub-time period are clustered to obtain clusters.

[0055] The similarity between the word vectors corresponding to each two financial transaction data in each sub-time period is calculated respectively; in this embodiment, cosine similarity is used to characterize the similarity between word vectors, that is, the cosine similarity between the word vectors corresponding to each two financial transaction data in each sub-time period is calculated respectively, as the similarity between the word vectors corresponding to each two financial transaction data. As another implementation method, the negative correlation mapping result of the dynamic time warping (DTW) distance can also be used to characterize the similarity between word vectors, which will not be described in detail.

[0056] The average value of the similarity between the word vector corresponding to each financial transaction data in each sub-time period and the word vector corresponding to all other financial transaction data is used as the similarity feature value of each financial transaction data in each sub-time period; the upload time of the financial transaction data is used as the horizontal coordinate, and the similarity feature value of the financial transaction data is used as the vertical coordinate to construct a rectangular coordinate system to obtain multiple sample points in each sub-time period. The density clustering algorithm is used to cluster all sample points in each sub-time period to obtain multiple cluster clusters in each sub-time period. The density clustering algorithm is a prior art and will not be described in detail here.

[0057] Step S22, according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which it is located, and the time when the user corresponding to each sample point submits the query request to the node server on the blockchain, the association value of the financial transaction data of each cluster is obtained.

[0058] Since users' financial transaction data is uploaded to the chain by banks and other financial institutions, it is a centralized chain-up process of multi-user financial transaction data within a certain time interval. However, different financial users have different real-time reconciliation needs and different requirements for data security protection. Therefore, analysis should be conducted based on the correlation performance of financial transaction data of different users.

[0059] The sample points in the same cluster can be considered as similar financial transaction data sample points with the same change trend. However, when dividing the clusters, the division is based on the distribution position of the sample points. Under the analysis of the actual change trend of financial transaction data, the differences in the financial data contained in the sample points in the clusters are different in different clusters, and the differences between multiple clusters are different overall. This embodiment will evaluate the correlation of the financial transaction data corresponding to the sample points in each cluster according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which it is located, and the time when the user corresponding to each sample point submits the query request to the node server on the blockchain.

[0060] Specifically, for the i-th sample point:

[0061] According to the similarity between the word vectors corresponding to the financial transaction data corresponding to the i-th sample point and each other sample point in the sub-time period in which it is located, and the difference between the demand interval values ​​of the users corresponding to the i-th sample point and each other sample point in the sub-time period in which it is located, the transaction data difference index of the i-th sample point is obtained; the similarity is negatively correlated with the transaction data difference index, and the difference between the demand interval values ​​is positively correlated with the transaction data difference index. Among them, the positive correlation relationship means that the dependent variable will increase as the independent variable increases, and the dependent variable will decrease as the independent variable decreases. The specific relationship can be a multiplication relationship, an addition relationship, and the idempotence of an exponential function, which is determined by actual application; the negative correlation relationship means that the dependent variable will decrease as the independent variable increases, and the dependent variable will increase as the independent variable decreases. It can be a subtraction relationship, a division relationship, etc., which is determined by actual application. As a specific implementation method, a specific calculation formula for the transaction data difference index is given. The specific calculation formula for the transaction data difference index of the i-th sample point is:

[0062]

[0063] in, represents the transaction data difference index of the i-th sample point, J represents the number of sample points in the sub-time period where the i-th sample point is located, and ρ i represents the word vector corresponding to the financial transaction data corresponding to the i-th sample point, ρ i,j represents the word vector corresponding to the financial transaction data corresponding to the jth sample point except the i-th sample point in the sub-time period where the i-th sample point is located, cos() represents the cosine similarity function, τ i represents the user demand interval value corresponding to the i-th sample point, τ i,j represents the user demand interval value corresponding to the jth sample point excluding the i-th sample point in the sub-time period where the i-th sample point is located, || represents the absolute value sign, λ1 is the preset first adjustment parameter, and λ1 is greater than 0.

[0064] The first adjustment parameter is introduced into the calculation formula of the transaction data difference index in this embodiment to prevent the denominator from being 0. In this embodiment, the first adjustment parameter is preset to 0.01. In specific applications, the implementer can set it according to specific circumstances. i -τ i,j | is used to reflect the difference between the user demand interval values ​​corresponding to the i-th sample point and the j-th sample point in the sub-time period except the i-th sample point. The larger the value, the greater the difference between the two. cos(ρ i ,ρ i,j ) represents the cosine similarity between the word vector corresponding to the financial transaction data corresponding to the ith sample point and the word vector corresponding to the financial transaction data corresponding to the jth sample point except the ith sample point in the sub-time period where the ith sample point is located, which is used to reflect the similarity between the two word vectors. The larger the value, the higher the similarity between the two word vectors. The smaller the similarity between the word vectors corresponding to the financial transaction data corresponding to the ith sample point and each other sample point in the sub-time period where it is located, and the larger the difference between the demand interval values ​​of the users corresponding to the ith sample point and each other sample point in the sub-time period where it is located, the larger the transaction data difference index of the ith sample point.

[0065] By adopting the above method, the transaction data difference index of each sample point can be obtained. Next, the difference between the transaction data difference index of each sample point in each cluster and the average value of the transaction data difference index of all sample points in the cluster where it is located is calculated as the first index of each sample point in each cluster. According to the first index of all sample points in each cluster and the number of sample points in each cluster, the correlation value of the financial transaction data of each cluster is obtained, and the first index and the number of sample points are both positively correlated with the correlation value. Among them, the positive correlation relationship means that the dependent variable will increase as the independent variable increases, and the dependent variable will decrease as the independent variable decreases. The specific relationship can be a multiplication relationship, an addition relationship, and the idempotence of an exponential function, which is determined by actual application; as a specific implementation method, a calculation formula for the correlation value is given, and the specific calculation formula for the correlation value of the financial transaction data of the ath cluster is:

[0066]

[0067] Among them, G a represents the correlation value of the financial transaction data of the a-th cluster, N a represents the number of sample points in the ath cluster, Represents the transaction data difference index of the bth sample point in the ath cluster. It represents the average value of the transaction data difference index of all sample points in the a-th cluster, exp() represents the exponential function with a natural constant as the base, norm() represents the normalization function, and || represents the absolute value symbol.

[0068] The first index of the bth sample point in the ath cluster is used to reflect the difference between the transaction data difference index of the bth sample point in the ath cluster and the average value of the transaction data difference index of all sample points in the ath cluster. The larger the value, the greater the difference between the two. When the difference between the transaction data difference index of each sample point in the ath cluster and the average value of the transaction data difference index of all sample points in the cluster where it is located is greater, and the more sample points there are in the ath cluster, the stronger the correlation of the financial transaction data corresponding to the sample points in the ath cluster, that is, the greater the correlation value of the financial transaction data of the ath cluster.

[0069] Using the above method, the correlation value of the financial transaction data of each cluster can be obtained, such as Figure 2 As shown, the figure is a flow chart of the method for obtaining the associated value.

[0070] Step S3, obtaining the necessary indicators for data transmission in each sub-time period according to the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period; and determining the optimal upload time interval using the necessary indicators for data transmission of all sub-time periods in the preset time period.

[0071] The correlation value reflects the possibility of the time length corresponding to the cluster as the time interval for uploading new financial transaction data to the chain, but the impact of the time interval is often greatly affected by the difference in the local time series interval of the financial transaction data generated by the user in real time. Therefore, it is necessary to further analyze the differences between the financial transaction data in the cluster to determine the optimal upload time interval to improve storage efficiency and security. Therefore, this embodiment analyzes the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period, and determines the necessary indicators for data transmission in each sub-time period.

[0072] Specifically, for the kth sub-time period:

[0073] Construct a coordinate system based on the transaction data of every two dimensions in the kth sub-time period to obtain the data points corresponding to every two dimensions; perform convex hull detection on the data points corresponding to every two dimensions to obtain the area of ​​the convex hull corresponding to every two dimensions, and each arbitrary two dimensions corresponds to the area of ​​a convex hull. Convex hull detection is a prior art and will not be described in detail here. According to the area of ​​the convex hull corresponding to every two dimensions of the kth sub-time period and the correlation value of the financial transaction data of each cluster of the kth sub-time period, the necessary indicators for data transmission in the kth sub-time period are obtained. The specific calculation formula for the necessary indicators for data transmission in the kth sub-time period is:

[0074]

[0075] Among them, B k represents the necessary index for data transmission in the kth sub-time period, G r ′ represents the correlation value of the financial transaction data of the rth cluster in the kth sub-time period, R represents the number of clusters in the kth sub-time period, T represents the number of convex hulls corresponding to the kth sub-time period, and s t represents the area of ​​the t-th convex hull corresponding to the k-th sub-time period, represents the average of the areas of all convex hulls corresponding to the kth sub-time period, exp() represents an exponential function with a natural constant as the base, || represents the absolute value sign, λ2 is the preset second adjustment parameter, and λ2 is greater than 0.

[0076] The purpose of introducing the preset second adjustment parameter into the calculation formula of the necessary index for data transmission is to prevent the denominator from being 0. In this embodiment, the preset second adjustment parameter is 0.01. In specific applications, the implementer can set it according to the specific situation. represents the average value of the correlation value of the financial transaction data of the cluster in the kth sub-time period, It is used to reflect the difference between the area of ​​the tth convex hull corresponding to the kth sub-time period and the average area of ​​all convex hulls corresponding to the kth sub-time period. The larger the value, the greater the difference between the two. When the average value of the correlation value of the financial transaction data of the clusters of the kth sub-time period is smaller and the difference between the area of ​​each convex hull corresponding to the kth sub-time period and the average area of ​​all convex hulls is larger, the data transmission necessary index of the kth sub-time period is larger.

[0077] By adopting the above method, the necessary indicators for data transmission in each sub-time period can be obtained, which represents the confidence level of using this interval length as the time interval for financial institutions to periodically upload financial transaction data. Next, the optimal upload time interval is determined based on the necessary indicators for data transmission in all sub-time periods within the preset time period.

[0078] Specifically, for any sub-time period: the product of the length of the sub-time period and the necessary index for data transmission of the sub-time period is recorded as the first product corresponding to the sub-time period. By adopting this method, the MC product corresponding to each sub-time period can be obtained, and each sub-time period corresponds to a first product. The cumulative sum of the first products corresponding to all sub-time periods is rounded up as the optimal upload time interval. The optimal upload time interval can be expressed as:

[0079]

[0080] Where L represents the optimal upload time interval, K represents the number of sub-time periods within the preset time period, and B k represents the necessary index for data transmission in the kth sub-time period, l k represents the duration of the kth sub-time period, Indicates the round-up symbol.

[0081] So far, this embodiment has adaptively determined the optimal upload time interval according to the characteristics of the financial transaction data in the preset time period. It should be noted that: in this embodiment, the unit of the duration of the sub-time period is minutes, and the unit of the optimal upload time interval is also minutes. In specific applications, the implementer can set it according to the specific situation.

[0082] Step S4: uploading the financial transaction data to the blockchain for storage based on the optimal upload time interval.

[0083] This embodiment analyzes the accurate clustering results obtained, and the optimal upload time interval obtained is an analysis of the data chain time interval based on historical financial transaction data and combined with real-time financial transaction conditions to meet the corresponding needs such as reconciliation of real-time user financial transaction data. After the optimal upload time is adaptively determined, the corresponding blockchain data processing operation will be adopted next. For example, based on the real-time transaction data generation rate, the total amount of data that needs to be uploaded to the chain is estimated, and encryption and data desensitization are performed to achieve temporary storage to ensure the security of temporary data storage. After the optimal upload time interval is reached, it is transmitted to the blockchain, thereby realizing intelligent protection of financial transaction data and facilitating subsequent retrieval of financial transaction data.

[0084] At this point, the method provided in this embodiment has been used to complete the intelligent protection of financial transaction data.

[0085] This embodiment first analyzes the financial transaction data within the preset time period separately, obtains multiple sample points for each sub-time period based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, and one sample point corresponds to one amount transaction data, and clusters the sample points of each sub-time period, and evaluates the relevance of the financial transaction data of each cluster cluster in combination with the clustering results, and adjusts the time interval for uploading the financial transaction data according to the relevance of the financial transaction data, that is, adaptively determines the optimal upload time interval, so as to use blockchain technology to help financial institutions solve the security problems of financial transaction data, help them realize business innovation, and improve the quality of financial information services. Compared with the traditional fixed time interval financial transaction data uploading operation, it can better guarantee the real-time reconciliation needs of financial users, as well as the dynamic adjustment of the storage time of financial transaction data of different users by financial institutions, so as to realize the uploading operation as early as possible and realize the intelligent protection of financial transaction data by blockchain.

[0086] It should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the principles of the present invention should be included in the protection scope of the present invention.

Claims

1. A blockchain-based intelligent protection method for financial transaction data, characterized in that: The method comprises the following steps: Obtain each piece of financial transaction data and its corresponding word vector in each sub-time period within a preset time period, wherein each piece of financial transaction data includes transaction data of a preset number of dimensions; Based on the similarity between the word vectors corresponding to different financial transaction data in each sub-time period, sample points of each sub-time period are obtained, and the sample points of each sub-time period are clustered to obtain clusters; according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which it is located, and the time when the user corresponding to each sample point submits the query demand to the node server on the blockchain, the association value of the financial transaction data of each cluster is obtained; According to the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period, the necessary indicators for data transmission in each sub-time period are obtained; the optimal upload time interval is determined using the necessary indicators for data transmission in all sub-time periods in the preset time period; Uploading the financial transaction data to the blockchain for storage based on the optimal upload time interval; The necessary indicators for data transmission in each sub-time period are obtained according to the correlation values ​​of the financial transaction data of all clusters in each sub-time period and the distribution of the data values ​​of the transaction data of each two dimensions in each sub-time period, including: For the kth sub-period: A coordinate system is constructed based on the transaction data of each two dimensions in the kth sub-time period to obtain data points corresponding to each two dimensions; a convex hull detection is performed on the data points corresponding to each two dimensions to obtain the area of ​​the convex hull corresponding to each two dimensions; According to the area of ​​the convex hull corresponding to each two dimensions of the k-th sub-time period and the correlation value of the financial transaction data of each cluster of the k-th sub-time period, the necessary indicators for data transmission of the k-th sub-time period are obtained; The necessary data transmission index for the kth sub-time period is calculated using the following formula: Among them, B k represents the necessary index for data transmission in the kth sub-time period, G r ′ represents the correlation value of the financial transaction data of the rth cluster in the kth sub-time period, R represents the number of clusters in the kth sub-time period, T represents the number of convex hulls corresponding to the kth sub-time period, and s t represents the area of ​​the t-th convex hull corresponding to the k-th sub-time period, represents the average of the areas of all convex hulls corresponding to the kth sub-time period, exp() represents an exponential function with a natural constant as the base, || represents the absolute value sign, λ2 is the preset second adjustment parameter, and λ2 is greater than 0; Determining the optimal upload time interval by using the necessary indicators for data transmission in all sub-time periods within the preset time period includes: For any sub-time period: the product of the length of the sub-time period and the necessary index for data transmission in the sub-time period is recorded as the first product corresponding to the sub-time period; The result of rounding up the accumulated sum of the first products corresponding to all sub-time periods is taken as the optimal upload time interval.

2. The blockchain-based financial transaction data intelligent protection method according to claim 1 is characterized in that: The obtaining of sample points in each sub-time period based on similarities between word vectors corresponding to different financial transaction data in each sub-time period includes: Calculate the similarity between the word vectors corresponding to each two financial transaction data in each sub-time period; The average of the similarities between the word vector corresponding to each piece of financial transaction data in each sub-time period and the word vector corresponding to all other financial transaction data is used as the similarity feature value of each piece of financial transaction data in each sub-time period; A coordinate system is constructed with the upload time of the financial transaction data as the horizontal axis and the similar feature value of the financial transaction data as the vertical axis to obtain the sample points of each sub-time period.

3. The blockchain-based financial transaction data intelligent protection method according to claim 2 is characterized in that: The method obtains the association value of the financial transaction data of each cluster according to the number of sample points in each cluster, the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point in each cluster and other sample points in the time period in which the sample point is located, and the time when the user corresponding to each sample point submits the query request to the node server on the blockchain, including: For the user corresponding to any sample point: if the number of times the user submits query requirements to the node server on the blockchain is greater than or equal to two times, then the time interval between each two consecutive query requirements submitted by the user is obtained, and the average time interval between each two consecutive query requirements submitted by the user is taken as the demand interval value of the user; if the number of times the user submits query requirements to the node server on the blockchain is less than two times, then the user who submits query requirements to the node server on the blockchain greater than or equal to two times is recorded as a reference user, and the maximum value of the demand interval values ​​of all reference users is taken as the demand interval value of the user; According to the similarity between the word vectors corresponding to each sample point and the financial transaction data corresponding to other sample points in its sub-time period, and the demand interval value of each sample point and the user corresponding to other sample points in its sub-time period, the transaction data difference index of each sample point is obtained; According to the transaction data difference index of each sample point in each cluster and the number of sample points in each cluster, the association value of the financial transaction data of each cluster is obtained.

4. The method for intelligently protecting financial transaction data based on blockchain according to claim 3 is characterized in that: The transaction data difference index of each sample point is obtained according to the similarity between the word vectors corresponding to the financial transaction data corresponding to each sample point and other sample points in the sub-time period where the sample point is located, and the demand interval value of the user corresponding to each sample point and other sample points in the sub-time period where the sample point is located, including: For the i-th sample point: According to the similarity between the word vectors corresponding to the financial transaction data corresponding to the i-th sample point and each other sample point in the sub-time period where it is located, and the difference between the demand interval values ​​of the users corresponding to the i-th sample point and each other sample point in the sub-time period where it is located, the transaction data difference index of the i-th sample point is obtained; the similarity is negatively correlated with the transaction data difference index, and the difference between the demand interval values ​​is positively correlated with the transaction data difference index.

5. The method for intelligently protecting financial transaction data based on blockchain according to claim 3 is characterized in that: The method of obtaining the association value of the financial transaction data of each cluster according to the transaction data difference index of each sample point in each cluster and the number of sample points in each cluster includes: Calculate the difference between the transaction data difference index of each sample point in each cluster and the average value of the transaction data difference index of all sample points in the cluster to which it belongs, as the first index of each sample point in each cluster; According to the first index of all sample points in each cluster and the number of sample points in each cluster, the association value of the financial transaction data of each cluster is obtained, and the first index and the number of sample points are both positively correlated with the association value.

6. The blockchain-based financial transaction data intelligent protection method according to claim 1 is characterized in that: The density clustering algorithm is used to cluster all sample points in each sub-time period.

7. The blockchain-based financial transaction data intelligent protection method according to claim 1 is characterized in that: The word vector corresponding to each financial transaction data is obtained, including: The Word2Vec algorithm is used to convert each piece of financial transaction data into an initial word vector. All the initial word vectors corresponding to each piece of financial transaction data are concatenated and padded with 0 to obtain the word vector corresponding to each piece of financial transaction data.

Citation Information

Patent Citations

  • Federal learning-based energy big data security protection method

    CN117763621A

  • Financial user data security protection method based on block chain

    CN117788174A