For large-scale problems, efficiently optimizing task allocation with local communication and computing resources is challenging. Existing algorithms often fall short in task allocation computation time. Inspired by Bayesian estimation, we propose a parametric heuristic algorithm for redundant agents that can effectively perform dynamic task allocation in distributed architectures. Firstly, the method includes a confidence proxy-driven posterior correction algorithm (CPPCA), which can iteratively satisfy the constraint of the number of agents for each task based on local communication. We also prove that CPPCA can strictly converge after the number of neighbors is larger than a certain value. Then, we design a greedy swapping algorithm (GSA) to reduce the total cost while satisfying the constraints. It is also proved that the algorithm can converge in a finite number of steps under the condition that the communication graph is connected. Finally, the feasibility of the method is verified by simulation experiments. It shows that the confidence proxy-driven posterior correction and greedy swapping (CPPC-GS) method has significant advantages over the baseline algorithms in solving large-scale problems under the premise of redundant agents. It also has good results in the face of dynamic task allocation. Furthermore, the virtual-real fusion experiment bridges the “modeling gap” by validating the algorithm’s resilience to real-world engineering constraints, such as non-ideal communication and hardware heterogeneity, ensuring a seamless transition from theoretical frameworks to robust practical deployment.