Decentralized semi-asynchronous federated learning method based on committee consensus

By introducing the committee consensus method in decentralized federated learning, using the Byzantine Committee consensus mechanism and blockchain technology, the security and efficiency problems in a trustless environment are solved, and a high-performance and highly robust semi-asynchronous federated learning framework is built to achieve the transparency and trustworthy consensus of model updates.

CN120258174APending Publication Date: 2025-07-04NANJING UNIV OF POSTS & TELECOMM
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510381142.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-28
Publication Date
2025-07-04

AI Technical Summary

Technical Problem

Existing decentralized federated learning systems face challenges in security, efficiency and consensus method design in trustless environments, especially in dynamic environments, and traditional solutions are difficult to coordinate needs of all parties.

Method used

The committee consensus method is introduced, and the Byzantine Committee consensus mechanism is used to realize the recording and trustworthy consensus of model updates in a trustless environment. The transparency and credibility of model updates are ensured through the immutability of blockchain, and the autonomous security architecture and dynamic optimization mechanism are adopted to reduce system complexity and communication overhead.

Benefits of technology

A semi-asynchronous federated learning framework with high performance, high robustness and high security was built, which solved the consistency problem caused by data heterogeneity, improved the performance and efficiency of the global model, and enhanced the security and reliability of the framework.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120258174A_ABST
    Figure CN120258174A_ABST
Patent Text Reader

Abstract

The invention discloses a decentralized semi-asynchronous federated learning method based on committee consensus. The decentralized semi-asynchronous federated learning method specifically comprises a semi-asynchronous federated learning framework; participants are arranged in the framework, and the participants are divided into two identities, namely task publisher nodes and local equipment nodes; the federated learning task is determined by a task publisher node and specifically comprises information of a model structure, a training target, a model initialization parameter and an update quantity required by each round of global model update. According to the method, a high-performance, high-robustness and high-security semi-asynchronous federated learning framework is constructed, an innovative solution is provided for federated learning in a trustless environment, and the Byzantine committee consensus method oriented to semi-asynchronous federated learning has the advantages of being high in robustness and security under the condition of not depending on a third-party credible node. The security and reliability of the framework are ensured, and the efficiency and throughput of the framework are improved at the same time.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical fields of machine learning, blockchain, and federated learning, and specifically provides a decentralized semi-asynchronous federated learning method based on committee consensus. Background Art

[0002] As a distributed model training method, federated learning enables each participating node to perform data training locally and send model updates to a central server for aggregation, ensuring data privacy and security. However, traditional federated learning relies on a centralized server, which not only brings the risk of single-point failure but also may cause data security and fairness issues in some application scenarios.

[0003] To address these issues, blockchain technology has been introduced into federated learning to form decentralized federated learning. The decentralized and immutable characteristics of blockchain effectively solve some security challenges in federated learning. By applying the consensus method of blockchain to federated learning, the system can achieve decentralized updates and verification of the global model without relying on a central server, improving the robustness and security of the system.

[0004] However, decentralized federated learning still faces challenges in terms of efficiency. Traditional synchronous aggregation methods require all nodes to complete tasks synchronously, resulting in low efficiency due to differences in node computing power and network environments. Although asynchronous federated learning alleviates this problem, frequent model transmissions bring a huge communication overhead, and the accuracy of the model is also affected, especially when dealing with non-independent and identically distributed data.

[0005] Therefore, semi-asynchronous federated learning has been proposed, which combines the advantages of synchronous and asynchronous methods. In each round of training, a certain number of local models are aggregated according to the arrival order of the nodes, avoiding the inefficiency of waiting for the slowest node and reducing the communication overhead. However, in a trustless decentralized environment, semi-asynchronous federated learning still faces challenges in security and consensus method design. Existing research mainly focuses on aggregation algorithms and the handling of straggler nodes, ignoring the importance of consensus methods in a decentralized environment.

[0006] The defects of the existing technologies mainly focus on security, flexibility, dependence on trusted third parties, system implementation complexity and high overhead, and the limitations of smart contracts in handling dynamic problems. These defects make it difficult for existing systems to simultaneously ensure the efficiency, robustness, and security of federated learning when facing challenges such as malicious nodes, resource heterogeneity, and dynamic changes in node states. Especially in a fully decentralized, dynamic, and trustless environment, these deficiencies are particularly prominent. Existing solutions are difficult to effectively coordinate the needs of all parties in design and implementation to ensure the security and efficiency of the system. Summary of the Invention

[0007] In view of the deficiencies of the prior art, the present invention applies the committee consensus method to trustless decentralized semi-asynchronous federated learning, aiming to solve the above-mentioned security problems. By introducing the committee consensus method, each node can record and achieve trusted consensus on model updates without relying on a central server. The immutability of the blockchain ensures the transparency and credibility of model updates, preventing malicious nodes from tampering with the results of model updates. At the same time, the application of the committee consensus method avoids the problem of low efficiency of traditional consensus methods in large-scale networks and improves the overall performance of the system.

[0008] To achieve the above objectives, the present invention is realized through the following technical solutions: A decentralized semi-asynchronous federated learning method based on committee consensus, specifically including a semi-asynchronous federated learning framework;

[0009] The framework is provided with participants, and the participants are divided into two identities: task publisher nodes and local device nodes;

[0010] The federated learning task is determined by the task publisher node, specifically including information such as the model structure, training objective, model initialization parameters, and the number of updates required for each round of global model updates;

[0011] The task information is recorded on the blockchain for all local device nodes to obtain;

[0012] Each local device node trains the model using local data according to the task requirements;

[0013] After the training is completed, the local device node encapsulates the local model update and related information into a transaction and submits it to the blockchain network.

[0014] Preferably, the framework allows nodes to start the aggregation process of the global model as long as a sufficient number of nodes submit model updates without waiting for all other nodes to complete local training;

[0015] In the process of validating and aggregating model updates, the framework introduces the Byzantine committee consensus method. In the consensus stage, nodes that have completed the training task and submitted updates to the blockchain network become part of the main committee. At the same time, extended committee nodes are elected from the nodes that have not completed the training task. These two committees together form the Byzantine committee. The Byzantine committee is responsible for validating model updates and aggregating the global model. These committee nodes use the practical Byzantine fault tolerance method to ensure the credibility of model updates and the security of the global model. Even in the presence of malicious nodes, the framework can still run stably. The verified model updates are recorded on the blockchain and can be accessed by all nodes, ensuring the transparency and immutability of the data.

[0016] Preferably, after the new global model is aggregated and generated, it is recorded on the blockchain for all local device clients to obtain and use for the next round of local training.

[0017] Preferably, the overall parameters of the framework are specifically defined as follows;

[0018] A1. The total number of local device nodes participating in the training in the federated learning framework, which is the total number of local device nodes participating in the training in the federated learning framework;

[0019] A2. The number of local device nodes that have completed local training first in the current training round. When n local device nodes that have completed training are reached, the main committee is formed;

[0020] A3. The number of members of the extended committee, and m nodes are selected from the nodes that have not completed training;

[0021] A4. It is defined as the maximum time allowed for consensus voting within the main committee.

[0022] Preferably, in each round of global model aggregation, it is not necessary to wait for all nodes to complete local training. As long as n nodes have completed training, the aggregation process can be started, which reflects the semi-asynchronous feature. These n nodes that have completed local training and participated in the aggregation form the main committee, and m nodes are selected from the nodes that have not completed training to form the extended committee. The nodes that have not entered the extended committee continue to perform local training;

[0023] The values of n and m are as follows:

[0024] m = 2n + 1;

[0025] A leader node is elected from the main committee. The main responsibility of the leader node is to aggregate the updated local node models that have completed training and generate a candidate new round of global model.

[0026] Preferably, the responsibility of the main committee is to generate a candidate new round of global model and reach consensus internally, while the responsibility of the candidate committee is to independently verify and perform performance evaluation on the proposals submitted by the main committee to ensure the correctness and robustness of the proposals. Whether to accept the proposal as the new global model is decided by more than 2 / 3 of the members voting in favor through majority voting. In addition to normal verification, when the main committee fails to output a consistent proposal, an internal deadlock, timeout, or failure occurs, the extended committee is responsible for the consensus recovery process.

[0027] Preferably, the generation method of the main committee and the extended committee and the specific process of internal consensus voting of the main committee include the following steps;

[0028] B1. Generate the main committee. When n nodes complete local training, these nodes automatically become members of the main committee. The smart contract records the start time of this round of main committee consensus.

[0029] B2. The received local model updates are aggregated, and the leader node in the main committee aggregates a new round of global models through an aggregation algorithm;

[0030] B3. Generate an extended committee and select m nodes as members of the extended committee through a random algorithm.

[0031] C1. Proposal generation: The leader node packages the aggregation results into a proposal and sends it to other main committee members. The proposal includes the global parameters of the new round of aggregation results, the leader node signature, and the hash;

[0032] C2. During the pre-preparation and preparation phase of the main committee, all members of the main committee verify the legitimacy of the proposal, including checking the model parameter format, signature, and hash, and broadcast the instruction message to other members after confirming its validity;

[0033] C3. During the submission stage of the Main Committee, the members of the Main Committee vote based on the above verification results. If the verification is passed, they will vote for approval, and if it is not passed, they will not vote.

[0034] Preferably, in the success case, when more than 2 / 3 of the members of the main committee approve the proposal, after the message interaction in the instruction and submission phase, the internal consensus is reached, and the proposal is regarded as the final aggregation result within the main committee, and then enters the S1 phase; in the failure case, if 2 / 3 of the members of the main committee fail to approve the proposal, and the smart contract detects that the consensus time of the main committee reaches the main committee consensus time threshold T, the smart contract notifies each member of the extended committee that the main committee consensus has failed. At this time, the smart contract converts the consensus method in this round of the framework into a single-committee consensus method, and the main committee and the extended committee are combined to form the consensus committee of this round, and a consensus vote is re-performed in the consensus committee.

[0035] Preferably, the verification method of the extension committee specifically includes the following steps:

[0036] S1. The proposal is submitted to the extended committee. The main committee submits the proposal and signature set S_Main to the extended committee.

[0037] S2. During the pre-preparation and preparation phase of the extended committee, the m members of the extended committee independently verify the legitimacy of the proposal, including:

[0038] Verify the number of multi-signatures:

[0039] Verify the correctness of the aggregated proof information;

[0040] Performance check: Performance (M) ≥ θ, where θ is the performance threshold, ensuring that the performance of the Proposal on the public verification dataset is not lower than this threshold, and this threshold is 90% of the accuracy of the previous round of the global model.

[0041] Preferably, the extended committee members vote according to the verification results. If the verification passes, they vote in favor; if it fails, they do not vote.

[0042] Through an innovative autonomous security architecture and dynamic optimization mechanism, the system of the present invention successfully eliminates the dependence on a trusted third party. Its modular design significantly reduces the system complexity, and a lightweight resource scheduling strategy is adopted to greatly reduce the operation overhead. The intelligent contract demonstrates strong adaptive capabilities in a dynamic environment through multi-dimensional state perception and real-time parameter adjustment technologies, effectively overcoming the rigidity defects of traditional solutions. In the face of malicious node penetration and resource heterogeneity, the system relies on a hierarchical defense mechanism and an elastic resource allocation algorithm to construct a collaborative protection system in a zero-trust environment in a completely decentralized architecture, enabling the coordination of multi-party requirements in a dynamic trustless scenario to achieve unprecedented accuracy and stability.

[0043] This method constructs a semi-asynchronous federated learning framework with high performance, high robustness, and high security, providing an innovative solution for federated learning in a trustless environment. The Byzantine committee consensus method for semi-asynchronous federated learning implements a very important consensus algorithm in decentralized semi-asynchronous federated learning, enhancing the security and reliability of the framework, solving the consistency problem caused by data heterogeneity, improving the performance of the global model, ensuring the security and reliability of the framework without relying on a third-party trusted node, and at the same time improving the efficiency and throughput of the framework. BRIEF DESCRIPTION OF THE DRAWINGS

[0044] Figure 1 It is the overall process framework diagram of the present invention;

[0045] Figure 2 It is the overall flow chart of the present invention;

[0046] Figure 3 It is the consensus flow chart of the present invention;

[0047] Figure 4 It is the schematic diagram of the consensus process of the present invention Figure 1 ;

[0048] Figure 5 It is the schematic diagram of the consensus process of the present invention Figure 2 。 Detailed Implementation Modes

[0049] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only a part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0050] Please refer to Figures 1-5 , an embodiment of the present invention provides a technical solution, a decentralized semi-asynchronous federated learning method based on committee consensus, specifically including a semi-asynchronous federated learning framework;

[0051] There are participants in the framework, and the participants are divided into two identities: task publisher nodes and local device nodes;

[0052] The federated learning task is determined by the task publisher node, specifically including information such as the model structure, training objective, model initialization parameters, and the number of updates required for each round of global model update;

[0053] The task information is recorded on the blockchain for all local device nodes to obtain;

[0054] Each local device node trains the model using local data according to the task requirements;

[0055] After the training is completed, the local device node encapsulates the local model update and related information into a transaction and submits it to the blockchain network.

[0056] In the present invention, the framework allows nodes to start the aggregation process of the global model as long as a sufficient number of nodes submit model updates without waiting for all other nodes to complete local training;

[0057] In the process of validating and aggregating model updates, the framework introduces the Byzantine committee consensus method. In the consensus stage, the nodes that have completed the training task and submitted updates to the blockchain network become part of the main committee. At the same time, extended committee nodes are elected from the nodes that have not completed the training task. These two committees together form the Byzantine committee. The Byzantine committee is responsible for validating model updates and aggregating the global model. These committee nodes use the practical Byzantine fault tolerance method to ensure the credibility of model updates and the security of the global model. Even in the presence of malicious nodes, the framework can still run stably. The verified model updates are recorded on the blockchain and can be accessed by all nodes, ensuring the transparency and immutability of the data.

[0058] In the present invention, after the new global model aggregation is generated, it is recorded on the blockchain for all local device clients to obtain and used for the next round of local training.

[0059] In the present invention, the overall framework parameters are specifically defined as follows;

[0060] A1. The total number of local device nodes participating in the training in the federated learning framework, which is the total number of local device nodes participating in the training in the federated learning framework;

[0061] A2. The number of local device nodes that have completed local training first in the current training round. When n local device nodes that have completed training are reached, the main committee is formed;

[0062] A3. The number of members of the extended committee, and m nodes are selected from the nodes that have not completed training;

[0063] A4. It is defined as the maximum time allowed for consensus voting within the main committee.

[0064] In the present invention, in each round of global model aggregation, it is not necessary to wait for all nodes to complete local training. As long as n nodes have completed training, the aggregation process can be started, which reflects the semi-asynchronous feature. These n nodes that have completed local training and participated in the aggregation form the main committee, and m nodes are selected from the nodes that have not completed training to form the extended committee. The nodes that have not entered the extended committee continue with local training;

[0065] The values of n and m are as follows:

[0066] m = 2n + 1;

[0067] A leader node is elected from the main committee. The main responsibility of the leader node is to aggregate the updated local node models that have completed training to generate a candidate new round of global model.

[0068] The responsibility of the main committee is to generate a candidate new round of global model and reach consensus internally, while the responsibility of the candidate committee is to independently verify and perform performance evaluation on the proposals submitted by the main committee to ensure the correctness and robustness of the proposals. It is decided whether to accept the proposal as the new global model by a majority vote of more than 2 / 3 of the members agreeing. In addition to normal verification, when the main committee is unable to output a consistent proposal, resulting in an internal deadlock, timeout, or failure, the extended committee is responsible for the consensus recovery process.

[0069] In the present invention, the generation methods of the main committee and the extended committee and the specific process of internal consensus voting of the main committee include the following steps;

[0070] B1. Generate the main committee. When n nodes complete local training, these nodes automatically become members of the main committee. The smart contract records the start time of this round of main committee consensus.

[0071] B2. The received local model updates are aggregated, and the leader node in the main committee aggregates a new round of global models through an aggregation algorithm;

[0072] B3. Generate an extended committee and select m nodes as members of the extended committee through a random algorithm.

[0073] C1. Proposal generation: The leader node packages the aggregation results into a proposal and sends it to other main committee members. The proposal includes the global parameters of the new round of aggregation results, the leader node signature, and the hash;

[0074] C2. During the pre-preparation and preparation phase of the main committee, all members of the main committee verify the legitimacy of the proposal, including checking the model parameter format, signature, and hash, and broadcast the instruction message to other members after confirming its validity;

[0075] C3. During the submission stage of the Main Committee, the members of the Main Committee vote based on the above verification results. If the verification is passed, they will vote for approval, and if it is not passed, they will not vote.

[0076] In the present invention, in the case of success, when more than 2 / 3 of the members of the main committee approve the Proposal, after the message interaction in the instruction and submission phase, the internal consensus is reached. At this time, the Proposal is regarded as the final aggregation result within the main committee, and then enters the S1 phase;

[0077] In this embodiment, when the main committee consensus fails, and 2 / 3 of the members of the main committee have not yet approved the proposal, the smart contract detects that the main committee consensus time has reached the main committee consensus time threshold T, and the smart contract notifies each member of the extended committee that the main committee consensus has failed. At this time, the smart contract converts the consensus method in this round of the framework into a single-committee consensus method, and the main committee and the extended committee are combined to form the consensus committee of this round, and a consensus vote is re-performed in this consensus committee.

[0078] Pre-preparation and preparation stage: All committee members independently verify the legality of the proposal, including:

[0079] Check the model parameter format in the proposal;

[0080] Verify the correctness of the aggregate proof information in the proposal;

[0081] Verify the hash values ​​of the model parameters in the proposal;

[0082] Performance check: Performance (M) ≥ θ, where θ is the performance threshold, ensuring that the performance of the Proposal on the public validation dataset is not lower than this threshold, and this threshold is 90% of the accuracy of the previous round's global model.

[0083] Submission stage: All committee members vote based on the above verification results. If the verification passes, they vote in favor; if it fails, they do not vote.

[0084] Successful case: When more than 2 / 3 of the members in the committee express approval of the Proposal (after the message interaction in the preparation and submission stages), internal consensus is reached. At this time, the Proposal is regarded as the final aggregation result within the committee, and the leader node packages the global model of this consensus into a block.

[0085] Failure case: Less than 2 / 3 of the members in the committee express approval of the Proposal. Then the committee members conduct cross-verification on the local updates, and the cross-verification content includes the following:

[0086] ① Local update legality check: Confirm whether the format of the model update (such as the dimension of the weight matrix, hyperparameter settings, etc.) is consistent with the protocol specification. If the model format does not meet the requirements, the local update is considered illegal;

[0087] ② Performance consistency check: Each member tests the received local update on the public validation set. If the obtained accuracy rate is lower than 90% of the accuracy of the previous round's global model, the local update is considered illegal;

[0088] If it is not verified by 2 / 3 of the nodes, the smart contract removes its update from the transaction pool, marks the node that submitted this update as a malicious node, and prohibits it from participating in the federated learning process within this round. At the same time, this round of consensus fails, and the main committee and the extended committee are dissolved. The regular members of the main committee continue to wait until enough new local nodes complete training and submit local updates to start the next round of aggregation and consensus.

[0089] In the present invention, recovery stage: After the end of this round of consensus, the smart contract converts the consensus method in the federated learning framework into a two-layer committee consensus method.

[0090] In this embodiment, when the main committee consensus is successful: The main committee members digitally sign the finally approved Proposal to form a multi-signature set S_Main, and attach relevant proofs (such as the hash values of each local update, the summary of the aggregation algorithm parameters) to ensure the verifiability of the aggregation process. The verification method of the extended committee specifically includes the following steps;

[0091] S1. The proposal submission to the extended committee. The main committee submits the proposal Proposal and the signature set S_Main to the extended committee;

[0092] S2. The pre - preparation and preparation stages of the extended committee. m members of the extended committee independently verify the legality of the proposal Proposal, including:

[0093] Verify the number of multi - signatures:

[0094] Verify the correctness of the aggregated proof information;

[0095] In the present invention, performance check: Performance (M) ≥ θ, where θ is the performance threshold, ensuring that the performance of the proposal Proposal on the public verification dataset is not lower than this threshold, and this threshold is 90% of the accuracy of the previous round of the global model.

[0096] In the present invention, the members of the extended committee vote according to the verification results. If the verification passes, they vote in favor; if not, they do not vote. Pre - preparation and preparation stages:

[0097] All members of the committee independently verify the legality of the proposal Proposal, including:

[0098] Check the model parameter format in the proposal.

[0099] Verify the correctness of the aggregated proof information in the proposal.

[0100] Verify the hash value of the model parameters in the proposal.

[0101] Performance check: Performance (M) ≥ θ. Where θ is the performance threshold, ensuring that the performance of the proposal Proposal on the public verification dataset is not lower than this threshold. This threshold is 90% of the accuracy of the previous round of the global model.

[0102] Submission stage: All committee members vote according to the above verification results. If the verification passes, they vote in favor; if not, they do not vote.

[0103] Success case: When more than 2 / 3 of the members in the committee express their approval of the proposal Proposal (after the message interaction in the preparation and submission stages), internal consensus is reached. At this time, the proposal Proposal is regarded as the final aggregated result within the committee. The leader node packages the global model of this consensus into a block.

[0104] In the present invention, if less than 2 / 3 of the members of the Failure Committee approve the Proposal, the committee members perform cross-verification on the local update. The cross-verification content includes the following: ① Local update legality check: Confirm whether the format of the model update (such as the dimension of the weight matrix, hyperparameter settings, etc.) is consistent with the protocol specification. If the model format does not meet the requirements, the local update is considered illegal. ② Performance consistency check: Each member tests the received local update on the public validation set. If the obtained accuracy rate is lower than 90% of the accuracy of the previous round of the global model, the local update is considered illegal.

[0105] If the update is not verified and passed by 2 / 3 of the nodes, the smart contract removes the update from the transaction pool, marks the node that submitted the update as a malicious node, and prohibits it from participating in the federated learning process within this round. At the same time, the consensus for this round fails, and the main committee and the extended committee are dissolved. The regular members of the main committee continue to wait until enough new local nodes complete training and submit local updates to initiate the next round of aggregation and consensus.

[0106] The committee shown in the above embodiment is the extended committee. The verification method of the extended committee is as follows;

[0107] First, when a Proposal is proposed and reaches an agreement in the main committee, it enters the verification stage of the extended committee;

[0108] Submission of the Proposal to the extended committee: The main committee submits the Proposal and the signature set S_Main to the extended committee.

[0109] Next, the pre-preparation and preparation stage of the extended committee: m members of the extended committee independently verify the legality of the Proposal, including: verifying the number of multi-signatures: Verifying the correctness of the aggregation proof information.

[0110] Performance check: Performance (M) ≥ θ, where θ is the performance threshold, ensuring that the performance of the Proposal on the public validation data set is not lower than this threshold, and this threshold is 90% of the accuracy of the previous round of the global model.

[0111] Submission stage of the extended committee: The members of the extended committee vote based on the above verification results. If the verification passes, they vote in favor; if not, they do not vote.

[0112] Successful case: If more than 2 / 3 of the members of the extended committee approve the Proposal, the extended committee approves the global model, the smart contract declares the consensus successful, and the leader of the main committee packages the Proposal into a new block to start a new round of training and consensus iteration.

[0113] Failure case: If the proposal Proposal is not approved by more than 2 / 3 of the extended committee members, the proposal Proposal is considered illegal. Reject the proposal. At the same time, enter the consistency recovery phase after rejecting the proposal.

[0114] Secondly, the extended committee conducts cross-verification on the local updates of this round. The content of the cross-verification is as follows:

[0115] Local update legality check: Confirm whether the format of the model update (such as the dimension of the weight matrix, hyperparameter settings, etc.) is consistent with the protocol specification. If the model format does not meet the requirements, the local update is considered illegal. Performance consistency check: Each member tests the received local update on the public validation set. If the obtained accuracy rate is lower than 90% of the accuracy of the previous round of the global model, the local update is considered illegal.

[0116] If the local update is not verified by 2 / 3 of the nodes, the smart contract will remove its update from the transaction pool, mark the node that submitted the update as a malicious node, and remove it from the federated learning process. At the same time, the consensus of this round fails, and the main committee and the extended committee are dissolved.

[0117] Finally, the normal members of the main committee continue to wait until enough new local nodes complete training and submit local updates to start the next round of aggregation and consensus.

[0118] This method constructs a semi-asynchronous federated learning framework with high performance, high robustness, and high security, providing an innovative solution for federated learning in a trustless environment. The Byzantine committee consensus method for semi-asynchronous federated learning implements a very important consensus algorithm in decentralized semi-asynchronous federated learning, enhancing the security and reliability of the framework, solving the consistency problem caused by data heterogeneity, and improving the performance of the global model.

[0119] Initialization:

[0120] Step 1: The task publisher initializes the blockchain-based semi-asynchronous federated learning framework and publishes information such as tasks, initial global models, and task objectives in the blockchain.

[0121] Step 2: The local device (local device node) registers in the blockchain to enter the framework and joins the blockchain network.

[0122] Training phase:

[0123] Step 1: The node trains the model using its local dataset.

[0124] Step 2: When the local training is completed, the node broadcasts the model parameters trained locally through the blockchain.

[0125] Step 3: The nodes that have completed training first become members of the main committee. When n nodes have completed training, the consensus phase is initiated.

[0126] Consensus phase:

[0127] Step 1: The smart contract in the blockchain broadcasts information to start the consensus phase. Nodes that have not completed local training can run for membership in the extended committee through the smart contract.

[0128] Step 2: After the committee is formed, a leader node is elected.

[0129] Step 3: The leader node aggregates to generate a new candidate global model through an aggregation algorithm.

[0130] Step 4: Conduct a consensus consistency algorithm through the above consensus process.

[0131] Step 5: Each local device (local device node) that has completed training and been aggregated obtains the new global model from the blockchain as its new local model to continue training.

[0132] Subsequently, the training phase and the consensus phase are repeated until the global model meets the requirements of the task publisher.

[0133] The blockchain technology is deeply integrated with semi-asynchronous federated learning to construct an efficient, secure, and robust decentralized federated learning framework. This innovation fully utilizes the decentralized, immutable, and transparent characteristics of the blockchain to solve the single-point failure and privacy security problems existing in traditional federated learning. At the same time, the semi-asynchronous aggregation mechanism avoids the inefficiency of synchronous methods and the high communication overhead of asynchronous methods, improving the efficiency of model training and updating.

[0134] A Byzantine committee consensus mechanism for semi-asynchronous federated learning is designed. By dividing the committee into a main committee and an extended committee and using the practical Byzantine fault tolerance mechanism (PBFT), it realizes secure and efficient model update and transaction confirmation in the case of asynchronous node training progress. This mechanism only requires partial nodes to participate in the consensus, avoiding the problem of waiting for full network synchronization, and improving the efficiency and throughput of the framework. At the same time, it can prevent interference from malicious nodes and enhance the security and robustness of the framework.

Claims

1. A decentralized semi-asynchronous federated learning method based on committee consensus, characterized in that: Specifically, it includes a semi-asynchronous federated learning framework; In this framework, there are participants, which are divided into two identities: task publisher nodes and local device nodes; The federated learning task is determined by the task publisher node, specifically including information such as the model structure, training objective, model initialization parameters, and the number of updates required for each round of global model update; The task information is recorded on the blockchain for all local device nodes to obtain; Each local device node trains the model using local data according to the task requirements; After the training is completed, the local device node encapsulates the local model update and related information into a transaction and submits it to the blockchain network.

2. The decentralized semi-asynchronous federated learning method based on committee consensus according to claim 1, wherein: This framework allows nodes to start the aggregation process of the global model as long as a sufficient number of nodes submit model updates without waiting for all other nodes to complete local training; In the process of validating and aggregating model updates, the framework introduces the Byzantine Committee Consensus Method. In the consensus stage, nodes that have completed the training task and submitted updates to the blockchain network become part of the main committee. At the same time, extended committee nodes are elected from nodes that have not completed the training task. These two committees together form the Byzantine Committee. The Byzantine Committee is responsible for validating model updates and aggregating the global model. These committee nodes use the Practical Byzantine Fault Tolerance method to ensure the credibility of model updates and the security of the global model. Even in the presence of malicious nodes, the framework can still operate robustly. The verified model updates are recorded on the blockchain and can be accessed by all nodes, ensuring data transparency and immutability.

3. The decentralized semi-asynchronous federated learning method based on committee consensus according to claim 2, characterized in that: After the new global model is aggregated and generated, it is recorded on the blockchain for all local device clients to obtain and use for the next round of local training.

4. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 1, characterized in that: The overall parameters of the framework are specifically defined as follows; A1: The total number of local device nodes participating in training in the federated learning framework, which is the total number of local device nodes participating in training in the federated learning framework; A2: The number of local device nodes that have completed local training first in the current training round. When n local device nodes that have completed training are reached, the main committee is formed; A3: The number of members of the extended committee, which selects m nodes from nodes that have not completed training; A4: Defined as the maximum time allowed for achieving consensus voting within the main committee.

5. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 4, characterized in that: In each round of global model aggregation, there is no need to wait for all nodes to complete local training. As long as n nodes have completed training, the aggregation process can be started, which reflects the semi-asynchronous feature. These n nodes that have completed local training and participated in the aggregation form the main committee, and m nodes are selected from nodes that have not completed training to form the extended committee. Nodes that have not entered the extended committee continue with local training; The values of n and m are as follows: m = 2n + 1; A leader node is elected from the main committee. The main responsibility of the leader node is to aggregate the model updates of local nodes that have completed training and generate a candidate new round of global model.

6. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 1, characterized in that: The responsibilities of the main committee are to generate a candidate for the new round of the global model and reach an internal consensus, while the responsibilities of the candidate committee are to independently verify and perform performance evaluation on the proposals submitted by the main committee to ensure the correctness and robustness of the proposals, and decide whether to accept the proposal as the new global model by a majority vote of more than 2 / 3 of the members. In addition to normal verification, when the main committee fails to output a consistent proposal, resulting in an internal deadlock, timeout, or failure, the extension committee is responsible for the consistency recovery process.

7. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 6, characterized in that: The generation method of the main committee and the extension committee and the specific process of the internal consensus voting of the main committee include the following steps; B1. Generate the main committee. When n nodes complete local training, these nodes automatically become members of the main committee, and the smart contract records the start time of the main committee consensus in this round; B2. Aggregate the received local model updates. The leader node in the main committee aggregates a new round of the global model through an aggregation algorithm; B3. Generate the extension committee. Elect m nodes as members of the extension committee through a random algorithm, C1. Proposal generation. The leader node packages the aggregation result into a proposal Proposal and sends it to other main committee members. The proposal includes the new round of global parameters of the aggregation result, the signature of the leader node, and the hash; C2. Pre-preparation and preparation stages of the main committee. All main committee members perform legal verification on the proposal Proposal, including checking the model parameter format, signature, and hash, and broadcast instruction messages to other members after confirming its validity; C3. Submission stage of the main committee. The main committee members vote based on the above verification results. If the verification passes, they vote in favor; if it fails, they do not vote.

8. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 7, characterized in that: In the case of success, when more than 2 / 3 of the members in the main committee express their approval of the proposal Proposal, after the message interaction in the instruction and submission stages, internal consensus is reached. At this time, the proposal Proposal is regarded as the final aggregation result within the main committee, and then it enters the S1 stage; in the case of failure, if less than 2 / 3 of the members in the main committee express their approval of the proposal Proposal for a long time, and the smart contract detects that the main committee consensus time reaches the main committee consensus time threshold T, the smart contract notifies each member of the extension committee that the main committee consensus has failed. At this time, the smart contract converts the consensus method in this round of the framework into a single committee consensus method. The main committee and the extension committee are combined to form the consensus committee in this round, and consistency voting is carried out again in this consensus committee.

9. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 1, characterized in that: The verification method of the extension committee specifically includes the following steps; S1. Submit the proposal to the extension committee. The main committee submits the proposal Proposal and the signature set S_Main to the extension committee; S2. Pre-preparation and preparation stages of the extension committee. The m members of the extension committee independently verify the legality of the proposal Proposal, including: Verify the number of multi-signatures: Verify the correctness of the aggregation proof information; Performance check: Performance M ≥ θ, where θ is the performance threshold, ensuring that the performance of the Proposal on the public validation dataset is not lower than this threshold, and this threshold is 90% of the accuracy of the previous round of the global model.

10. A decentralized semi-asynchronous federated learning method based on committee consensus according to claim 1, characterized in that: The extended committee members vote according to the verification results. If the verification passes, they vote in favor; if it fails, they do not vote.