Aggregate client parameter vectors by sample count without moving raw examples to the server.
Required APIdef federated_average(models, weights):
return averaged_modelBehaviorThink through the mechanism first if you want the extra reasoning step. It never blocks the editor.
federated_average([[0.0, 1.0], [1.0, 3.0]], [1, 3])more data contributes more update mass
federated_average([[0.0], [2.0]], [1, 1])equal weights reduce to a mean
2 hidden edge tests run after the visible contract passes.
Run Tests to see the contract verdicts here.