DOI: 10.3390/electronics15214897 ISSN: 2079-9292

AdaTrust: Dual-Loop AI-Driven Adaptive Consensus via Bayesian Trust and Deep Reinforcement Learning

Song Tang, Zhigang Jin, Zhiqiang Wang

Blockchain consensus protocols are deployed as static designs in which one protocol with fixed parameters must serve dynamic networks with fluctuating workloads and evolving adversaries. This forces a rigid compromise among throughput, latency, and security. Existing remedies tune a single protocol’s parameters or select validators by reputation, leaving the strongest adaptation lever, the protocol identity itself, ungoverned and unproved. Here, we present AdaTrust, a dual-loop adaptive consensus framework. The fast loop, called BayesElect, maintains Beta-posterior trust scores from on-chain votes and elects committees whose size adapts to the estimated Byzantine ratio under a provable corruption bound. The slow loop, called AdaptSwitch, trains a proximal policy optimization (PPO) agent that jointly selects the protocol from an all-BFT pool and its configuration, which is gated by hysteresis. BFT safety is preserved during protocol handover under a bounded-overlap invariant, and policy convergence is characterized under bounded adversarial reward corruption. We evaluate AdaTrust on live blockchains consisting of a 16-validator CometBFT network and a 4-validator Besu QBFT network, with the simulator used only as the controller’s training environment. A trust-driven k=4 committee matches full 16-validator Tendermint, achieves 7.8× the matched-workload QBFT throughput, and serves 2.9× the throughput of a reactive threshold switcher; reconfiguration completes in under 8 s, while throughput is flat in committee size (1.9% spread). Under a live silence attack, AdaTrust retains 90.9% of throughput versus 75.9% and heals the committee (k: 4→13) in 6/6 runs; when the Tendermint backend is halted outright, the same controller escapes to QBFT and restores service in 6/6 runs. The results show that the diversity of modern consensus designs can be harvested safely when adaptation is governed by formally bounded trust.

More from our Archive