GFL: A Decentralized Federated Learning Framework Based On Blockchain

Yifan Hu, Wei Xia, Jun Xiao, Chao WuarXiv 2020

Introduction

Standard Federated Learning (FL) architectures typically rely on a central server to aggregate model updates from distributed participants. While effective, this centralized approach introduces significant communication bottlenecks and single points of failure. Furthermore, in decentralized environments, the presence of malicious nodes and non-identically distributed (Non-IID) data can severely degrade model performance and trust.

To address these challenges, the Galaxy Federated Learning (GFL) framework proposes a decentralized architecture built on three core technical pillars: consistent hashing, the Ring Decentralized FL (RDFL) algorithm, and a hybrid storage strategy using Blockchain and IPFS.

The GFL Framework

System Architecture

GFL organizes nodes into a ring topology using a consistent hashing algorithm. This structure ensures network stability as nodes join or leave and facilitates efficient model transfers. Untrusted data nodes transmit their models to the nearest "trusted" node on the ring.

The GFL System Architecture, integrating the ring topology with IPFS and smart contracts.

The framework utilizes the InterPlanetary File System (IPFS) for storing large model files, while an Ethereum-based blockchain records only the 46-byte IPFS hashes. This hybrid approach leverages the security and immutability of a ledger without the latency of on-chain data storage. Smart contracts manage task flows and provide a transparent audit trail for every update.

The RDFL Algorithm

The Ring Decentralized FL (RDFL) algorithm optimizes bandwidth through a Ring-allreduce strategy. To enhance robustness against data poisoning, it incorporates Knowledge Distillation (KD). Trusted nodes act as "students," learning from a subset of "teacher" models provided by peers. By calculating the Kullback-Leibler (KL) divergence, nodes filter out malicious or irrelevant updates, focusing only on the top 30–50% most similar models.

Key Results and Performance

The GFL framework was evaluated using standard benchmarks like MNIST, CIFAR-10, and CIFAR-100, with Non-IID data simulated via Latent Dirichlet Allocation (LDA).

Accuracy and Robustness

In data poisoning scenarios with a high ratio of malicious nodes, GFL significantly outperformed standard FedAvg. On the CIFAR-10 dataset, GFL achieved 84.25% accuracy compared to FedAvg's 79.19%. Even under skewed Non-IID distributions, GFL maintained a performance lead (63.25% vs 61.72%).

Comparison of Test Accuracy over FL rounds between the proposed RDFL and standard FedAvg.

Communication Efficiency

The integration of IPFS yielded massive speedups. For a ResNet-50 model, communication time was reduced from 796 seconds to approximately 16 seconds per round—a nearly 50x improvement in efficiency over conventional decentralized methods. Additionally, the blockchain implementation allows the system to trace the source of every update, preventing tampering.

Conclusion

GFL provides a scalable and secure alternative to centralized Federated Learning. By combining blockchain for trust, consistent hashing for stability, and knowledge distillation for robustness, it effectively mitigates the risks of bottlenecks and malicious attacks. Future work will focus on refining consensus mechanisms and exploring broader real-world applications.

Summary updated

BibTeX
@misc{hu2020gfl,
  author = {Yifan Hu and Wei Xia and Jun Xiao and Chao Wu},
  title = {{GFL: A Decentralized Federated Learning Framework Based On Blockchain}},
  year = {2020},
  eprint = {2010.10996},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2010.10996},
}
Figure