Rename rank to weight
Rename rank to weight