A blockchain-based clinical data statistical management and analysis method

By employing blockchain-based technologies such as hierarchical storage, homomorphic encryption, and adaptive consensus, the security, efficiency, and data sharing issues of clinical data management systems have been addressed, enabling efficient and secure data management and analysis.

CN119249473BActive Publication Date: 2026-02-17BEIJING KANGTERIKE STATISTICAL TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411208246.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-30
Publication Date
2026-02-17
Estimated Expiration
2044-08-30

AI Technical Summary

Technical Problem

Existing clinical data management systems suffer from data leakage risks, efficiency bottlenecks, difficulties in data sharing between heterogeneous systems, and data semantic inconsistencies, making it impossible to maintain efficient operation and scalability under high load conditions.

Method used

It employs blockchain-based layered storage algorithms, homomorphic encryption, federated learning, adaptive consensus mechanisms, cross-chain interoperability protocols, and semantic analysis to achieve data classification, encryption, secure access, dynamic adjustment of consensus algorithms, data standardization, and distributed computing.

Benefits of technology

It improves data security and privacy, enhances the system's efficiency and scalability in processing massive amounts of data, ensures semantic consistency and operational transparency of data across heterogeneous systems, reduces the complexity of data transformation, and improves user experience and system stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119249473B_ABST
    Figure CN119249473B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of blockchains, and discloses a clinical data statistical management and analysis method based on a blockchain, which comprises the following steps: S1, collecting clinical data through the sources of hospital, clinic and patient equipment, and classifying the data according to the sensitivity, frequent access and size of the data by using a hierarchical storage algorithm; S2, applying a sharding technology, dividing the blockchain into different data segments for processing, and using a homomorphic encryption algorithm to encrypt the data; S3, the patient can set the range of access to the data and the access permission and the time length of access through a smart contract. Through the combination of the hierarchical storage algorithm, the homomorphic encryption technology and the revocable anonymous technology, the sensitive clinical data can be effectively protected, the safety and privacy of the data in the transmission and storage process are ensured, meanwhile, the patient can finely control the access permission of the data through the smart contract, part of the data can be safely disclosed, and the privacy protection of the data is further improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of blockchains, in particular to a clinical data statistical management and analysis method based on a blockchain. BACKGROUND

[0002] In the modern medical field, the management and analysis of clinical data play an extremely important role in medical decision-making, scientific research progress and patient treatment. With the popularity of digital medical systems, the quantity and complexity of clinical data have increased, and how to effectively manage, share and analyze data has become a challenge for medical informatization. However, the existing clinical data management and analysis systems have the following problems:

[0003] Traditional clinical data management systems mostly use centralized storage methods, which makes the system vulnerable to network attacks and risks of data leakage. In addition, the existing systems use simple encryption measures in the data transmission and storage process, which cannot fully cope with complex security threats.

[0004] The exponential growth of medical data has made traditional centralized data processing systems show obvious efficiency bottlenecks in dealing with massive data. In addition, the traditional consensus mechanism cannot be flexibly adjusted under different network load conditions, resulting in a decline in system performance under high load conditions and inability to guarantee the efficient operation and scalability of the system in complex environments.

[0005] In the existing medical information system, there are multiple heterogeneous databases and data formats, and the data sharing and interoperability between different systems are prominent. There is a lack of unified data standards and effective cross-platform data exchange mechanisms. The data exchange between different systems often requires a complex conversion process, which is prone to problems of inconsistent data semantics.

[0006] Therefore, the present application provides a clinical data statistical management and analysis method based on a blockchain to solve the problems raised in the background. SUMMARY

[0007] In view of the deficiencies of the prior art, the present application provides a clinical data statistical management and analysis method based on a blockchain to solve the problems raised in the background.

[0008] To achieve the above purpose, the present application is implemented by the following technical solution: a clinical data statistical management and analysis method based on a blockchain, comprising the following steps: S1, collecting clinical data through the sources of hospitals, clinics and patient devices, and classifying the data according to their sensitivity, frequency of access and size using a hierarchical storage algorithm;

[0009] S2, applying a sharding technology to divide the blockchain into different data segments, and using a homomorphic encryption algorithm to encrypt the data;

[0010] S3, the patient can set the scope of access to his data and access rights and the duration of access through a smart contract, and introduce a revocable anonymity technology to allow partial data disclosure;

[0011] S4, use federated learning algorithm, let each medical institution train the model without sharing the original data, and use homomorphic encryption technology to encrypt the on-chain data for calculation;

[0012] S5, introduce an adaptive consensus mechanism, dynamically adjust the consensus algorithm according to the network state, and record and update the data changes in real time through a smart contract, and automatically generate an audit report;

[0013] S6, use advanced cross-chain interoperability protocol, standardize the data of each medical system through semantic analysis and ontology matching algorithm;

[0014] S7, develop a simple and easy-to-use user interface to hide complex encryption and data management operations, and use automatic optimization algorithms to dynamically adjust the blockchain configuration according to user needs and system load;

[0015] S8, use the distributed computing power of the blockchain network to statistically analyze the on-chain data and generate a clinical research report;

[0016] S9, use an automated deployment algorithm to simplify the system installation and maintenance process, and through continuous performance monitoring and adaptive maintenance algorithms, dynamically adjust the system parameters according to actual usage.

[0017] Preferably, in the S1 step, the hierarchical storage algorithm step:

[0018] a. Assuming that the clinical data set to be processed D = {d1, d2,..., d n}, where each data item d i has the following properties:

[0019] Sensitivity S(d i ): defined as the sensitivity level of the data;

[0020] Access frequency F(d i ): defined as the expected number of accesses or access frequency of the data;

[0021] Data size γ·|d i |: defined as the size of the data item;

[0022] b. Calculate the comprehensive score of each data item through a weighted scoring function, which is used to evaluate its storage location, and the algorithm formula of the weighted scoring function is:

[0023] P(d i ) = α·S(d i)+ β · F(d i )+ γ · |d i |,

[0024] where α, β, γ are predefined weight parameters;

[0025] c. Hierarchical decision rule:

[0026] According to the comprehensive score P(d i ), the data is classified and stored:

[0027] On-chain storage: if P(d i ) is higher than a certain threshold T high , the data is stored on the blockchain;

[0028] if P(d i ) ≥ T high , then stored i on-chain,

[0029] Off-chain storage: if P(d i ) is lower than a certain threshold T low , the data is stored in the distributed storage system off-chain;

[0030] if P(d i ) ≤ T low , then stored i off-chain,

[0031] Hybrid storage: if T low < P(d i ) < T high , a hybrid storage strategy is adopted, part of the data is stored on-chain and part of the data is stored off-chain;

[0032] if T low < P(d i ) < T high , then stored i using hybrid storage.

[0033] Preferably, in the S2 step, the formula of the sharding technology and the homomorphic encryption algorithm is as follows:

[0034] The data sharding algorithm:

[0035] Assume that a data set D is to be divided into multiple data segments D = {D1, D2,..., D m}, where each segment D i can be independently stored and processed;

[0036] The basic steps of data sharding:

[0037] Data partitioning: using a hash function H to map data items d to different shards D i Up;

[0038] H(d) mod m = i,

[0039] where H(d) is the hash value of data item d, m is the number of shards, and i represents the shard D i to which d is assigned.

[0040] Shard storage: storing different shards D i in different shards of the blockchain.

[0041] Preferably, the homomorphic encryption algorithm:

[0042] Homomorphic encryption allows direct computation under ciphertext without decryption, assuming the use of an encryption function E and a decryption function D, and an operator is supported by homomorphic encryption.

[0043] Basic properties of homomorphic encryption:

[0044] Encryption: encrypting each data shard D i .

[0045] C i = E(D i ),

[0046] where C i is the encrypted ciphertext.

[0047] Ciphertext computation: operating on encrypted data shards C i without decryption.

[0048]

[0049] where C i,j is the operated ciphertext, and D i + D j is the corresponding plaintext operation.

[0050] Decryption: decrypting the result when needed to obtain the computed plaintext.

[0051] D(C i,j ) = D(E(D i + D j )) = D i + D j .

[0052] Preferably, in the S4 step, the federated learning algorithm is a distributed machine learning method that allows multiple participants to jointly train a global model without sharing raw data, assuming there are n participants, each participant i has a local dataset D i and local model parameters W i ;

[0053] Basic steps of federated learning:

[0054] Local model update: each participant trains the model on the local dataset and updates the local model parameters:

[0055]

[0056] where η is the learning rate, L i is the loss function, is the gradient of the loss function;

[0057] Global model aggregation: the federated learning server collects the local model parameters of the participants and aggregates them into a global model w (t +1) :

[0058]

[0059] where n is the number of participants;

[0060] The server distributes the updated global model parameters w (t+1) to each participant, and enters the next round of training;

[0061] The homomorphic encryption allows computation on encrypted data without decryption, assuming that E(.) is an encryption function, D(.) is a decryption function, and supports additive homomorphism;

[0062] Basic properties of homomorphic encryption:

[0063] Encryption: encrypt the local model parameters W i :

[0064] C i = E(w i ),

[0065] where C i is the encrypted model parameters.

[0066] Encrypted model aggregation: aggregate the encrypted model parameters without decryption:

[0067]

[0068] Preferably, in the S5 step, the adaptive consensus mechanism aims to dynamically adjust the consensus algorithm according to the network state to optimize system performance and security, and its adaptive consensus algorithm formula is:

[0069] Define the state variable S(t) representing the network state at time t, which includes factors such as:

[0070] N(t): the number of nodes participating in consensus;

[0071] T(t): the amount of transactions in the network;

[0072] L(t): the load of the network;

[0073] Define the optimization function Q(S(t)) according to the optimal consensus algorithm C(t) based on the state variable:

[0074]

[0075] where Q(S(t)) is a weighted sum function, and different consensus algorithms are weighted according to their contributions to system performance and security:

[0076] Q(S(t)) = α·f PoW (N(t), T(t), L(t)) + β·f Pos (N(t), T(t), L(t)) + γ·f DFT (N(t), T(t),

[0077] where α, β, γ are weight parameters adjusting the importance of each consensus algorithm, and f PoW , f PoS , f DFT represent the performance and security scores of each consensus algorithm.

[0078] Preferably, in the S6 step, the cross-chain interoperability protocol aims to achieve data exchange and intercommunication between different blockchains, and its basic steps for cross-chain operation are:

[0079] Data locking: Lock the hash value H(D) of data D on blockchain A as a voucher to ensure that the data is tamper-proof on chain A:

[0080] Lock A (D) = H(D),

[0081] Cross-chain verification: Verify the hash value H(D) of data D on blockchain B to ensure that the status of data on chain A is correctly recorded:

[0082] Verify B (H(D)) = True,

[0083] Data unlocking and transmission: Once the verification is passed, the data is unlocked and transmitted on blockchain B:

[0084] Unlock B (D) = D,

[0085] Cross-chain protocol formula: Assuming f A→B (D) represents the data transmission function from chain A to chain B, and its formula is as follows:

[0086]

[0087] Preferably, in the S6 step, the semantic analysis and ontology matching algorithm is used to standardize the data in different systems, and the algorithm formula is as follows:

[0088] Semantic mapping: define the mapping relationship M(O A , O B ) between ontologies, which maps the data concept C A of chain A to the data concept C B of chain B:

[0089] M(C A , O A → O B ) = C B ,

[0090] Matching degree calculation: measure the semantic similarity between concepts by calculating the matching degree function Sim(C A , C B ):

[0091]

[0092] Standardized data transmission: In the cross-chain data transmission process, the data concept C A of chain A is converted to the standardized data concept C B on chain B according to the mapping M:

[0093] D B = M(D A , O A → O B ).

[0094] Preferably, in the S8 step, the algorithm steps of distributed computing are as follows:

[0095] Local calculation: each node N i calculates the statistical quantity locally, assuming that the global mean μ is to be calculated, each node first calculates its local mean μ i :

[0096]

[0097] Global aggregation: nodes send their local mean μ i to the aggregation node, which computes the global mean μ:

[0098]

[0099] Global statistics computation: for more complex statistics, a two-stage computation can be used, first computing the local variance Post-aggregation into global variance σ 2 :

[0100]

[0101] Preferably, in the S8 step, the data statistical analysis formula can use a distributed linear regression model, and the algorithm steps are as follows:

[0102] Local gradient computation: each node N i computes the gradient g i on its local data:

[0103]

[0104] Where X i and y i are the local data on node N i :

[0105] Global gradient aggregation: nodes send their local gradient g i to the aggregation node, which aggregates into the global gradient g:

[0106]

[0107] Parameter update: update the regression coefficient β using the global gradient:

[0108] β (t+1) = β (t) - ηg,

[0109] Where η is the learning rate.

[0110] The application provides a clinical data statistical management and analysis method based on a blockchain. The application has the following beneficial effects:

[0111] 1. The application can effectively protect sensitive clinical data by combining a hierarchical storage algorithm, homomorphic encryption technology and revocable anonymity technology, ensure the security and privacy of the data during transmission and storage, and further improve the privacy protection of the data.

[0112] 2、The application utilizes the sharding technology and the adaptive consensus mechanism to significantly improve the efficiency and scalability of the system when processing massive data, wherein the adaptive consensus mechanism can dynamically adjust the consensus algorithm according to the network state, and ensure that the performance and security of the system under different load conditions are always in the best state.

[0113] 3、The application realizes data standardization and seamless exchange between different blockchain platforms through the cross-chain interoperability protocol and semantic analysis and ontology matching algorithm, ensures the semantic consistency of data in heterogeneous systems, reduces the complexity of data conversion, at the same time, the automatic audit mechanism records and updates data changes in real time through the smart contract, and automatically generates an audit report, ensures the transparency and traceability of data operation, and helps to meet various compliance requirements. BRIEF DESCRIPTION OF DRAWINGS

[0114] Figure 1 The flowchart of the application. DETAILED DESCRIPTION

[0115] In order to enable those skilled in the art to understand the application scheme, the technical solutions in the embodiments of the application will be described clearly and completely below in conjunction with the drawings of the embodiments of the application. Obviously, the described embodiments are part of the embodiments of the application, rather than all the embodiments. Based on the embodiments in the application, other embodiments obtained by those skilled in the art without creative labor should be within the scope of protection of the application.

[0116] The application will be described in detail below in conjunction with the drawings:

[0117] Embodiment:

[0118] Please refer to the accompanying Figure 1 The embodiment of the application provides a clinical data statistical management and analysis method based on a blockchain, comprising the following steps: S1, collecting clinical data through the sources of hospitals, clinics and patient devices, so as to classify the data according to the sensitivity, frequent access and size of the data by using a hierarchical storage algorithm;

[0119] S2, applying a sharding technology to divide the blockchain into different data segments, and using a homomorphic encryption algorithm to encrypt the data;

[0120] S3, the patient can set the range of access to his data and access authority and the duration of access through a smart contract, and introduce a revocable anonymity technology to allow partial data to be disclosed;

[0121] S4, using a federated learning algorithm to train the model without sharing the original data, and using a homomorphic encryption technology to encrypt and calculate the on-chain data;

[0122] S5, introduce an adaptive consensus mechanism, dynamically adjust the consensus algorithm according to the network state, and record and update the data changes in real time through the smart contract, automatically generate an audit report;

[0123] S6, use a high-level cross-chain interoperability protocol, standardize the data of each medical system through semantic analysis and ontology matching algorithms;

[0124] S7, develop a simple and easy-to-use user interface, hide complex encryption and data management operations, and use automatic optimization algorithms to dynamically adjust the blockchain configuration according to user needs and system load;

[0125] S8, use the distributed computing power of the blockchain network to statistically analyze the on-chain data and generate a clinical research report;

[0126] S9, use an automated deployment algorithm to simplify the system installation and maintenance process, and through continuous performance monitoring and adaptive maintenance algorithms, dynamically adjust the system parameters according to actual usage.

[0127] S1 benefits through a hierarchical storage algorithm, classifying data by sensitivity, access frequency, and size, effectively protecting sensitive data, reducing the risk of data leakage, prioritizing high-frequency access data, improving system response speed and user experience, reducing storage resource waste, and improving overall system storage efficiency; S2 benefits reduce the burden on a single node, improving system processing capacity and scalability; S3 benefits ensure that authorized parties can access specific data, strengthening data security management, balancing data privacy and the need for necessary information sharing; S4 benefits avoid data leakage risks while using homomorphic encryption to ensure data privacy during calculations, improving data utilization and analysis effectiveness; S5 benefits ensure data operation transparency and traceability, which helps with compliance management; S6 benefits ensure data standardization and seamless exchange between different blockchain platforms, reducing data conversion complexity and error rates, and enhancing data compatibility and cooperation capabilities between systems; S7 benefits reduce user operation complexity, improve user convenience and efficiency; S8 benefits improve data analysis efficiency, enabling efficient data statistical analysis and generating clinical research reports; S9 benefits reduce manual intervention, improve system management efficiency, and ensure long-term stability and efficient operation.

[0128] In S1, the hierarchical storage algorithm steps are:

[0129] a. Assume that the clinical data set to be processed D = {d1, d2,..., d n}, where each data item d i has the following properties:

[0130] Sensitivity S(d i ): defined as the sensitivity level of the data;

[0131] Access frequency F(d i ): defined as the expected number of accesses or access frequency of data;

[0132] Data size γ·|d i |: defined as the size of data item;

[0133] b. Calculate the comprehensive score for each data item by a weighted scoring function, which is used to evaluate its storage location, whose algorithm formula is:

[0134] P(d i ) = α·S(d i ) + β·F(d i ) + γ·|d i |,

[0135] where α, β, γ are predefined weight parameters;

[0136] c. Hierarchical decision rule:

[0137] According to the comprehensive score P(d i ), the data is classified and stored:

[0138] On-chain storage: if P(d i ) is higher than a certain threshold T high , the data is stored on the blockchain;

[0139] if P(d i ) ≥ T high , then stored i on-chain,

[0140] Off-chain storage: if P(d i ) is lower than a certain threshold T low , the data is stored in the distributed storage system off-chain;

[0141] if P(d i ) ≤ T low , then stored i off-chain,

[0142] Mixed storage: if T low < P(d i ) < T high , a mixed storage strategy is adopted, part of the data is stored on-chain and part of the data is stored off-chain;

[0143] i f T low < P(d i ) < T high, then stored i using hybrid storage.

[0144] By using the weighted scoring function, the system can calculate the comprehensive score according to the sensitivity, access frequency and data size of the data item, and quantify the storage requirement of each data item, and the setting of the weight parameter can be flexibly adjusted according to the specific application scene, so that the system can make adaptive storage decisions for different types of data;

[0145] The comprehensive score of the data item d i is between the low threshold and the high threshold, indicating that the data has certain security requirements and access efficiency, and the hybrid storage strategy makes the key part of the data stored on the blockchain and the non-key part stored off-chain, balancing security and cost efficiency.

[0146] In the S2 step, the formula of the sharding technology and the homomorphic encryption algorithm is as follows:

[0147] Data sharding algorithm:

[0148] Suppose a data set D is to be divided into multiple data segments D = {D1, D2,..., D m}, where each segment D i can be independently stored and processed;

[0149] Basic steps of data sharding:

[0150] Data division: use a hash function H to map the data item d on different segments D i ;

[0151] H(d) mod m = i,

[0152] where H(d) is the hash value of the data item d, m is the number of segments, and i represents the segment D i to which d is allocated.

[0153] Segment storage: store different segments D i in different shards of the blockchain.

[0154] Through the hash function H(d), the data item d is evenly allocated to m segments. Since the hash function has the characteristics of randomization and uniform distribution, and the mapping can ensure that the data is evenly distributed among the segments, it can prevent the data from being concentrated in a single segment, thereby preventing segment overload or resource waste.

[0155] After the data set is divided into multiple independent segments and stored in different shards of the blockchain, each segment can be independently stored and processed, and the distributed processing manner greatly improves the processing capacity of the system, enhances the scalability and processing performance of the system when facing large-scale data.

[0156] After the data is divided into multiple segments, different segments are stored in different shards, reducing the storage pressure of each shard, optimizing the access path of the data. Since the storage and computing tasks of each shard are relatively balanced, the system is more efficient and has shorter response time when storing, reading and computing data.

[0157] Since the data is divided and stored in different shards in the blockchain, even if a shard is attacked or damaged, it will not affect the data in other shards. The design enhances the fault tolerance and data security of the system, ensuring high availability of the system.

[0158] Homomorphic encryption algorithm:

[0159] Homomorphic encryption allows direct calculation under ciphertext without decryption. Assuming that the encryption function E and the decryption function D are used, and the operator is a homomorphic encryption supported operation.

[0160] Basic properties of homomorphic encryption:

[0161] Encryption: encrypt each data segment D i ;

[0162] C i =E(D i ),

[0163] where C i is the encrypted ciphertext;

[0164] Ciphertext calculation: operate on encrypted data segments C i without decryption;

[0165]

[0166] where C i,j is the ciphertext after operation, and D i +D j is the corresponding plaintext operation.

[0167] Decryption: decrypt the result when needed to obtain the calculated plaintext;

[0168] D(C i,j )=D(E(D i +D j ))=D i +D j .

[0169] The encryption formula acts in the data storage or transmission process, and unauthorized users cannot directly access the plaintext data, ensuring the privacy of the data. The encryption process maintains the computability of the data, allowing subsequent computing operations to be performed in an encrypted state. The ciphertext calculation formula allows direct operations on encrypted data without the need to decrypt the data to perform common calculations, which is particularly important for protecting data privacy, as the data remains encrypted during the calculation process. The decryption formula restores the encrypted calculation results to plaintext, enabling the conversion of calculations performed in ciphertext to readable plaintext results, ensuring the practicality of data processing and the correctness and integrity of the data processing process.

[0170] In step S4, the federated learning algorithm is a distributed machine learning method that allows multiple participants to jointly train a global model without sharing raw data. Assuming there are n participants, each participant i has a local data set D i and local model parameters W i ;

[0171] Basic steps of federated learning:

[0172] Local model update: Each participant trains the model on the local data set and updates the local model parameters:

[0173]

[0174] where η is the learning rate, L i is the loss function, and ΔL i is the gradient of the loss function;

[0175] Global model aggregation: The federated learning server collects the local model parameters of the participants and aggregates them into a global model w (t +1) :

[0176]

[0177] where n is the number of participants;

[0178] The server distributes the updated global model parameters w (t+1) to each participant, and the next round of training begins;

[0179] Homomorphic encryption allows computations to be performed on encrypted data without decryption. Assuming E(.) is the encryption function and D(.) is the decryption function, and supports additive homomorphism;

[0180] Basic properties of homomorphic encryption:

[0181] Encryption: Encrypt the local model parameters W i :

[0182] C i = E(w i ),

[0183] where C i is the encrypted model parameters.

[0184] Encrypted model aggregation: aggregate encrypted model parameters without decryption:

[0185]

[0186] Local model update formula: optimize the model step by step to reduce the prediction error and protect the privacy of data; Global model aggregation formula: after the aggregation of global model parameters, the server distributes them to the participants for use in the next round of training, while optimizing the global model; Homomorphic encryption formula: encrypted model parameters can participate in calculation, so that the federal learning server can perform subsequent aggregation operations even in an encrypted state; Encrypted model aggregation formula: through homomorphic encryption technology, even if the server itself does not have decryption capability, it can complete the necessary aggregation calculation, further protecting the privacy of the participants' data.

[0187] In step S5, the goal of the adaptive consensus mechanism is to dynamically adjust the consensus algorithm according to the network state to optimize system performance and security, and its adaptive consensus algorithm formula is:

[0188] Define state variable S(t) to represent the network state at time t, and state variable S(t) includes factors:

[0189] N(t): the number of nodes participating in consensus;

[0190] T(t): the amount of transactions in the network;

[0191] L(t): the load of the network;

[0192] Define optimization function Q(S(t)) according to the optimal consensus algorithm C(t) of state variable:

[0193]

[0194] where Q(S(t)) is a weighted sum function, and different consensus algorithms are weighted according to their contributions to system performance and security:

[0195] Q(S(t)) = α·f PoW (N(t), T(t), L(t)) + β·f PoS (N(t), T(t), L(t)) + γ·f DFT (N(t), T(t),

[0196] Wherein, a, b, g are weight parameters for adjusting the importance of each consensus algorithm, f PoW , f PoS , f DFT represent the performance and security scores in the state of each consensus algorithm.

[0197] The state variable formula functions by monitoring the state variables to keep track of the network's running status in real time, ensuring that the system can maintain optimal performance and security under different conditions; the optimization function formula functions by dynamically adjusting the consensus algorithm, allowing the system to maintain stable and efficient operation under high or low load conditions; the optimization function formula functions allow the system to flexibly adjust the use ratio of each consensus algorithm according to the real-time network status, thereby optimizing the overall performance and security of the system.

[0198] In step S6, the goal of the cross-chain interoperation protocol is to achieve data exchange and intercommunication between different blockchains, and the basic steps of its cross-chain operation are as follows:

[0199] Data locking: Lock the hash value H(D) of data D on blockchain A as a voucher to ensure that the data is tamper-proof on chain A:

[0200] Lock A (D) = H(D),

[0201] Cross-chain verification: Verify the hash value H(D) of data D on blockchain B to ensure that the status of the data on chain A is correctly recorded:

[0202] Verify B (H(D)) = True,

[0203] Data unlocking and transmission: Once the verification is passed, unlock the data on blockchain B and transmit it:

[0204] Unlock B (D) = D,

[0205] Cross-chain protocol formula: Assuming f A→B (D) represents the data transmission function from chain A to chain B, and its formula is as follows:

[0206]

[0207] The data locking formula ensures that the state of the data on chain A cannot be tampered with, and the steps establish the integrity proof of the data, guaranteeing the security and credibility of the data in subsequent cross-chain operations. The subsequent verification step on chain B relies on the locked hash value to ensure the correctness of the data; the cross-chain verification formula verifies the hash value of the data D on the chain, ensuring that the state of the data on chain A has been correctly recorded, which is the core step of secure cross-chain data transmission. If the verification fails, the data transmission cannot proceed, preventing data tampering or forgery; the data unlocking and transmission formula marks the successful completion of cross-chain data transmission and restores the use state of the data; the cross-chain protocol formula specifies that when the hash value of data D is verified on chain B, it will be unlocked and transmitted, otherwise it will return an error and abort the transmission, ensuring the security and reliability of cross-chain data transmission, guaranteeing the correctness and consistency of the data, and avoiding the risk of manual intervention.

[0208] In step S6, the semantic analysis and ontology matching algorithm is used to standardize data in different systems, and the algorithm formula is:

[0209] Semantic mapping: define the mapping relationship M(O A , O B ) between ontologies, which converts the data concept C A of chain A to the data concept C B of chain B:

[0210] M(C A , O A → O B ) = C B ,

[0211] Matching degree calculation: measure the semantic similarity between concepts by calculating the matching degree function Sim(C A , C B ):

[0212]

[0213] Standardized data transmission: in the cross-chain data transmission process, according to the mapping M, the data concept C A of chain A is converted to the standardized data concept C B on chain B:

[0214] D B = M(D A , O A → O B ).

[0215] The semantic mapping formula ensures that the concept remains consistent in different systems during cross-chain data transmission, which is crucial for data exchange between heterogeneous blockchain platforms, enabling the system to accurately convert data on chain A into standardized data concepts on chain B, avoiding ambiguity in data understanding; the matching degree calculation formula helps the system identify the closest concept pair in terms of semantics, improving the conversion accuracy of data during cross-chain transmission and reducing data errors or ambiguities caused by concept mismatch; the standardized data transmission formula ensures the correct interpretation and use of cross-chain data on the target chain through standardized data transmission, avoiding transmission errors or data loss due to differences in data format and semantics between different chains.

[0216] In step S8, the algorithm steps of distributed computing are as follows:

[0217] Local computation: each node N i In local computation, assuming that the global mean μ is to be calculated, each node first calculates its local mean μ i :

[0218]

[0219] Global aggregation: the node sends its local mean μ i to the aggregation node, which calculates the global mean μ:

[0220]

[0221] Global statistical calculation: for more complex statistics, a two-stage calculation method can be used, first calculating the local variance and then aggregating to the global variance σ 2 :

[0222]

[0223] The local computation formula helps protect data privacy by having each node only process local data sets without the need to share data, avoiding the bottleneck problem caused by centralizing data for processing; the global aggregation formula avoids the centralized transmission and processing of large amounts of data by having each node independently calculate and aggregate the results, improving the efficiency and scalability of global statistical calculation; the global statistical calculation formula reduces data transmission and computing overhead while maintaining high accuracy by calculating the local variance and local mean in two steps and then performing global aggregation, which helps reduce errors in distributed systems caused by directly calculating global statistics.

[0224] In step S8, the data statistical analysis formula can use a distributed linear regression model, and its algorithm steps are as follows:

[0225] Local gradient calculation: each node Ni Compute the gradient g on its local data i :

[0226]

[0227] where X i and y i are the local data on node N i ;

[0228] Global gradient aggregation: the node sends its local gradient g i to the aggregation node, and the aggregation is the global gradient g:

[0229]

[0230] Parameter update: update the regression coefficient β using the global gradient:

[0231] β (t+1) = β (t) - ηg,

[0232] where η is the learning rate.

[0233] The function of the local gradient calculation formula is that the node can participate in the training of the global model while protecting the privacy of the data by calculating the gradient locally, which is particularly important for the processing of sensitive data; the function of the global gradient aggregation formula is that the system can comprehensively consider the influence of the local data of the node on the model by summarizing the local gradient calculated by each node to form the global gradient g, so as to ensure that the global model can correctly reflect the structure and characteristics of the data set; the function of the parameter update formula is that the model can be optimized by updating the regression coefficient using the global gradient, so that it can more accurately fit the data, and the learning rate controls the step of parameter update, which affects the speed and stability of model convergence.

[0234] Although the embodiments of the present application have been shown and described, it can be understood by those skilled in the art that various changes, modifications, replacements and variations can be made to the embodiments without departing from the principles and spirits of the present application, and the scope of the present application is defined by the appended claims and their equivalents.

Claims

1. A blockchain-based method for the statistical management and analysis of clinical data, characterized in that, Includes the following steps: Clinical data is collected from sources such as hospitals, clinics, and patient devices to utilize hierarchical storage algorithms to categorize data based on its sensitivity, frequency of access, and size. The hierarchical storage algorithm steps are as follows: Assuming the clinical dataset to be processed Among them, each data item It has the following attributes: Sensitivity Defined as the sensitivity level of the data; Access frequency Defined as the expected number of times or frequency of data access; Data size Defined as the size of a data item; A weighted scoring function is used to calculate a comprehensive score for each data item, which is then used to evaluate the storage location of the data item. The algorithm formula for the weighted scoring function of the data item is as follows: in, These are predefined weight parameters; Hierarchical decision-making rules: Based on the overall score Classify and store the data: On-chain storage: based on overall score Greater than or equal to the threshold Data is stored on the blockchain; Off-chain storage: based on overall score Less than or equal to the threshold The data is stored in an off-chain distributed storage system; Hybrid storage: based on overall score Greater than the threshold And overall score Less than the threshold A hybrid storage strategy is adopted, with some data stored on-chain and some data stored off-chain; By applying sharding technology, the blockchain is divided into different data segments for processing, and homomorphic encryption algorithms are used to encrypt the data; Patients can set the scope and duration of access to their data and permissions through smart contracts, and revocable anonymization technology is introduced to allow disclosure of some data; The federated learning algorithm allows medical institutions to train models without sharing raw data, and homomorphic encryption technology is used to perform encrypted computations on on-chain data. The federated learning algorithm is a distributed machine learning method that allows multiple participants to jointly train a global model without sharing the original data. Assume there are... Each participant Have local dataset and local model parameters ; The basic steps of federated learning: Local model update: Each participant trains its model on its local dataset and updates the local model parameters. in, For learning rate, For loss function, The gradient of the loss function; Global model aggregation: The federated learning server collects the local model parameters from the participants and aggregates them into a global model. : in, The number of participants; The server will update the global model parameters. Distribute to all participants and proceed to the next round of training; The homomorphic encryption allows computation to be performed on encrypted data without decryption, assuming it is an encryption function. It is a decryption function and supports additive homomorphism; The fundamental properties of homomorphic encryption: Encryption: Encryption of local model parameters Encrypt: in, For the encrypted model parameters, As a participant Local model parameters; Encryption Model Aggregation: Aggregate encrypted model parameters without decryption. ; An adaptive consensus mechanism is introduced to dynamically adjust the consensus algorithm based on the network status, and data changes are recorded and updated in real time through smart contracts to automatically generate audit reports; Using advanced cross-chain interoperability protocols, data from various healthcare systems is standardized through semantic analysis and ontology matching algorithms; Develop a simple and easy-to-use user interface, hide complex encryption and data management operations, and use automatic optimization algorithms to dynamically adjust the blockchain configuration according to user needs and system load; The goal of the cross-chain interoperability protocol is to achieve data exchange and interoperability between different blockchains. The basic steps of its cross-chain operation are as follows: Data Locking: On the Blockchain Locking up the clinical dataset hash value As credentials, ensuring data is on the blockchain The above cannot be altered: , Cross-chain verification: in blockchain Up to validate clinical dataset hash value To ensure data is on the blockchain The status on was correctly recorded: , Data unlocking and transmission: Once verified, on the blockchain Unlock data and transmit it: Cross-chain protocol formula: Assumption Blockchain To blockchain The data transfer function is defined by the following formula: ; By leveraging the distributed computing capabilities of the blockchain network, statistical analysis is performed on on-chain data to generate clinical research reports; The algorithm steps for distributed computing are as follows: Local computation: Each node Calculate statistics locally, assuming we want to calculate the global mean. First, calculate the local mean at each node. : in, For data items, As a participant The local dataset that we possess; Global aggregation: Nodes will calculate the local mean. Send to the aggregation node to calculate the global mean. : Global statistical calculation: For more complex statistics, a two-stage calculation method can be used, first calculating the local variance. The variance is then aggregated into the global variance. : ; The system installation and maintenance process is simplified by using automated deployment algorithms, and system parameters are dynamically adjusted based on actual usage through continuous performance monitoring and adaptive maintenance algorithms.

2. The clinical data statistical management and analysis method based on blockchain according to claim 1, characterized in that, The The formulas for the fragmentation technique and homomorphic encryption algorithm in the steps are as follows: The data sharding algorithm: Assuming dataset To be divided into multiple data segments Among them, each segment Each can be stored and processed independently; The basic steps of data sharding: Data partitioning: using a hash function data items Mapped on different fragments superior; in, For data items hash value, It is the number of segments. For data items The assigned fragment Fragment storage: storing different fragments It is stored in different shards of the blockchain.

3. The method for statistical management and analysis of clinical data based on blockchain according to claim 2, characterized in that, The homomorphic encryption algorithm: Homomorphic encryption allows direct computation on ciphertext without decryption, assuming the use of an encryption function. Decryption function Furthermore, the operator ⊕ is an operation supported by homomorphic encryption; The fundamental properties of homomorphic encryption: Encryption: Encryption of each data segment Encrypt; Ciphertext computation: the computation of encrypted data fragments Perform the operation without decryption; Decryption: When necessary, decrypt the result to obtain the calculated plaintext; in, The encrypted ciphertext, For encryption functions, The encrypted text after the operation. This is a data fragment.

4. The method for statistical management and analysis of clinical data based on blockchain according to claim 1, characterized in that, The In this process, the adaptive consensus mechanism aims to dynamically adjust the consensus algorithm based on the network state to optimize system performance and security. Its adaptive consensus algorithm formula is as follows: Define state variables Indicates time Network state at any given time, state variables Factors included: This refers to the number of nodes participating in the consensus process. For transaction volume in the network, Network load, define optimization function Consensus algorithm based on optimal state variables in, The form is a weighted sum function, which weights the contributions of different consensus algorithms to system performance and security: in, Weight parameters are used to adjust the importance of each consensus algorithm.

5. The method for statistical management and analysis of clinical data based on blockchain according to claim 1, characterized in that, The In this process, semantic analysis and ontology matching algorithms are used to standardize data from different systems. The algorithm formula is as follows: Semantic mapping: Defines the mapping relationships between ontologies. Mapping will chain Data Concepts Convert to chain Data Concepts Matching degree calculation: by calculating the matching degree function Measuring semantic similarity between concepts: .

6. The method for statistical management and analysis of clinical data based on blockchain according to claim 1, characterized in that, The In this process, the statistical analysis formula can use a distributed linear regression model, and the algorithm steps are as follows: Local gradient calculation: each node Calculate the gradient on local data : in, For nodes Local data on; Global gradient aggregation: Nodes aggregate local gradients Send to the aggregation node, where it is aggregated into global gradients. Parameter update: Update regression coefficients using global gradient in, This is the learning rate.

Citation Information

Patent Citations

  • Block chain privacy protection method and system based on homomorphic encryption algorithm and zero-knowledge proof protocol

    CN116915379A

  • Federal learning privacy protection system and method based on block chain and privacy computing technology

    CN117852068A

  • Breast cancer clinical data analysis diagnosis and treatment platform based on artificial intelligence large language model

    CN118016280A

  • Block chain on-chain and off-chain heterogeneous data association storage method and system

    CN118035350A

  • Processing method and device based on block chain network, electronic equipment and medium

    CN118368291A